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

Add all-args-constructor for easy initial config Pagination #696

Merged
merged 3 commits into from
Jan 29, 2024
Merged

Add all-args-constructor for easy initial config Pagination #696

merged 3 commits into from
Jan 29, 2024

Conversation

jonaskahn
Copy link
Contributor

Pull Request for Enhancement

What does this PR do?

This is a tiny PR to make the Pagination initial more easier.
The current implementation make extra lines to config Pagination. Here is an example:

Before

val index = meilisearchClient.index(it.getIndex())
val defaultPagination = Pagination()
defaultPagination.maxTotalHits = 5000
index.updatePaginationSettings(defaultPagination)

After

val index = meilisearchClient.index(it.getIndex())
index.updatePaginationSettings(Pagination(5000))

@curquiza
Copy link
Member

curquiza commented Jan 17, 2024

hello @jonaskahn

Sorry for the delay 🙇‍♀️ and thanks for your work!

Can you add a test for this new method?

@jonaskahn
Copy link
Contributor Author

@curquiza I added some tests. Could you please review it again?
Thank you

@curquiza curquiza added the enhancement New feature or request label Jan 24, 2024
Copy link
Member

@curquiza curquiza left a comment

Choose a reason for hiding this comment

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

thank you @jonaskahn

bors merge

Copy link
Contributor

meili-bors bot commented Jan 29, 2024

Build succeeded:

  • integration-and-unit-tests
  • linter

@meili-bors meili-bors bot merged commit 02068d5 into meilisearch:main Jan 29, 2024
3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants