Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

WIP Migrate data from existing freedit instance #10

Draft
wants to merge 2 commits into
base: main
Choose a base branch
from

Conversation

jacque006
Copy link
Collaborator

@jacque006 jacque006 commented Dec 17, 2024

Implementation / Review resources

TODO

  • Users
  • Inns
  • Posts
  • Solos
  • Comments
  • Static/uploaded assets?
  • Test/simulate with prod data
  • Migrate data from talk.zketh.io

Resolves #1

@jacque006 jacque006 force-pushed the jacque006/data-migration branch from a0f3e59 to c288ecf Compare December 18, 2024 05:37
i_u.username, i_u.uid, uid
);
} else {
let uid = incr_id(db, "users_count")?;
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Note that most (all?) ids for entries are done via incrementing id. When merging in data from another instance, these ids must be remapped to a higher id. The new id then must be used in other references to the old id in the incoming data.

Comment on lines +95 to +98
let num_incoming_inns = get_count(&m_db, "default", "inns_count")?;
info!("processing {0} incoming Inns", num_incoming_inns);

// TODO If only one inn, just use that (aka merge posts in)
Copy link
Collaborator Author

@jacque006 jacque006 Dec 18, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I believe there is only one inn on each of the freedit instances/data we are targeting. Can likely just use the current inn and ignore the incoming one from the migration.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Migrate data from https://talk.zketh.io
1 participant