tju-yxq commented on PR #3646:
URL: 
https://github.com/apache/rocketmq-dashboard/pull/3646#issuecomment-5584530938

   Thanks for catching this — the review is correct. The frontend's 
`alertRulePath` helper routes the CLUSTER domain to `/api/cluster-alert-rules`, 
but my summary endpoint was only added to the legacy shared controller 
(`/api/alert-rules` + `/api/business-alert-rules`). The cluster page therefore 
always fell back to page-local counters.
   
   Fixed in 143c17b8 (also rebased onto the current `rocketmq-studio`):
   
   - `ClusterAlertRuleController` now serves `GET 
/api/cluster-alert-rules/summary`, forwarding `search` and `enabled` to 
`alertService.summarizeRules(AlertDomain.CLUSTER, ...)` with the same 24-hour 
triggered window as the other routes.
   - Added 
`ClusterAlertRuleControllerTest.summarizeRulesShouldUseClusterDomainTest` 
covering the route, filter forwarding, and response contract.
   
   Validation on the rebased branch:
   
   - `mvn 
'-Dtest=AlertServiceTest,AlertRuleControllerTest,ClusterAlertRuleControllerTest,MybatisPlusAlertRepositoryTest'
 test` — 124 tests passed
   - `mvn checkstyle:check` — 0 violations
   - `npm test -- AlertsPage.test.tsx alerts.test.ts --run` — 40 tests passed
   - `npm run lint -- --quiet` — 0 errors
   - `npm run build` — passed
   
   


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