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

crl-release-24.3: sstable: fix improper buffer reuse in copyDataBlocks #4182

Merged

Conversation

itsbilal
Copy link
Member

Backport of #4181

Previously, in the colblk implementation of copyDataBlocks, we were reusing a buffer that could under some cases be passed directly to the write queue and would get written to sstable while later blocks are being read into the same buffer.

This change also improves tests around CopySpan() to better test cache hit/miss cases.

Fixes cockroachdb/cockroach#131332.

Previously, in the colblk implementation of copyDataBlocks,
we were reusing a buffer that could under some cases be passed
directly to the write queue and would get written to sstable
while later blocks are being read into the same buffer.

This change also improves tests around CopySpan() to better test
cache hit/miss cases.

Fixes cockroachdb/cockroach#131332.
@itsbilal itsbilal requested a review from a team as a code owner November 26, 2024 00:24
@cockroach-teamcity
Copy link
Member

This change is Reviewable

@itsbilal
Copy link
Member Author

TFTR!

@itsbilal itsbilal merged commit dde9490 into cockroachdb:crl-release-24.3 Nov 26, 2024
22 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants