Skip to content

Fix bulk operations breaking frozen locks #12008

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

Merged
merged 1 commit into from
Nov 26, 2024

Conversation

snaury
Copy link
Member

@snaury snaury commented Nov 26, 2024

Changelog entry

Fix bulk operations potentially breaking frozen locks later causing non-serializable commits.

Changelog category

  • Bugfix

Additional information

While investigating YDBREQUESTS-4711 it was discovered that TTL (and bulk operations in general) are not waiting for the pipeline to be properly restored after a restart, which allowed them to erroneously break validated (and frozen) locks. This in turn could allow later transactions to violate serializability, which is demonstrated in a unit-test.

Additionally a typo was found in locks.h which caused persistent locks to always restore as read-write locks, even when they are write-only. This could never cause serializability issues, but could cause unnecessary conflicts.

@snaury snaury self-assigned this Nov 26, 2024
@snaury snaury marked this pull request as ready for review November 26, 2024 12:42
@github-actions github-actions bot added bugfix and removed bugfix labels Nov 26, 2024
Copy link

github-actions bot commented Nov 26, 2024

2024-11-26 12:45:08 UTC Pre-commit check linux-x86_64-relwithdebinfo for 68d424f has started.
2024-11-26 12:45:30 UTC Artifacts will be uploaded here
2024-11-26 12:48:27 UTC ya make is running...
🟡 2024-11-26 13:42:47 UTC Some tests failed, follow the links below. Going to retry failed tests...

Test history | Ya make output | Test bloat

TESTS PASSED ERRORS FAILED SKIPPED MUTED?
15481 13956 0 4 1409 112

2024-11-26 13:44:05 UTC ya make is running... (failed tests rerun, try 2)
🟡 2024-11-26 13:55:42 UTC Some tests failed, follow the links below. Going to retry failed tests...

Test history | Ya make output | Test bloat | Test bloat

TESTS PASSED ERRORS FAILED SKIPPED MUTED?
128 (only retried tests) 21 0 1 0 106

2024-11-26 13:55:50 UTC ya make is running... (failed tests rerun, try 3)
🟢 2024-11-26 14:07:25 UTC Tests successful.

Test history | Ya make output | Test bloat | Test bloat | Test bloat

TESTS PASSED ERRORS FAILED SKIPPED MUTED?
107 (only retried tests) 1 0 0 0 106

🟢 2024-11-26 14:07:32 UTC Build successful.
🟢 2024-11-26 14:07:53 UTC ydbd size 2.5 GiB changed* by +4.8 KiB, which is < 100.0 KiB vs main: OK

ydbd size dash main: 2a7eb6b merge: 68d424f diff diff %
ydbd size 2 694 580 984 Bytes 2 694 585 848 Bytes +4.8 KiB +0.000%
ydbd stripped size 482 594 640 Bytes 482 595 088 Bytes +448 Bytes +0.000%

*please be aware that the difference is based on comparing your commit and the last completed build from the post-commit, check comparation

Copy link

github-actions bot commented Nov 26, 2024

2024-11-26 12:45:57 UTC Pre-commit check linux-x86_64-release-asan for 68d424f has started.
2024-11-26 12:46:08 UTC Artifacts will be uploaded here
2024-11-26 12:49:03 UTC ya make is running...
🟡 2024-11-26 13:56:06 UTC Some tests failed, follow the links below. This fail is not in blocking policy yet

Test history | Ya make output | Test bloat

TESTS PASSED ERRORS FAILED SKIPPED MUTED?
9068 8997 0 17 6 48

🟢 2024-11-26 13:56:53 UTC Build successful.
🟢 2024-11-26 13:57:22 UTC ydbd size 4.9 GiB changed* by +11.6 KiB, which is < 100.0 KiB vs main: OK

ydbd size dash main: 2a7eb6b merge: 68d424f diff diff %
ydbd size 5 293 729 296 Bytes 5 293 741 200 Bytes +11.6 KiB +0.000%
ydbd stripped size 1 361 387 440 Bytes 1 361 388 912 Bytes +1.4 KiB +0.000%

*please be aware that the difference is based on comparing your commit and the last completed build from the post-commit, check comparation

@snaury snaury merged commit 205cf3a into ydb-platform:main Nov 26, 2024
12 checks passed
@snaury snaury deleted the bugfix-YDBREQUESTS-4711 branch November 26, 2024 15:12
snaury added a commit to snaury/ydb that referenced this pull request Nov 26, 2024
snaury added a commit to snaury/ydb that referenced this pull request Nov 26, 2024
snaury added a commit to snaury/ydb that referenced this pull request Nov 26, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants