Skip to content

kv: add a comment#45554

Merged
craig[bot] merged 1 commit intocockroachdb:masterfrom
andreimatei:kv.btree-comment
Mar 2, 2020
Merged

kv: add a comment#45554
craig[bot] merged 1 commit intocockroachdb:masterfrom
andreimatei:kv.btree-comment

Conversation

@andreimatei
Copy link
Copy Markdown
Contributor

Explain the surprising fact that we're telling then inflight-writes
btree to not reuse its nodes.

Release note: None

Explain the surprising fact that we're telling then inflight-writes
btree to not reuse its nodes.

Release note: None
@andreimatei andreimatei requested a review from nvb February 29, 2020 23:20
@andreimatei
Copy link
Copy Markdown
Contributor Author

Right?

@cockroach-teamcity
Copy link
Copy Markdown
Member

This change is Reviewable

Copy link
Copy Markdown
Contributor

@nvb nvb left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

:lgtm: I wouldn't have expected this to be surprising given that it's on the txn COMMITTED path, but I'm happy to have it be more explicit.

Reviewable status: :shipit: complete! 1 of 0 LGTMs obtained (waiting on @nvanbenschoten)

Copy link
Copy Markdown
Contributor Author

@andreimatei andreimatei left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

TFTR

well, everything about that reuse param is unclear because it's ambiguous whether it's the caller that's free to reuse something, or the callee. Once you figure out that it's the callee, you (I) would expect that when the caller is categorically done with the btree, it'd give the callee the freedom to do whatever it wants. Except here (surprisingly) the freedom comes at a price.

bors r+

Reviewable status: :shipit: complete! 1 of 0 LGTMs obtained

@craig
Copy link
Copy Markdown
Contributor

craig bot commented Mar 2, 2020

Build failed

@andreimatei
Copy link
Copy Markdown
Contributor Author

andreimatei commented Mar 2, 2020 via email

@craig
Copy link
Copy Markdown
Contributor

craig bot commented Mar 2, 2020

Build succeeded

@craig craig bot merged commit 003fa43 into cockroachdb:master Mar 2, 2020
@andreimatei andreimatei deleted the kv.btree-comment branch March 2, 2020 19:27
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