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

   ### What happened
   
   The Studio alert-management page still exposes row selection, but 
`handleExportYaml` ignores the selected rows and always calls the unfiltered 
`/api/alert-rules/export` endpoint. As a result, selecting one enabled rule 
downloads every enabled rule.
   
   The same export path infers every custom `rocketmq_proxy_*` metric as the 
`broker` team because `AlertService.inferTeam` and the Studio mapping helper 
have no Proxy branch. Generated YAML therefore places Proxy rules under 
`rocketmq-broker.rules` with `team: broker`, even though the bundled Proxy 
rules use `rocketmq-proxy.rules` and `team: proxy`.
   
   ### Expected behavior
   
   - When enabled rows are selected, export only those persisted rules.
   - When no rows are selected, preserve the current behavior and export all 
enabled rules (or bundled defaults when no configured rules are enabled).
   - Classify `rocketmq_proxy_*` rules under `rocketmq-proxy.rules` with `team: 
proxy`.
   - Reject stale/disabled selected IDs instead of silently falling back to an 
unrelated full/default export.
   
   ### Evidence
   
   - `web/src/pages/studio/AlertManagement.tsx`: `selectedRules` is derived 
from table selection, but `handleExportYaml` calls `exportAlertRulesYaml()` 
without passing it.
   - 
`server/src/main/java/org/apache/rocketmq/studio/ops/alert/AlertService.java`: 
`exportPrometheusRulesYaml()` always loads all enabled repository rules; 
`inferTeam()` and `groupName()` have no Proxy branch.
   - Bundled `rocketmq-proxy-*.yaml` assets already use the expected Proxy 
group/team contract.
   
   ### Scope
   
   Track 1 / unified control-plane alert and metrics management. The export API 
change should remain backward compatible for callers that do not provide rule 
IDs.


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