You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@rocketmq.apache.org by "Loyal-Young (via GitHub)" <gi...@apache.org> on 2026/10/12 16:44:42 UTC

[PR] fix(alert): retain runtime state for equivalent duration edits [rocketmq-dashboard]

Loyal-Young opened a new pull request, #6446:
URL: https://github.com/apache/rocketmq-dashboard/pull/6446

   ### Which Issue(s) This PR Fixes
   
   Fixes #6441
   
   ### Brief Description
   
   Editing a duration from `60s` to `1m` cleared native alert evaluation state, losing pending progress or acknowledgement despite identical evaluation conditions. Add a runtime identity that compares parsed durations and use it only for the state-reset decision in updateRule.
   
   The persisted unique fingerprint keeps its existing format and duplicate-detection behavior. No index/data migration is needed. Legacy malformed durations retain their prior normalized-text comparison; actual duration changes and disabled-rule cleanup still reset state.
   
   ### How Did You Test This Change?
   
   - Java 21 `mvn -B -ntp test -Dtest=AlertServiceTest,AlertRuleSemanticFingerprintTest`: **94 passed**, no failures/errors/skips.
   - All four new equivalent-duration update cases failed on the original implementation by invoking deleteByRuleId. A real duration-change control verifies cleanup still occurs.
   - Added controls for persisted identity compatibility and malformed legacy text. Existing duplicate-detection tests remain green.
   - Maven Checkstyle: 0 violations; `git diff --check`: passed.
   
   No live database/broker integration or full Maven suite was run. No ArchitectureTest class exists in this snapshot, so no ArchUnit execution is claimed.
   
   ### Checklist
   
   - [x] One coherent fix with regression tests ending in `Test`
   - [x] Conventional Commit subject; no new files or UI strings
   
   ### AI Assistance
   
   AI assistance was used to trace the state-reset and persisted-fingerprint callers, draft the scoped correction and regression tests, and execute the checks above.
   


-- 
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: commits-unsubscribe@rocketmq.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [PR] fix(alert): retain runtime state for equivalent duration edits [rocketmq-dashboard]

Posted by "lizhimins (via GitHub)" <gi...@apache.org>.
lizhimins merged PR #6446:
URL: https://github.com/apache/rocketmq-dashboard/pull/6446


-- 
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: commits-unsubscribe@rocketmq.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org