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

   **Issue Evaluation**
   
   Category: `type/bug` | Status: **Confirmed**
   
   The Prometheus step/duration validator accepts inputs like `15` (no unit) 
and `1h2x` (invalid suffix `x`) because the regex pattern is too permissive. 
These invalid values then cause Prometheus HTTP API calls to fail.
   
   **Root Cause:** Overly lenient regex pattern in the metrics configuration 
validator that does not enforce Prometheus duration format (`[0-9]+[smhd]`).
   **Impact:** Invalid duration values are accepted at configuration time but 
fail at query time, producing confusing errors.
   **Severity:** low
   
   Suggested fix: Tighten the regex to match the Prometheus duration format 
strictly, e.g. `^[0-9]+[smhdwy]$`.
   
   An automated fix proposal can be generated. Reply `/approve` to proceed with 
PR generation.
   
   ---
   *Automated evaluation by RockteMQ-AI*


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