RockteMQ-AI commented on issue #2542:
URL: 
https://github.com/apache/rocketmq-dashboard/issues/2542#issuecomment-5380553803

   **Issue Evaluation**
   
   Category: `enhancement` | Status: **Evaluated**
   
   **Feasibility:** Feasible
   **Scope:** Backend instance controller/service + frontend instance 
management page
   **Compatibility:** Backward-compatible (existing unpaginated endpoint 
preserved for instance selector usage)
   
   This is a well-scoped improvement. The current design loads the full 
inventory in a single request, which degrades as operators import more cloud 
instances. Adding server-side pagination aligns with the pattern already used 
by other management pages (cloud credentials, data sources, Studio users, query 
history).
   
   **Key observations:**
   - The proposed `GET /api/instances/page` contract (`items`, `total`, `page`, 
`size`) is consistent with the other paginated endpoints in the dashboard.
   - Keeping the existing unpaginated endpoint for instance selector usage is 
the right call — avoids breaking downstream consumers.
   - Validation of `page`/`pageSize` before repository or provider access 
prevents unnecessary work on invalid requests.
   - Resetting to page 1 on filter change is standard UX behavior and should be 
straightforward.
   
   **Suggested implementation order:**
   1. Backend: add paginated endpoint with validation and slice selection
   2. Backend: add unit tests for pagination params, boundary cases, and filter 
interaction
   3. Frontend: update API client to call the new paginated endpoint
   4. Frontend: wire up server-driven pagination component with 20/50/100 page 
sizes
   5. Frontend: reset to page 1 when search/type filters change
   
   ---
   *Automated evaluation by github-manager*


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to