Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
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
Sliding sync: Store the per-connection state in the database. #17599
Sliding sync: Store the per-connection state in the database. #17599
Changes from 10 commits
e2ade85
5b77f4a
7087c7c
e34d634
87d5336
d1ee253
b3d8e2d
3838b18
ed7591c
03eac5a
7935423
948456b
68a2a98
8ed1c07
bae50d3
1e5a3a7
0e07f65
4a68975
ac14e57
5fe6466
9065382
52f2199
174e1ad
5152f19
8a54f48
2da80fe
57a9506
File filter
Filter by extension
Conversations
Jump to
There are no files selected for viewing
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.
It looks like we're no longer taking
access_token
into account for thesliding_sync_connections
table. Are we ok with the potential collisions?If we care, we should add a test to make sure we don't regress this kind of thing.
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.
Ugh, I'd forgotten I had a to do for that. My hunch is that ideally we'd always have sliding sync attached to a device so that eg we can tie it to last time we saw a device. We also don't generally use sliding sync with pupetted access (which is the common way we don't have a device). I'll have a think
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.
I've renamed it to
effective_device_id
and added a comment.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.
Discussed in an internal meeting today
The
column
having the new nameeffective_device_id
is good enough but we're not going to address takingaccess_token
into account in this PR because the only users that won't have adevice_id
are application services. And since we block application services from using sync anyway, this doesn't matter now.We can always support it in the future and the column already has a good name if we decide to support it.