Skip to content

Conversation

@DomGarguilo
Copy link
Member

Fixes #5788

The main change here is to use the version of Utils.reserveTable() that allows us to pass a range to only lock that portion.

@DomGarguilo DomGarguilo added this to the 4.0.0 milestone Oct 3, 2025
@DomGarguilo DomGarguilo self-assigned this Oct 3, 2025
Copy link
Member

@kevinrr888 kevinrr888 left a comment

Choose a reason for hiding this comment

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

LGTM

Comment on lines +57 to +58
range.isStartKeyInclusive(), range.isInfiniteStopKey() ? null : range.getEndKey().getRow(),
range.isEndKeyInclusive());
Copy link
Member

Choose a reason for hiding this comment

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

Not anything for this PR but is a bit confusing that Range uses both "Stop Key" and "End Key" to mean the same thing

range.isInfiniteStartKey() ? null : range.getStartKey().getRow(),
range.isStartKeyInclusive(), range.isInfiniteStopKey() ? null : range.getEndKey().getRow(),
range.isEndKeyInclusive());
final LockRange lockRange = LockRange.of(rowRange);
Copy link
Member

@kevinrr888 kevinrr888 Oct 8, 2025

Choose a reason for hiding this comment

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

Is a RowRange object needed in this method? Seems like more info is computed than needed (inclusive start/end). Can just have
final LockRange lockRange = LockRange.of(range.isInfiniteStartKey() ? null : range.getStartKey().getRow(), range.isInfiniteStopKey() ? null : range.getEndKey().getRow())

@DomGarguilo DomGarguilo marked this pull request as draft October 9, 2025 17:45
@DomGarguilo
Copy link
Member Author

I have converted this to draft for now. I think #5952 should be merged first as it might have some impact here.

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.

Narrow table lock range for set tablet availability fate operation

2 participants