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

Prevent UserIdentity metadata table from growing #5144

Merged
merged 2 commits into from
Jan 11, 2022
Merged

Conversation

jedelbo
Copy link
Contributor

@jedelbo jedelbo commented Jan 7, 2022

What, How & Why?

I discovered that every time I ran a realm-js program using a synchronized realm, the UserIdentity table was growing with 2 elements, but all elements in the table were the same.

Fixes #5152

☑️ ToDos

  • 📝 Changelog update
  • 🚦 Tests (or not relevant)

@jedelbo jedelbo requested a review from ironage January 7, 2022 15:25
@cla-bot cla-bot bot added the cla: yes label Jan 7, 2022
@jedelbo
Copy link
Contributor Author

jedelbo commented Jan 7, 2022

@ironage if you agree that this was not then intention, I will also create an issue for it.

@ironage
Copy link
Contributor

ironage commented Jan 7, 2022

Yes great find, and the fix you made is solid. Another approach to get the expected behaviour could be to make the UserIdentity an embedded table such that clearing the list also deletes the linked objects. But I'm not sure if the limitations of embedded tables will hinder us from using this data in the future so I think your solution is probably best.

@jedelbo jedelbo merged commit 13bbcc0 into master Jan 11, 2022
@jedelbo jedelbo deleted the je/user-identity branch January 11, 2022 11:27
@github-actions github-actions bot locked as resolved and limited conversation to collaborators Mar 22, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

UserIdentity metadata table grows indefinitely
3 participants