-
Notifications
You must be signed in to change notification settings - Fork 13
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
List: add pagination support #321
Merged
Merged
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Codecov Report
@@ Coverage Diff @@
## main #321 +/- ##
==========================================
- Coverage 74.50% 73.41% -1.09%
==========================================
Files 16 16
Lines 1961 2024 +63
==========================================
+ Hits 1461 1486 +25
- Misses 454 492 +38
Partials 46 46
Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here. |
a015d03
to
cbfe5a9
Compare
If API returned partial result: - generate new NextPageToken based on UUID - return the token in the responce - save the token to re-use later on - Empty NextPageToken indicates end of results list Token expiration is not implemeted yet. Signed-off-by: Boris Glimcher <[email protected]>
Signed-off-by: Boris Glimcher <[email protected]>
Signed-off-by: Boris Glimcher <[email protected]>
According to Google AIP, if PageSize is zero means not provided by user, reasonable default value should be used Signed-off-by: Boris Glimcher <[email protected]>
According to Google AIP, max PageSize value shoould be limited to a reasonable max value Signed-off-by: Boris Glimcher <[email protected]>
introduce new ExtractPagination function Signed-off-by: Boris Glimcher <[email protected]>
introduce new LimitPagination function Signed-off-by: Boris Glimcher <[email protected]>
Code review comments Signed-off-by: Boris Glimcher <[email protected]>
Signed-off-by: Boris Glimcher <[email protected]>
Code review comments Signed-off-by: Boris Glimcher <[email protected]>
Signed-off-by: Boris Glimcher <[email protected]>
artek-koltun
approved these changes
Apr 12, 2023
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
see https://google.aip.dev/132 and https://google.aip.dev/158
If API returned partial result:
If non empty token received in API request:
Token expiration is not implemeted yet.
Signed-off-by: Boris Glimcher [email protected]