Efficient means for migrating a collection from one service to another #286
Labels
No labels
bug
documentation
duplicate
enhancement
good first issue
help wanted
invalid
question
wontfix
No milestone
No assignees
2 participants
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
orinoco/dump-things-service#286
Loading…
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
At the moment this appears to need custom tooling, and also administrator access at both outgoing and incoming service. The latter to obtain and then instantiate a collection's configuration. This appears to make it hard to perform migrations.
It could be argued that the base collection setup cannot really be migrated (because the auth setup is likely to be very different, or should be different). At most it could be recreated "in spirit".
Assuming a collection is already recreated empty at the new service, it appears that the following steps are necessary:
/serverand find the right object in.collectionsp[]that matches the source collection, to be able to extract.classesfor it/{collection}/incoming/to determine existing inboxes/{collection}/curated/records/{class_name}and feed the outcome to new/{collection}/curated/record/{class_name}/{collection}/incoming/{label}/records/p/{class_name}and feed the outcome to new/{collection}/incoming/{label}/record/{class_name}-- possibly mapping to a new inbox nameThis approach takes the route via explicit per-class processing, because while there is
/{collection}/curated/records/to read, there is no equivalent endpoint to post "any" record.Good point. After dropping the auto-generated per-class endpoints it would only be natural to add an endpoint that accepts any class.