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

perf: avoid large offset query via limit windowing #180

Merged
merged 11 commits into from
May 27, 2024

Conversation

Roiocam
Copy link
Member

@Roiocam Roiocam commented Apr 19, 2024

Motivation

resolves: #179

Looks like we don't need to change a lot.

also found the legacy unit tests didn't works.

@Roiocam Roiocam marked this pull request as draft April 19, 2024 09:38
@Roiocam Roiocam marked this pull request as ready for review April 26, 2024 02:31
fromSequenceNr: Long,
toSequenceNr: Long,
batchSize: Int,
refreshInterval: Option[(FiniteDuration, Scheduler)]) = {
Copy link
Member

Choose a reason for hiding this comment

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

should add some check for fromSequenceNr and batchSize

Copy link
Member

Choose a reason for hiding this comment

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

and add checking for where fromSequenceNr > toSequenceNr too

Copy link
Member Author

Choose a reason for hiding this comment

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

should add some check for fromSequenceNr and batchSize

what does that mean? batch size didn't allow zero value, and the fromSequenceNr was generate from acotr it self.

and add checking for where fromSequenceNr > toSequenceNr too

fromSequenceNr > toSequenceNr is enforced down below.

Copy link
Contributor

Choose a reason for hiding this comment

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

it is generally good practice to do input validation to catch failures early and make constraints explicit

@pjfanning
Copy link
Contributor

@Roiocam I want to release v1.1.0-M1 of this module within the next week or 2. Is this PR something that we can get merged in that timeframe or could we add it after v1.1.0-M1 is released?

@Roiocam
Copy link
Member Author

Roiocam commented May 16, 2024

@Roiocam I want to release v1.1.0-M1 of this module within the next week or 2. Is this PR something that we can get merged in that timeframe or could we add it after v1.1.0-M1 is released?

Busy paid time works, I will fix these over the weekend.

@Roiocam Roiocam requested review from pjfanning and He-Pin May 17, 2024 01:44
@laglangyue
Copy link
Contributor

lgtm

@pjfanning pjfanning modified the milestones: 1.1.0, 1.1.0-M1, 1.1.0-M1-RC1 May 23, 2024
Copy link
Contributor

@pjfanning pjfanning left a comment

Choose a reason for hiding this comment

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

lgtm - but I would appreciate if other people could approve it too @He-Pin @nvollmar @mdedetrich wdyt?

Copy link
Contributor

@nvollmar nvollmar left a comment

Choose a reason for hiding this comment

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

lgtm

@pjfanning
Copy link
Contributor

@Roiocam can you merge this if you are happy it is ready? This is the last PR that we need before we can do an RC for this module.

@Roiocam Roiocam merged commit ab2f6ce into apache:main May 27, 2024
23 checks passed
@Roiocam Roiocam deleted the avoid-large-offset branch May 27, 2024 01:11
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.

Query performance improvement
5 participants