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

Sync client shall not block user writes #5844

Merged
merged 23 commits into from
Sep 27, 2022
Merged
Changes from 1 commit
Commits
Show all changes
23 commits
Select commit Hold shift + click to select a range
e9322ee
Reenable sync benchmark
danieltabacaru Sep 12, 2022
9e7e4f6
Update sync benchmark
danieltabacaru Sep 12, 2022
313ed46
Add method to check if other threads are waiting for the write mutex
danieltabacaru Sep 12, 2022
5429e85
Allow users to commit changes while sync client is integrating remote…
danieltabacaru Sep 12, 2022
7c62329
Fix typos/grammar in comments
danieltabacaru Sep 12, 2022
54b35d1
Fix hack in async write unit test
danieltabacaru Sep 12, 2022
6ef9f0e
Add sync unit tests
danieltabacaru Sep 12, 2022
793517e
Adapt benchmark code to use proper arguments in function call
danieltabacaru Sep 12, 2022
433d591
Clang-format + minor changes
danieltabacaru Sep 12, 2022
aa74107
Code review changes
danieltabacaru Sep 16, 2022
d5843dc
Fix bugs introduced after code review changes
danieltabacaru Sep 17, 2022
c44c806
Use thread instead of future
danieltabacaru Sep 21, 2022
3d15242
Move _impl::ForEventLoopDispatcher out of realm::util namespace so re…
danieltabacaru Sep 21, 2022
168ef37
Refactor transforming and applying server changesets into separate me…
danieltabacaru Sep 21, 2022
07856ba
Merge branch 'master' into dt/sync_client_shall_not_block_user_writes_2
danieltabacaru Sep 21, 2022
36ef668
Fix test after introducing DownloadBatchState::SteadyState
danieltabacaru Sep 21, 2022
97c5417
Update changelog
danieltabacaru Sep 21, 2022
b3584c8
Add integration test for pbs
danieltabacaru Sep 21, 2022
5640dcb
Merge branch 'master' into dt/sync_client_shall_not_block_user_writes_2
danieltabacaru Sep 21, 2022
475b669
It is a violation to call on_flx_sync_progress with SteadyState
danieltabacaru Sep 23, 2022
cea8594
Remove flaky tests
danieltabacaru Sep 26, 2022
1e68dd3
Merge branch 'master' into dt/sync_client_shall_not_block_user_writes_2
danieltabacaru Sep 26, 2022
6091910
Remove unused test code
danieltabacaru Sep 26, 2022
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
Fix bugs introduced after code review changes
danieltabacaru committed Sep 17, 2022
commit d5843dcdddd7ee78c8a7a2c2fdee209bda1b88db
3 changes: 3 additions & 0 deletions src/realm/sync/transform.cpp
Original file line number Diff line number Diff line change
@@ -2574,6 +2574,9 @@ TransformerImpl::iterator TransformerImpl::transform_remote_changesets(
// 2. No reciprocal changeset was modified
continue_applying = changeset_applier(p) || must_apply_all;
}
if (p != same_base_range_end) {
break;
}

our_changesets.clear(); // deliberately not releasing memory
}
2 changes: 1 addition & 1 deletion test/test_sync.cpp
Original file line number Diff line number Diff line change
@@ -4442,7 +4442,7 @@ TEST(Sync_UserInterruptsIntegrationOfRemoteChanges)
version_type user_commit_version = UINT_FAST64_MAX;

Session::Config config;
config.on_download_message_integrated_hook =
config.on_download_message_received_hook =
[&](const sync::SyncProgress&, int64_t, sync::DownloadBatchState batch_state, size_t num_changesets) {
CHECK(batch_state == sync::DownloadBatchState::SteadyState);
if (num_changesets == 0)