Skip to content

storage: remove Engine.SetUpperBound#81194

Merged
craig[bot] merged 2 commits intocockroachdb:masterfrom
erikgrinaker:mvcc-iterator-setupperbound
May 16, 2022
Merged

storage: remove Engine.SetUpperBound#81194
craig[bot] merged 2 commits intocockroachdb:masterfrom
erikgrinaker:mvcc-iterator-setupperbound

Conversation

@erikgrinaker
Copy link
Copy Markdown
Contributor

Partial resubmit of #79291, which was merged into the mvcc-range-tombstones branch.


storage: make Engine.ClearIterRange construct iterator internally

Engine.ClearIterRange now creates the iterator itself, instead of
having it passed in. This ensures the iterator is created with
appropriate bounds and options, which becomes even more important with
the introduction of range keys. It will also allow removal of
Engine.SetUpperBound in a subsequent commit.

If further flexibility is needed, we can consider passing an
IterOptions struct with appropriate bounds instead of a key span.

Release note: None

storage: remove Engine.SetUpperBound

This patch removes the Engine.SetUpperBound method, as it is no longer
in use.

Release note: None

`Engine.ClearIterRange` now creates the iterator itself, instead of
having it passed in. This ensures the iterator is created with
appropriate bounds and options, which becomes even more important with
the introduction of range keys. It will also allow removal of
`Engine.SetUpperBound` in a subsequent commit.

If further flexibility is needed, we can consider passing an
`IterOptions` struct with appropriate bounds instead of a key span.

Release note: None
This patch removes the `Engine.SetUpperBound` method, as it is no longer
in use.

Release note: None
@erikgrinaker erikgrinaker requested review from a team as code owners May 11, 2022 16:22
@erikgrinaker erikgrinaker self-assigned this May 11, 2022
@cockroach-teamcity
Copy link
Copy Markdown
Member

This change is Reviewable

Copy link
Copy Markdown
Contributor

@jbowens jbowens left a comment

Choose a reason for hiding this comment

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

:lgtm_strong:

Reviewed 10 of 12 files at r1, 6 of 7 files at r2, all commit messages.
Reviewable status: :shipit: complete! 1 of 0 LGTMs obtained (waiting on @aliher1911, @nicktrav, and @sumeerbhola)

@erikgrinaker
Copy link
Copy Markdown
Contributor Author

TFTR!

bors r=jbowens

@craig
Copy link
Copy Markdown
Contributor

craig bot commented May 16, 2022

Build succeeded:

@craig craig bot merged commit e2f3965 into cockroachdb:master May 16, 2022
@erikgrinaker erikgrinaker deleted the mvcc-iterator-setupperbound branch May 17, 2022 16: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