You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@rocketmq.apache.org by "yyqdbngt (via GitHub)" <gi...@apache.org> on 2026/09/05 13:52:57 UTC

[PR] test(metrics): deepen alert collection lease coverage [rocketmq-dashboard]

yyqdbngt opened a new pull request, #3369:
URL: https://github.com/apache/rocketmq-dashboard/pull/3369

   ## Summary
   
   Extends the existing `MybatisPlusAlertCollectionLeaseTest` (2 to 6 tests) to pin down the lease acquisition paths that were untested.
   
   Added cases:
   - `tryAcquire` renews the live row when the conditional update succeeds (no insert happens);
   - when no live row can be renewed, `tryAcquire` inserts its own row sharing the acquire-attempt holder id and lease name;
   - the insert-race is lost gracefully when another replica inserts first (`DuplicateKeyException` → false);
   - `renew` falls back to a one-minute lease window for a malformed configured duration (window asserted via argument capture).
   
   ## Why
   
   The lease coordinates native collection across replicas; the upstream suite covered only the two `renew` outcomes.
   
   ## Testing
   
   `mvn -B test -Dtest=MybatisPlusAlertCollectionLeaseTest` — 6/6 pass; checkstyle (validate) clean.


-- 
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] test(metrics): deepen alert collection lease coverage [rocketmq-dashboard]

Posted by "lizhimins (via GitHub)" <gi...@apache.org>.
lizhimins closed pull request #3369: test(metrics): deepen alert collection lease coverage
URL: https://github.com/apache/rocketmq-dashboard/pull/3369


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