Aias00 opened a new issue, #4515:
URL: https://github.com/apache/rocketmq-dashboard/issues/4515

   ### Before Creating the Bug Report
   
   - [x] I searched open and closed issues and pull requests for alert rule 
filter loading, stale rows, page refresh, and table request ownership.
   - [x] I verified the behavior on current `master` 
(`987b748e8f4f421c5cd3c4c4e51a064cc7e59f18`).
   
   ### Problem
   
   The native Alert Rules page initializes `loading=true` and explicitly 
re-enters loading when the route changes between CLUSTER and BUSINESS domains. 
The normal server-page effect, however, never sets loading back to true when 
search text, enabled status, pagination, page size, refresh version, or 
language changes. Its completion path only sets loading to false.
   
   After the first load, each of those changes leaves the previous rows and 
total visible without a loading boundary while the replacement request is 
pending. Row enable/edit/delete controls, row selection, and bulk actions 
remain actionable against records from the previous query scope.
   
   The effect cleanup prevents an older response from publishing after 
dependencies change, so this is not a stale-response race. The missing behavior 
is the visible and interactive loading boundary for the current request.
   
   ### Impact
   
   Operators can mutate or select rules that no longer belong to the active 
search, status filter, page, or refreshed inventory. The screen also presents 
the previous result set as current until the server responds, which is 
misleading during alert administration.
   
   ### Proposed Design
   
   Keep the existing request effect and cancellation behavior:
   
   1. Re-enter `loading=true` whenever the rule-page request effect starts.
   2. Keep current rows mounted behind the Ant Design table loading overlay so 
layout remains stable and actions are blocked while the replacement page is 
pending.
   3. Keep the existing domain-change render-time reset and response 
cancellation guard unchanged.
   4. Do not add search debouncing or change the Alert Rule API in this fix.
   
   Because the repository lint rule rejects synchronous state writes at the top 
of an effect, schedule the loading transition through the same guarded 
microtask pattern already used by other server-backed tables.
   
   ### Acceptance Criteria
   
   - Search, enabled-status, page, page-size, and refresh changes show the 
table loading state until the current request settles.
   - Existing rows are not actionable while the replacement request is pending.
   - Loading clears on both success and failure for the current request.
   - Superseded responses remain unable to publish.
   - Domain switching continues to clear old-domain rows and filters 
immediately.
   - A deferred-promise frontend regression fails on current master and passes 
after the fix.
   - Focused tests, frontend lint/build, formatting, and `git diff --check` 
pass.
   
   AI-assisted source audit; behavior was verified from the current effect, 
table loading binding, and action controls.


-- 
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