-
-
Notifications
You must be signed in to change notification settings - Fork 148
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
Introduce MongoDB sharding rules to Documents and Document-wide collections #734
Conversation
Codecov ReportAttention:
Additional details and impacted files@@ Coverage Diff @@
## main #734 +/- ##
==========================================
+ Coverage 50.17% 50.87% +0.70%
==========================================
Files 69 70 +1
Lines 10165 10168 +3
==========================================
+ Hits 5100 5173 +73
+ Misses 4526 4473 -53
+ Partials 539 522 -17 ☔ View full report in Codecov by Sentry. |
72694b0
to
f20f0fa
Compare
f20f0fa
to
2bc01f9
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for your contribution.
I looked at the code up to the memory DB. and I have a question.
MemoryDB
runs standalone, and it is not sharded based on shard keys. If we receive refKey due to change in interface, we only need to utilize the id. So there's no necessity to use the key in the implementation. What are your thoughts on this?
I think that's also a good idea. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM. 👍
This commit introduces MongoDB sharding rules to documents and document-wide collections (e.g. Changes, SyncedSync, Snapshots). Changes: - Introduce RefKey to represent ID and shard key together instead of ID. - Change the reference key of Users from _id to username. - Introduce encoders for types.ID, time.ActorID and ClientDocInfo to MongoDB.
What this PR does / why we need it:
This PR introduces MongoDB sharding rules to
documents
and document-wide collections (e.g.Changes
,SyncedSync
,Snapshots
).Which issue(s) this PR fixes:
Addresses #673
Special notes for your reviewer:
Does this PR introduce a user-facing change?:
Additional documentation:
Checklist: