-
Notifications
You must be signed in to change notification settings - Fork 2
Handle table no search result #904
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
Conversation
WalkthroughThe changes update the pagination logic in the Changes
Sequence Diagram(s)sequenceDiagram
participant Client
participant Repository as HandleRestRepository
participant Service as handleClarinService
Client->>Repository: Call findAll(Pageable)
Repository->>Service: Retrieve list of handles
Service-->>Repository: Return total handles list
alt Offset > total handles
Repository->>Repository: Calculate last valid page & create new PageRequest
end
Repository->>Client: Return paginated results
Poem
📜 Recent review detailsConfiguration used: CodeRabbit UI 📒 Files selected for processing (1)
⏰ Context from checks skipped due to timeout of 90000ms (3)
🔇 Additional comments (2)
✨ Finishing Touches
🪧 TipsChatThere are 3 ways to chat with CodeRabbit:
Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments. CodeRabbit Commands (Invoked using PR comments)
Other keywords and placeholders
CodeRabbit Configuration File (
|
milanmajchrak
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
When you get wrong pageable object I think the problem could be somewhere in the UI
|
@milanmajchrak |
|
Fixed here dataquest-dev/dspace-angular#822 |
Problem description
There are no search results for some handles.

Problems
There is an issue with the pageable in the findAll endpoint. When we search for all results for the handle, the pageable is set to 20 in some cases. As a result, an exception occurs when trying to paginate the results, because the pageable is larger than the size of the result.
Solution
Calculate the pageable based on the size of the result.
Summary by CodeRabbit