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

Helper function for migrating to EmbeddedObject #2408

Closed
DominicFrei opened this issue Jun 2, 2021 · 4 comments · Fixed by #3322
Closed

Helper function for migrating to EmbeddedObject #2408

DominicFrei opened this issue Jun 2, 2021 · 4 comments · Fixed by #3322
Assignees

Comments

@DominicFrei
Copy link
Contributor

Goals

When migrating to EmbeddedObject two cases have to be handled:

  • Objects without backlinks (orphaned objects)
  • Objects with more than one backlink

This is necessary due to the nature of EmbeddedObjects always belonging to one and only one other object.

As explained in #2394 and #2393 this cannot be achieved while migrating because EmbeddedObject cannot be iterated over / queried since it's not a standalone object.

This will also unlock #2394.

Expected Results

  • Orphaned objects get deleted automatically when a flag for deleting them is set as part of the migration block.
  • Objects with multiple backlinks will be duplicated so that every object linking to them gets their own version.
@DominicFrei
Copy link
Contributor Author

This will be unlocked by realm/realm-core#4729.

@DominicFrei DominicFrei added the Blocked This issue is blocked by another issue label Jun 2, 2021
@sync-by-unito
Copy link

sync-by-unito bot commented Sep 3, 2021

➤ Dominic Frei commented:

Unassigned myself and set it to Parked since we really don't know if and when we will do that. It's just an enhance to automate something that users can do manually anyway and it depends on a Core change that would have to be done first.

@softlion
Copy link

The core has been changed last year
realm/realm-core#5737

Also, how to do that manually as questioned here ? Can't find a way.
#2594 (comment)

@nirinchev nirinchev self-assigned this May 12, 2023
@nirinchev nirinchev removed Blocked This issue is blocked by another issue gathering-interest labels May 12, 2023
@nirinchev
Copy link
Member

This is now unblocked and we can pick it up.

@github-actions github-actions bot locked as resolved and limited conversation to collaborators Mar 11, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants