-
-
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
Improve Version Vector Handling for Legacy SDK and Snapshots #1096
Conversation
Changes with VV length of 0 were created from legacy SDK (v0.5.2 or below).
Warning Rate limit exceeded@hackerwins has exceeded the limit for the number of commits or files that can be reviewed per hour. Please wait 13 minutes and 23 seconds before requesting another review. ⌛ How to resolve this issue?After the wait time has elapsed, a review can be triggered using the We recommend that you space out your commits to avoid hitting the rate limit. 🚦 How do rate limits work?CodeRabbit enforces hourly rate limits for each developer per organization. Our paid plans have higher rate limits than the trial, open-source and free plans. In all cases, we re-allow further reviews after a brief timeout. Please see our FAQ for further information. 📒 Files selected for processing (3)
WalkthroughThe pull request introduces several modifications across multiple files, primarily focusing on refining the handling of version vectors within the ID management and document structures. Key changes include updates to the Changes
Possibly related PRs
Suggested labels
Suggested reviewers
Thank you for using CodeRabbit. We offer it for free to the OSS community and would appreciate your support in helping us grow. If you find it useful, would you consider giving us a shout-out on your favorite social media? 🪧 TipsChatThere are 3 ways to chat with CodeRabbit:
Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments. CodeRabbit Commands (Invoked using PR comments)
Other keywords and placeholders
CodeRabbit Configuration File (
|
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.
Actionable comments posted: 2
🧹 Outside diff range and nitpick comments (1)
pkg/document/crdt/rga_tree_split.go (1)
Line range hint
583-584
: Consider tracking the legacy Changes migrationThe TODO comment indicates temporary code handling legacy Changes without version vectors. This technical debt should be tracked.
Would you like me to create a GitHub issue to track the migration of legacy Changes and removal of
maxCreatedAt
parameter?
📜 Review details
Configuration used: CodeRabbit UI
Review profile: CHILL
📒 Files selected for processing (5)
pkg/document/change/id.go
(2 hunks)pkg/document/crdt/rga_tree_split.go
(1 hunks)pkg/document/document.go
(1 hunks)pkg/document/internal_document.go
(3 hunks)test/integration/gc_test.go
(1 hunks)
🔇 Additional comments (5)
pkg/document/change/id.go (2)
109-111
: Approve handling of empty version vector in SyncClocks
The added conditional correctly handles cases where other.versionVector
is empty by setting the other
actor's Lamport timestamp in the new version vector. This ensures proper synchronization of clocks.
125-125
: Approve unsetting of InitialActorID
in SetClocks
Unsetting time.InitialActorID
from the version vector in SetClocks
is appropriate to maintain the integrity of the version vector and prevent inclusion of irrelevant initial actors.
pkg/document/document.go (1)
192-192
: Approve simplification of applySnapshot
call
Removing the pack.Checkpoint.ServerSeq
parameter from the applySnapshot
call aligns with the updated method signature and simplifies the function call without affecting functionality.
pkg/document/crdt/rga_tree_split.go (2)
551-551
: LGTM: Version vector length check is more precise
The change from nil check to length check (len(versionVector) > 0
) is correct as it better handles empty version vectors, particularly for changes from legacy SDK (v0.5.2 or earlier).
Line range hint 551-584
: Verify version vector handling across the codebase
Let's verify that version vector handling is consistent across the codebase.
✅ Verification successful
Based on the search results, I can now generate the final response:
Version vector handling appears consistent with planned migration strategy
The codebase shows a consistent pattern of version vector handling with a clear migration strategy from legacy changes. The TODO comments and implementation across different files (rga_tree_split.go
, text.go
, and tree.go
) consistently document the temporary nature of maxCreatedAt
until all legacy changes are migrated to use version vectors.
Key findings:
- Version vector implementation is centralized in
pkg/document/change/id.go
with proper documentation - Consistent handling of version vector length checks across test and implementation files
- Well-documented migration path from legacy changes to version vector-based changes
- Uniform TODO comments indicating the temporary nature of
maxCreatedAt
🏁 Scripts executed
The following scripts were executed for the analysis:
Script:
#!/bin/bash
# Search for version vector usage patterns
echo "Searching for version vector length checks..."
rg "len\(.*[vV]ersionVector.*\)" -A 3
echo "Searching for maxCreatedAt usage..."
rg "maxCreatedAt.*legacy" -A 3
echo "Searching for version vector related types and interfaces..."
ast-grep --pattern 'type $_ struct {
$$$
versionVector $_
$$$
}'
Length of output: 4388
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #1096 +/- ##
==========================================
- Coverage 46.89% 46.84% -0.05%
==========================================
Files 84 84
Lines 12243 12256 +13
==========================================
Hits 5741 5741
- Misses 5926 5939 +13
Partials 576 576 ☔ View full report in Codecov by Sentry. |
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.
Go Benchmark
Benchmark suite | Current: a3f1430 | Previous: 9723c80 | Ratio |
---|---|---|---|
BenchmarkDocument/constructor_test |
1483 ns/op 1337 B/op 24 allocs/op |
1495 ns/op 1337 B/op 24 allocs/op |
0.99 |
BenchmarkDocument/constructor_test - ns/op |
1483 ns/op |
1495 ns/op |
0.99 |
BenchmarkDocument/constructor_test - B/op |
1337 B/op |
1337 B/op |
1 |
BenchmarkDocument/constructor_test - allocs/op |
24 allocs/op |
24 allocs/op |
1 |
BenchmarkDocument/status_test |
1120 ns/op 1305 B/op 22 allocs/op |
960.7 ns/op 1305 B/op 22 allocs/op |
1.17 |
BenchmarkDocument/status_test - ns/op |
1120 ns/op |
960.7 ns/op |
1.17 |
BenchmarkDocument/status_test - B/op |
1305 B/op |
1305 B/op |
1 |
BenchmarkDocument/status_test - allocs/op |
22 allocs/op |
22 allocs/op |
1 |
BenchmarkDocument/equals_test |
7759 ns/op 7529 B/op 134 allocs/op |
7900 ns/op 7529 B/op 134 allocs/op |
0.98 |
BenchmarkDocument/equals_test - ns/op |
7759 ns/op |
7900 ns/op |
0.98 |
BenchmarkDocument/equals_test - B/op |
7529 B/op |
7529 B/op |
1 |
BenchmarkDocument/equals_test - allocs/op |
134 allocs/op |
134 allocs/op |
1 |
BenchmarkDocument/nested_update_test |
17183 ns/op 12395 B/op 264 allocs/op |
19743 ns/op 12395 B/op 264 allocs/op |
0.87 |
BenchmarkDocument/nested_update_test - ns/op |
17183 ns/op |
19743 ns/op |
0.87 |
BenchmarkDocument/nested_update_test - B/op |
12395 B/op |
12395 B/op |
1 |
BenchmarkDocument/nested_update_test - allocs/op |
264 allocs/op |
264 allocs/op |
1 |
BenchmarkDocument/delete_test |
23348 ns/op 15923 B/op 347 allocs/op |
23742 ns/op 15923 B/op 347 allocs/op |
0.98 |
BenchmarkDocument/delete_test - ns/op |
23348 ns/op |
23742 ns/op |
0.98 |
BenchmarkDocument/delete_test - B/op |
15923 B/op |
15923 B/op |
1 |
BenchmarkDocument/delete_test - allocs/op |
347 allocs/op |
347 allocs/op |
1 |
BenchmarkDocument/object_test |
8773 ns/op 7073 B/op 122 allocs/op |
8960 ns/op 7073 B/op 122 allocs/op |
0.98 |
BenchmarkDocument/object_test - ns/op |
8773 ns/op |
8960 ns/op |
0.98 |
BenchmarkDocument/object_test - B/op |
7073 B/op |
7073 B/op |
1 |
BenchmarkDocument/object_test - allocs/op |
122 allocs/op |
122 allocs/op |
1 |
BenchmarkDocument/array_test |
29674 ns/op 12203 B/op 278 allocs/op |
30360 ns/op 12203 B/op 278 allocs/op |
0.98 |
BenchmarkDocument/array_test - ns/op |
29674 ns/op |
30360 ns/op |
0.98 |
BenchmarkDocument/array_test - B/op |
12203 B/op |
12203 B/op |
1 |
BenchmarkDocument/array_test - allocs/op |
278 allocs/op |
278 allocs/op |
1 |
BenchmarkDocument/text_test |
32088 ns/op 15326 B/op 492 allocs/op |
32454 ns/op 15324 B/op 492 allocs/op |
0.99 |
BenchmarkDocument/text_test - ns/op |
32088 ns/op |
32454 ns/op |
0.99 |
BenchmarkDocument/text_test - B/op |
15326 B/op |
15324 B/op |
1.00 |
BenchmarkDocument/text_test - allocs/op |
492 allocs/op |
492 allocs/op |
1 |
BenchmarkDocument/text_composition_test |
30837 ns/op 18716 B/op 504 allocs/op |
30598 ns/op 18718 B/op 504 allocs/op |
1.01 |
BenchmarkDocument/text_composition_test - ns/op |
30837 ns/op |
30598 ns/op |
1.01 |
BenchmarkDocument/text_composition_test - B/op |
18716 B/op |
18718 B/op |
1.00 |
BenchmarkDocument/text_composition_test - allocs/op |
504 allocs/op |
504 allocs/op |
1 |
BenchmarkDocument/rich_text_test |
83960 ns/op 40180 B/op 1183 allocs/op |
86772 ns/op 40181 B/op 1183 allocs/op |
0.97 |
BenchmarkDocument/rich_text_test - ns/op |
83960 ns/op |
86772 ns/op |
0.97 |
BenchmarkDocument/rich_text_test - B/op |
40180 B/op |
40181 B/op |
1.00 |
BenchmarkDocument/rich_text_test - allocs/op |
1183 allocs/op |
1183 allocs/op |
1 |
BenchmarkDocument/counter_test |
18601 ns/op 11874 B/op 258 allocs/op |
18696 ns/op 11874 B/op 258 allocs/op |
0.99 |
BenchmarkDocument/counter_test - ns/op |
18601 ns/op |
18696 ns/op |
0.99 |
BenchmarkDocument/counter_test - B/op |
11874 B/op |
11874 B/op |
1 |
BenchmarkDocument/counter_test - allocs/op |
258 allocs/op |
258 allocs/op |
1 |
BenchmarkDocument/text_edit_gc_100 |
1371479 ns/op 872559 B/op 17282 allocs/op |
1375483 ns/op 872569 B/op 17281 allocs/op |
1.00 |
BenchmarkDocument/text_edit_gc_100 - ns/op |
1371479 ns/op |
1375483 ns/op |
1.00 |
BenchmarkDocument/text_edit_gc_100 - B/op |
872559 B/op |
872569 B/op |
1.00 |
BenchmarkDocument/text_edit_gc_100 - allocs/op |
17282 allocs/op |
17281 allocs/op |
1.00 |
BenchmarkDocument/text_edit_gc_1000 |
53202666 ns/op 50546884 B/op 186747 allocs/op |
54253609 ns/op 50547612 B/op 186740 allocs/op |
0.98 |
BenchmarkDocument/text_edit_gc_1000 - ns/op |
53202666 ns/op |
54253609 ns/op |
0.98 |
BenchmarkDocument/text_edit_gc_1000 - B/op |
50546884 B/op |
50547612 B/op |
1.00 |
BenchmarkDocument/text_edit_gc_1000 - allocs/op |
186747 allocs/op |
186740 allocs/op |
1.00 |
BenchmarkDocument/text_split_gc_100 |
1966044 ns/op 1589042 B/op 15951 allocs/op |
1985378 ns/op 1589007 B/op 15949 allocs/op |
0.99 |
BenchmarkDocument/text_split_gc_100 - ns/op |
1966044 ns/op |
1985378 ns/op |
0.99 |
BenchmarkDocument/text_split_gc_100 - B/op |
1589042 B/op |
1589007 B/op |
1.00 |
BenchmarkDocument/text_split_gc_100 - allocs/op |
15951 allocs/op |
15949 allocs/op |
1.00 |
BenchmarkDocument/text_split_gc_1000 |
118639699 ns/op 141480093 B/op 186137 allocs/op |
118803927 ns/op 141482809 B/op 186142 allocs/op |
1.00 |
BenchmarkDocument/text_split_gc_1000 - ns/op |
118639699 ns/op |
118803927 ns/op |
1.00 |
BenchmarkDocument/text_split_gc_1000 - B/op |
141480093 B/op |
141482809 B/op |
1.00 |
BenchmarkDocument/text_split_gc_1000 - allocs/op |
186137 allocs/op |
186142 allocs/op |
1.00 |
BenchmarkDocument/text_delete_all_10000 |
16696916 ns/op 10213165 B/op 55681 allocs/op |
17017397 ns/op 10211937 B/op 55680 allocs/op |
0.98 |
BenchmarkDocument/text_delete_all_10000 - ns/op |
16696916 ns/op |
17017397 ns/op |
0.98 |
BenchmarkDocument/text_delete_all_10000 - B/op |
10213165 B/op |
10211937 B/op |
1.00 |
BenchmarkDocument/text_delete_all_10000 - allocs/op |
55681 allocs/op |
55680 allocs/op |
1.00 |
BenchmarkDocument/text_delete_all_100000 |
295000137 ns/op 142976748 B/op 561725 allocs/op |
297387914 ns/op 142998560 B/op 561775 allocs/op |
0.99 |
BenchmarkDocument/text_delete_all_100000 - ns/op |
295000137 ns/op |
297387914 ns/op |
0.99 |
BenchmarkDocument/text_delete_all_100000 - B/op |
142976748 B/op |
142998560 B/op |
1.00 |
BenchmarkDocument/text_delete_all_100000 - allocs/op |
561725 allocs/op |
561775 allocs/op |
1.00 |
BenchmarkDocument/text_100 |
231638 ns/op 120491 B/op 5182 allocs/op |
225977 ns/op 120491 B/op 5182 allocs/op |
1.03 |
BenchmarkDocument/text_100 - ns/op |
231638 ns/op |
225977 ns/op |
1.03 |
BenchmarkDocument/text_100 - B/op |
120491 B/op |
120491 B/op |
1 |
BenchmarkDocument/text_100 - allocs/op |
5182 allocs/op |
5182 allocs/op |
1 |
BenchmarkDocument/text_1000 |
2526589 ns/op 1171282 B/op 51086 allocs/op |
2446698 ns/op 1171279 B/op 51086 allocs/op |
1.03 |
BenchmarkDocument/text_1000 - ns/op |
2526589 ns/op |
2446698 ns/op |
1.03 |
BenchmarkDocument/text_1000 - B/op |
1171282 B/op |
1171279 B/op |
1.00 |
BenchmarkDocument/text_1000 - allocs/op |
51086 allocs/op |
51086 allocs/op |
1 |
BenchmarkDocument/array_1000 |
1289942 ns/op 1091562 B/op 11833 allocs/op |
1219180 ns/op 1091688 B/op 11834 allocs/op |
1.06 |
BenchmarkDocument/array_1000 - ns/op |
1289942 ns/op |
1219180 ns/op |
1.06 |
BenchmarkDocument/array_1000 - B/op |
1091562 B/op |
1091688 B/op |
1.00 |
BenchmarkDocument/array_1000 - allocs/op |
11833 allocs/op |
11834 allocs/op |
1.00 |
BenchmarkDocument/array_10000 |
13454736 ns/op 9800619 B/op 120300 allocs/op |
13277373 ns/op 9798498 B/op 120291 allocs/op |
1.01 |
BenchmarkDocument/array_10000 - ns/op |
13454736 ns/op |
13277373 ns/op |
1.01 |
BenchmarkDocument/array_10000 - B/op |
9800619 B/op |
9798498 B/op |
1.00 |
BenchmarkDocument/array_10000 - allocs/op |
120300 allocs/op |
120291 allocs/op |
1.00 |
BenchmarkDocument/array_gc_100 |
156707 ns/op 133287 B/op 1267 allocs/op |
148299 ns/op 133287 B/op 1266 allocs/op |
1.06 |
BenchmarkDocument/array_gc_100 - ns/op |
156707 ns/op |
148299 ns/op |
1.06 |
BenchmarkDocument/array_gc_100 - B/op |
133287 B/op |
133287 B/op |
1 |
BenchmarkDocument/array_gc_100 - allocs/op |
1267 allocs/op |
1266 allocs/op |
1.00 |
BenchmarkDocument/array_gc_1000 |
1477664 ns/op 1159770 B/op 12883 allocs/op |
1395245 ns/op 1159785 B/op 12883 allocs/op |
1.06 |
BenchmarkDocument/array_gc_1000 - ns/op |
1477664 ns/op |
1395245 ns/op |
1.06 |
BenchmarkDocument/array_gc_1000 - B/op |
1159770 B/op |
1159785 B/op |
1.00 |
BenchmarkDocument/array_gc_1000 - allocs/op |
12883 allocs/op |
12883 allocs/op |
1 |
BenchmarkDocument/counter_1000 |
211218 ns/op 193334 B/op 5773 allocs/op |
202781 ns/op 193337 B/op 5773 allocs/op |
1.04 |
BenchmarkDocument/counter_1000 - ns/op |
211218 ns/op |
202781 ns/op |
1.04 |
BenchmarkDocument/counter_1000 - B/op |
193334 B/op |
193337 B/op |
1.00 |
BenchmarkDocument/counter_1000 - allocs/op |
5773 allocs/op |
5773 allocs/op |
1 |
BenchmarkDocument/counter_10000 |
2219541 ns/op 2088268 B/op 59780 allocs/op |
2157968 ns/op 2088253 B/op 59780 allocs/op |
1.03 |
BenchmarkDocument/counter_10000 - ns/op |
2219541 ns/op |
2157968 ns/op |
1.03 |
BenchmarkDocument/counter_10000 - B/op |
2088268 B/op |
2088253 B/op |
1.00 |
BenchmarkDocument/counter_10000 - allocs/op |
59780 allocs/op |
59780 allocs/op |
1 |
BenchmarkDocument/object_1000 |
1477595 ns/op 1428352 B/op 9851 allocs/op |
1380555 ns/op 1428277 B/op 9850 allocs/op |
1.07 |
BenchmarkDocument/object_1000 - ns/op |
1477595 ns/op |
1380555 ns/op |
1.07 |
BenchmarkDocument/object_1000 - B/op |
1428352 B/op |
1428277 B/op |
1.00 |
BenchmarkDocument/object_1000 - allocs/op |
9851 allocs/op |
9850 allocs/op |
1.00 |
BenchmarkDocument/object_10000 |
15564478 ns/op 12166621 B/op 100565 allocs/op |
15059056 ns/op 12167677 B/op 100568 allocs/op |
1.03 |
BenchmarkDocument/object_10000 - ns/op |
15564478 ns/op |
15059056 ns/op |
1.03 |
BenchmarkDocument/object_10000 - B/op |
12166621 B/op |
12167677 B/op |
1.00 |
BenchmarkDocument/object_10000 - allocs/op |
100565 allocs/op |
100568 allocs/op |
1.00 |
BenchmarkDocument/tree_100 |
1073780 ns/op 943951 B/op 6103 allocs/op |
1021520 ns/op 943957 B/op 6103 allocs/op |
1.05 |
BenchmarkDocument/tree_100 - ns/op |
1073780 ns/op |
1021520 ns/op |
1.05 |
BenchmarkDocument/tree_100 - B/op |
943951 B/op |
943957 B/op |
1.00 |
BenchmarkDocument/tree_100 - allocs/op |
6103 allocs/op |
6103 allocs/op |
1 |
BenchmarkDocument/tree_1000 |
78970870 ns/op 86460779 B/op 60117 allocs/op |
72227744 ns/op 86460495 B/op 60117 allocs/op |
1.09 |
BenchmarkDocument/tree_1000 - ns/op |
78970870 ns/op |
72227744 ns/op |
1.09 |
BenchmarkDocument/tree_1000 - B/op |
86460779 B/op |
86460495 B/op |
1.00 |
BenchmarkDocument/tree_1000 - allocs/op |
60117 allocs/op |
60117 allocs/op |
1 |
BenchmarkDocument/tree_10000 |
9860862601 ns/op 8580660640 B/op 600217 allocs/op |
9317005118 ns/op 8580675248 B/op 600260 allocs/op |
1.06 |
BenchmarkDocument/tree_10000 - ns/op |
9860862601 ns/op |
9317005118 ns/op |
1.06 |
BenchmarkDocument/tree_10000 - B/op |
8580660640 B/op |
8580675248 B/op |
1.00 |
BenchmarkDocument/tree_10000 - allocs/op |
600217 allocs/op |
600260 allocs/op |
1.00 |
BenchmarkDocument/tree_delete_all_1000 |
79909352 ns/op 87510157 B/op 75271 allocs/op |
73376965 ns/op 87530427 B/op 75268 allocs/op |
1.09 |
BenchmarkDocument/tree_delete_all_1000 - ns/op |
79909352 ns/op |
73376965 ns/op |
1.09 |
BenchmarkDocument/tree_delete_all_1000 - B/op |
87510157 B/op |
87530427 B/op |
1.00 |
BenchmarkDocument/tree_delete_all_1000 - allocs/op |
75271 allocs/op |
75268 allocs/op |
1.00 |
BenchmarkDocument/tree_edit_gc_100 |
4004457 ns/op 4148427 B/op 15147 allocs/op |
3731695 ns/op 4147221 B/op 15146 allocs/op |
1.07 |
BenchmarkDocument/tree_edit_gc_100 - ns/op |
4004457 ns/op |
3731695 ns/op |
1.07 |
BenchmarkDocument/tree_edit_gc_100 - B/op |
4148427 B/op |
4147221 B/op |
1.00 |
BenchmarkDocument/tree_edit_gc_100 - allocs/op |
15147 allocs/op |
15146 allocs/op |
1.00 |
BenchmarkDocument/tree_edit_gc_1000 |
329579283 ns/op 383748438 B/op 154861 allocs/op |
295552693 ns/op 383743132 B/op 154847 allocs/op |
1.12 |
BenchmarkDocument/tree_edit_gc_1000 - ns/op |
329579283 ns/op |
295552693 ns/op |
1.12 |
BenchmarkDocument/tree_edit_gc_1000 - B/op |
383748438 B/op |
383743132 B/op |
1.00 |
BenchmarkDocument/tree_edit_gc_1000 - allocs/op |
154861 allocs/op |
154847 allocs/op |
1.00 |
BenchmarkDocument/tree_split_gc_100 |
2690620 ns/op 2413172 B/op 11131 allocs/op |
2509308 ns/op 2413016 B/op 11131 allocs/op |
1.07 |
BenchmarkDocument/tree_split_gc_100 - ns/op |
2690620 ns/op |
2509308 ns/op |
1.07 |
BenchmarkDocument/tree_split_gc_100 - B/op |
2413172 B/op |
2413016 B/op |
1.00 |
BenchmarkDocument/tree_split_gc_100 - allocs/op |
11131 allocs/op |
11131 allocs/op |
1 |
BenchmarkDocument/tree_split_gc_1000 |
198246882 ns/op 222253666 B/op 122010 allocs/op |
177609772 ns/op 222250952 B/op 122001 allocs/op |
1.12 |
BenchmarkDocument/tree_split_gc_1000 - ns/op |
198246882 ns/op |
177609772 ns/op |
1.12 |
BenchmarkDocument/tree_split_gc_1000 - B/op |
222253666 B/op |
222250952 B/op |
1.00 |
BenchmarkDocument/tree_split_gc_1000 - allocs/op |
122010 allocs/op |
122001 allocs/op |
1.00 |
BenchmarkRPC/client_to_server |
427290791 ns/op 19267048 B/op 216063 allocs/op |
419600527 ns/op 19255266 B/op 216041 allocs/op |
1.02 |
BenchmarkRPC/client_to_server - ns/op |
427290791 ns/op |
419600527 ns/op |
1.02 |
BenchmarkRPC/client_to_server - B/op |
19267048 B/op |
19255266 B/op |
1.00 |
BenchmarkRPC/client_to_server - allocs/op |
216063 allocs/op |
216041 allocs/op |
1.00 |
BenchmarkRPC/client_to_client_via_server |
774754746 ns/op 44987608 B/op 458635 allocs/op |
769034274 ns/op 41766736 B/op 454408 allocs/op |
1.01 |
BenchmarkRPC/client_to_client_via_server - ns/op |
774754746 ns/op |
769034274 ns/op |
1.01 |
BenchmarkRPC/client_to_client_via_server - B/op |
44987608 B/op |
41766736 B/op |
1.08 |
BenchmarkRPC/client_to_client_via_server - allocs/op |
458635 allocs/op |
454408 allocs/op |
1.01 |
BenchmarkRPC/attach_large_document |
1267464636 ns/op 1909647304 B/op 12166 allocs/op |
1302930456 ns/op 1910465696 B/op 12092 allocs/op |
0.97 |
BenchmarkRPC/attach_large_document - ns/op |
1267464636 ns/op |
1302930456 ns/op |
0.97 |
BenchmarkRPC/attach_large_document - B/op |
1909647304 B/op |
1910465696 B/op |
1.00 |
BenchmarkRPC/attach_large_document - allocs/op |
12166 allocs/op |
12092 allocs/op |
1.01 |
BenchmarkRPC/adminCli_to_server |
534236166 ns/op 35994112 B/op 289683 allocs/op |
537784444 ns/op 36396020 B/op 289687 allocs/op |
0.99 |
BenchmarkRPC/adminCli_to_server - ns/op |
534236166 ns/op |
537784444 ns/op |
0.99 |
BenchmarkRPC/adminCli_to_server - B/op |
35994112 B/op |
36396020 B/op |
0.99 |
BenchmarkRPC/adminCli_to_server - allocs/op |
289683 allocs/op |
289687 allocs/op |
1.00 |
BenchmarkLocker |
86.27 ns/op 16 B/op 1 allocs/op |
65.69 ns/op 16 B/op 1 allocs/op |
1.31 |
BenchmarkLocker - ns/op |
86.27 ns/op |
65.69 ns/op |
1.31 |
BenchmarkLocker - B/op |
16 B/op |
16 B/op |
1 |
BenchmarkLocker - allocs/op |
1 allocs/op |
1 allocs/op |
1 |
BenchmarkLockerParallel |
39.15 ns/op 0 B/op 0 allocs/op |
42.99 ns/op 0 B/op 0 allocs/op |
0.91 |
BenchmarkLockerParallel - ns/op |
39.15 ns/op |
42.99 ns/op |
0.91 |
BenchmarkLockerParallel - B/op |
0 B/op |
0 B/op |
1 |
BenchmarkLockerParallel - allocs/op |
0 allocs/op |
0 allocs/op |
1 |
BenchmarkLockerMoreKeys |
151.9 ns/op 15 B/op 0 allocs/op |
152.7 ns/op 15 B/op 0 allocs/op |
0.99 |
BenchmarkLockerMoreKeys - ns/op |
151.9 ns/op |
152.7 ns/op |
0.99 |
BenchmarkLockerMoreKeys - B/op |
15 B/op |
15 B/op |
1 |
BenchmarkLockerMoreKeys - allocs/op |
0 allocs/op |
0 allocs/op |
1 |
BenchmarkChange/Push_10_Changes |
4555976 ns/op 149196 B/op 1575 allocs/op |
4528815 ns/op 149056 B/op 1575 allocs/op |
1.01 |
BenchmarkChange/Push_10_Changes - ns/op |
4555976 ns/op |
4528815 ns/op |
1.01 |
BenchmarkChange/Push_10_Changes - B/op |
149196 B/op |
149056 B/op |
1.00 |
BenchmarkChange/Push_10_Changes - allocs/op |
1575 allocs/op |
1575 allocs/op |
1 |
BenchmarkChange/Push_100_Changes |
16448655 ns/op 794326 B/op 8285 allocs/op |
16130295 ns/op 784292 B/op 8284 allocs/op |
1.02 |
BenchmarkChange/Push_100_Changes - ns/op |
16448655 ns/op |
16130295 ns/op |
1.02 |
BenchmarkChange/Push_100_Changes - B/op |
794326 B/op |
784292 B/op |
1.01 |
BenchmarkChange/Push_100_Changes - allocs/op |
8285 allocs/op |
8284 allocs/op |
1.00 |
BenchmarkChange/Push_1000_Changes |
131543383 ns/op 7086145 B/op 77291 allocs/op |
127094909 ns/op 7295694 B/op 77295 allocs/op |
1.04 |
BenchmarkChange/Push_1000_Changes - ns/op |
131543383 ns/op |
127094909 ns/op |
1.04 |
BenchmarkChange/Push_1000_Changes - B/op |
7086145 B/op |
7295694 B/op |
0.97 |
BenchmarkChange/Push_1000_Changes - allocs/op |
77291 allocs/op |
77295 allocs/op |
1.00 |
BenchmarkChange/Pull_10_Changes |
3735038 ns/op 123367 B/op 1406 allocs/op |
3714562 ns/op 123235 B/op 1406 allocs/op |
1.01 |
BenchmarkChange/Pull_10_Changes - ns/op |
3735038 ns/op |
3714562 ns/op |
1.01 |
BenchmarkChange/Pull_10_Changes - B/op |
123367 B/op |
123235 B/op |
1.00 |
BenchmarkChange/Pull_10_Changes - allocs/op |
1406 allocs/op |
1406 allocs/op |
1 |
BenchmarkChange/Pull_100_Changes |
5306423 ns/op 350928 B/op 5040 allocs/op |
5360726 ns/op 351116 B/op 5041 allocs/op |
0.99 |
BenchmarkChange/Pull_100_Changes - ns/op |
5306423 ns/op |
5360726 ns/op |
0.99 |
BenchmarkChange/Pull_100_Changes - B/op |
350928 B/op |
351116 B/op |
1.00 |
BenchmarkChange/Pull_100_Changes - allocs/op |
5040 allocs/op |
5041 allocs/op |
1.00 |
BenchmarkChange/Pull_1000_Changes |
10817897 ns/op 2228830 B/op 43655 allocs/op |
10887820 ns/op 2227791 B/op 43654 allocs/op |
0.99 |
BenchmarkChange/Pull_1000_Changes - ns/op |
10817897 ns/op |
10887820 ns/op |
0.99 |
BenchmarkChange/Pull_1000_Changes - B/op |
2228830 B/op |
2227791 B/op |
1.00 |
BenchmarkChange/Pull_1000_Changes - allocs/op |
43655 allocs/op |
43654 allocs/op |
1.00 |
BenchmarkSnapshot/Push_3KB_snapshot |
18753487 ns/op 915364 B/op 8288 allocs/op |
18649717 ns/op 910190 B/op 8286 allocs/op |
1.01 |
BenchmarkSnapshot/Push_3KB_snapshot - ns/op |
18753487 ns/op |
18649717 ns/op |
1.01 |
BenchmarkSnapshot/Push_3KB_snapshot - B/op |
915364 B/op |
910190 B/op |
1.01 |
BenchmarkSnapshot/Push_3KB_snapshot - allocs/op |
8288 allocs/op |
8286 allocs/op |
1.00 |
BenchmarkSnapshot/Push_30KB_snapshot |
134066107 ns/op 7918264 B/op 82348 allocs/op |
131242202 ns/op 7860907 B/op 80881 allocs/op |
1.02 |
BenchmarkSnapshot/Push_30KB_snapshot - ns/op |
134066107 ns/op |
131242202 ns/op |
1.02 |
BenchmarkSnapshot/Push_30KB_snapshot - B/op |
7918264 B/op |
7860907 B/op |
1.01 |
BenchmarkSnapshot/Push_30KB_snapshot - allocs/op |
82348 allocs/op |
80881 allocs/op |
1.02 |
BenchmarkSnapshot/Pull_3KB_snapshot |
7740496 ns/op 1140914 B/op 19609 allocs/op |
7618355 ns/op 1140171 B/op 19604 allocs/op |
1.02 |
BenchmarkSnapshot/Pull_3KB_snapshot - ns/op |
7740496 ns/op |
7618355 ns/op |
1.02 |
BenchmarkSnapshot/Pull_3KB_snapshot - B/op |
1140914 B/op |
1140171 B/op |
1.00 |
BenchmarkSnapshot/Pull_3KB_snapshot - allocs/op |
19609 allocs/op |
19604 allocs/op |
1.00 |
BenchmarkSnapshot/Pull_30KB_snapshot |
19486059 ns/op 9339163 B/op 189553 allocs/op |
19500768 ns/op 9340076 B/op 189553 allocs/op |
1.00 |
BenchmarkSnapshot/Pull_30KB_snapshot - ns/op |
19486059 ns/op |
19500768 ns/op |
1.00 |
BenchmarkSnapshot/Pull_30KB_snapshot - B/op |
9339163 B/op |
9340076 B/op |
1.00 |
BenchmarkSnapshot/Pull_30KB_snapshot - allocs/op |
189553 allocs/op |
189553 allocs/op |
1 |
BenchmarkSplayTree/stress_test_100000 |
0.2008 ns/op 0 B/op 0 allocs/op |
0.1967 ns/op 0 B/op 0 allocs/op |
1.02 |
BenchmarkSplayTree/stress_test_100000 - ns/op |
0.2008 ns/op |
0.1967 ns/op |
1.02 |
BenchmarkSplayTree/stress_test_100000 - B/op |
0 B/op |
0 B/op |
1 |
BenchmarkSplayTree/stress_test_100000 - allocs/op |
0 allocs/op |
0 allocs/op |
1 |
BenchmarkSplayTree/stress_test_200000 |
0.3927 ns/op 0 B/op 0 allocs/op |
0.4056 ns/op 0 B/op 0 allocs/op |
0.97 |
BenchmarkSplayTree/stress_test_200000 - ns/op |
0.3927 ns/op |
0.4056 ns/op |
0.97 |
BenchmarkSplayTree/stress_test_200000 - B/op |
0 B/op |
0 B/op |
1 |
BenchmarkSplayTree/stress_test_200000 - allocs/op |
0 allocs/op |
0 allocs/op |
1 |
BenchmarkSplayTree/stress_test_300000 |
0.5822 ns/op 0 B/op 0 allocs/op |
0.6164 ns/op 0 B/op 0 allocs/op |
0.94 |
BenchmarkSplayTree/stress_test_300000 - ns/op |
0.5822 ns/op |
0.6164 ns/op |
0.94 |
BenchmarkSplayTree/stress_test_300000 - B/op |
0 B/op |
0 B/op |
1 |
BenchmarkSplayTree/stress_test_300000 - allocs/op |
0 allocs/op |
0 allocs/op |
1 |
BenchmarkSplayTree/random_access_100000 |
0.01279 ns/op 0 B/op 0 allocs/op |
0.01259 ns/op 0 B/op 0 allocs/op |
1.02 |
BenchmarkSplayTree/random_access_100000 - ns/op |
0.01279 ns/op |
0.01259 ns/op |
1.02 |
BenchmarkSplayTree/random_access_100000 - B/op |
0 B/op |
0 B/op |
1 |
BenchmarkSplayTree/random_access_100000 - allocs/op |
0 allocs/op |
0 allocs/op |
1 |
BenchmarkSplayTree/random_access_200000 |
0.02995 ns/op 0 B/op 0 allocs/op |
0.03262 ns/op 0 B/op 0 allocs/op |
0.92 |
BenchmarkSplayTree/random_access_200000 - ns/op |
0.02995 ns/op |
0.03262 ns/op |
0.92 |
BenchmarkSplayTree/random_access_200000 - B/op |
0 B/op |
0 B/op |
1 |
BenchmarkSplayTree/random_access_200000 - allocs/op |
0 allocs/op |
0 allocs/op |
1 |
BenchmarkSplayTree/random_access_300000 |
0.04567 ns/op 0 B/op 0 allocs/op |
0.04592 ns/op 0 B/op 0 allocs/op |
0.99 |
BenchmarkSplayTree/random_access_300000 - ns/op |
0.04567 ns/op |
0.04592 ns/op |
0.99 |
BenchmarkSplayTree/random_access_300000 - B/op |
0 B/op |
0 B/op |
1 |
BenchmarkSplayTree/random_access_300000 - allocs/op |
0 allocs/op |
0 allocs/op |
1 |
BenchmarkSplayTree/editing_trace_bench |
0.001742 ns/op 0 B/op 0 allocs/op |
0.001945 ns/op 0 B/op 0 allocs/op |
0.90 |
BenchmarkSplayTree/editing_trace_bench - ns/op |
0.001742 ns/op |
0.001945 ns/op |
0.90 |
BenchmarkSplayTree/editing_trace_bench - B/op |
0 B/op |
0 B/op |
1 |
BenchmarkSplayTree/editing_trace_bench - allocs/op |
0 allocs/op |
0 allocs/op |
1 |
BenchmarkSync/memory_sync_10_test |
8448 ns/op 3765 B/op 69 allocs/op |
8686 ns/op 3765 B/op 69 allocs/op |
0.97 |
BenchmarkSync/memory_sync_10_test - ns/op |
8448 ns/op |
8686 ns/op |
0.97 |
BenchmarkSync/memory_sync_10_test - B/op |
3765 B/op |
3765 B/op |
1 |
BenchmarkSync/memory_sync_10_test - allocs/op |
69 allocs/op |
69 allocs/op |
1 |
BenchmarkSync/memory_sync_100_test |
54632 ns/op 11118 B/op 304 allocs/op |
53461 ns/op 11111 B/op 303 allocs/op |
1.02 |
BenchmarkSync/memory_sync_100_test - ns/op |
54632 ns/op |
53461 ns/op |
1.02 |
BenchmarkSync/memory_sync_100_test - B/op |
11118 B/op |
11111 B/op |
1.00 |
BenchmarkSync/memory_sync_100_test - allocs/op |
304 allocs/op |
303 allocs/op |
1.00 |
BenchmarkSync/memory_sync_1000_test |
599000 ns/op 76993 B/op 2148 allocs/op |
582884 ns/op 77085 B/op 2153 allocs/op |
1.03 |
BenchmarkSync/memory_sync_1000_test - ns/op |
599000 ns/op |
582884 ns/op |
1.03 |
BenchmarkSync/memory_sync_1000_test - B/op |
76993 B/op |
77085 B/op |
1.00 |
BenchmarkSync/memory_sync_1000_test - allocs/op |
2148 allocs/op |
2153 allocs/op |
1.00 |
BenchmarkSync/memory_sync_10000_test |
7304495 ns/op 768479 B/op 20707 allocs/op |
7164814 ns/op 759563 B/op 20536 allocs/op |
1.02 |
BenchmarkSync/memory_sync_10000_test - ns/op |
7304495 ns/op |
7164814 ns/op |
1.02 |
BenchmarkSync/memory_sync_10000_test - B/op |
768479 B/op |
759563 B/op |
1.01 |
BenchmarkSync/memory_sync_10000_test - allocs/op |
20707 allocs/op |
20536 allocs/op |
1.01 |
BenchmarkTextEditing |
5236723898 ns/op 3982571360 B/op 20647622 allocs/op |
5173331444 ns/op 3982598256 B/op 20647672 allocs/op |
1.01 |
BenchmarkTextEditing - ns/op |
5236723898 ns/op |
5173331444 ns/op |
1.01 |
BenchmarkTextEditing - B/op |
3982571360 B/op |
3982598256 B/op |
1.00 |
BenchmarkTextEditing - allocs/op |
20647622 allocs/op |
20647672 allocs/op |
1.00 |
BenchmarkTree/10000_vertices_to_protobuf |
4090745 ns/op 6263010 B/op 70025 allocs/op |
4173176 ns/op 6265145 B/op 70025 allocs/op |
0.98 |
BenchmarkTree/10000_vertices_to_protobuf - ns/op |
4090745 ns/op |
4173176 ns/op |
0.98 |
BenchmarkTree/10000_vertices_to_protobuf - B/op |
6263010 B/op |
6265145 B/op |
1.00 |
BenchmarkTree/10000_vertices_to_protobuf - allocs/op |
70025 allocs/op |
70025 allocs/op |
1 |
BenchmarkTree/10000_vertices_from_protobuf |
219711550 ns/op 442172356 B/op 290058 allocs/op |
215516553 ns/op 442173652 B/op 290056 allocs/op |
1.02 |
BenchmarkTree/10000_vertices_from_protobuf - ns/op |
219711550 ns/op |
215516553 ns/op |
1.02 |
BenchmarkTree/10000_vertices_from_protobuf - B/op |
442172356 B/op |
442173652 B/op |
1.00 |
BenchmarkTree/10000_vertices_from_protobuf - allocs/op |
290058 allocs/op |
290056 allocs/op |
1.00 |
BenchmarkTree/20000_vertices_to_protobuf |
8681111 ns/op 12721503 B/op 140028 allocs/op |
9280051 ns/op 12716928 B/op 140028 allocs/op |
0.94 |
BenchmarkTree/20000_vertices_to_protobuf - ns/op |
8681111 ns/op |
9280051 ns/op |
0.94 |
BenchmarkTree/20000_vertices_to_protobuf - B/op |
12721503 B/op |
12716928 B/op |
1.00 |
BenchmarkTree/20000_vertices_to_protobuf - allocs/op |
140028 allocs/op |
140028 allocs/op |
1 |
BenchmarkTree/20000_vertices_from_protobuf |
872712417 ns/op 1697271776 B/op 580042 allocs/op |
853840546 ns/op 1697263568 B/op 580041 allocs/op |
1.02 |
BenchmarkTree/20000_vertices_from_protobuf - ns/op |
872712417 ns/op |
853840546 ns/op |
1.02 |
BenchmarkTree/20000_vertices_from_protobuf - B/op |
1697271776 B/op |
1697263568 B/op |
1.00 |
BenchmarkTree/20000_vertices_from_protobuf - allocs/op |
580042 allocs/op |
580041 allocs/op |
1.00 |
BenchmarkTree/30000_vertices_to_protobuf |
13623439 ns/op 19318527 B/op 210031 allocs/op |
13986879 ns/op 19318489 B/op 210030 allocs/op |
0.97 |
BenchmarkTree/30000_vertices_to_protobuf - ns/op |
13623439 ns/op |
13986879 ns/op |
0.97 |
BenchmarkTree/30000_vertices_to_protobuf - B/op |
19318527 B/op |
19318489 B/op |
1.00 |
BenchmarkTree/30000_vertices_to_protobuf - allocs/op |
210031 allocs/op |
210030 allocs/op |
1.00 |
BenchmarkTree/30000_vertices_from_protobuf |
1935450347 ns/op 3752035480 B/op 870043 allocs/op |
1878608708 ns/op 3752051832 B/op 870045 allocs/op |
1.03 |
BenchmarkTree/30000_vertices_from_protobuf - ns/op |
1935450347 ns/op |
1878608708 ns/op |
1.03 |
BenchmarkTree/30000_vertices_from_protobuf - B/op |
3752035480 B/op |
3752051832 B/op |
1.00 |
BenchmarkTree/30000_vertices_from_protobuf - allocs/op |
870043 allocs/op |
870045 allocs/op |
1.00 |
This comment was automatically generated by workflow using github-action-benchmark.
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.
Related to #723 |
What this PR does / why we need it:
Add
{actorID:lamport}
to accumulate VV when VV is empty in applyChangeUse maxLamport() instead of serverSeq in applySnapshot
Which issue(s) this PR fixes:
Fixes #
Special notes for your reviewer:
Does this PR introduce a user-facing change?:
Additional documentation:
Checklist:
Summary by CodeRabbit
New Features
Bug Fixes
Tests