yangjj-iso opened a new pull request, #6876: URL: https://github.com/apache/rocketmq-dashboard/pull/6876
### Which Issue(s) This PR Fixes Fixes #6875 ### Brief Description The rule editor's test run evaluated raw samples even when a window aggregation was configured. Share the stored-window aggregation implementation between rule tests and live evaluations so the preview's `currentValue` and `conditionMet` reflect the same condition. For a 300-second AVG window containing `[500, 500, 10]`, the test run now reports approximately `336.67` and matches `> 100`, instead of reporting `10` and a non-match. Rule tests remain read-only, and live aggregation behavior is preserved. Add regression coverage for aggregation modes and defaults, metric/resource filtering, cluster metrics, disabled or empty windows, and unavailable samples. ### How Did You Test This Change? ```sh mvn -f server/pom.xml -B -ntp "-Dtest=org.apache.rocketmq.studio.ops.alert.*Test,MybatisPlusMetricSnapshotRepositoryTest,TencentCloudLagFailureScopeTest" "-Dspring.profiles.active=dev" test ``` 449 tests passed with no failures, errors, or skips using the H2 dev profile. Checkstyle reported 0 violations. The rule-test regression suite failed on the original evaluation path before the fix and passes after it. ### Checklist - [x] One coherent change; unrelated modifications are not bundled in - [x] Commit subject follows Conventional Commits - [x] Tests added or updated for non-trivial changes, test methods named `...Test` - [x] New UI text has both Chinese and English entries (not applicable: no UI text changes) - [ ] Architecture constraints stay green (full backend suite left to CI; focused validation is listed above) - [x] New source files carry the ASF license header - [x] Documentation touched where behaviour changed (not applicable: restores the existing window aggregation behavior in the preview) -- 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]
