You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@rocketmq.apache.org by "ai-yang (via GitHub)" <gi...@apache.org> on 2026/08/02 04:16:23 UTC

[PR] [studio] fix: reject ACL rule updates for unknown IDs [rocketmq-dashboard]

ai-yang opened a new pull request, #758:
URL: https://github.com/apache/rocketmq-dashboard/pull/758

   ## Summary
   
   - give ACL rule updates atomic replace semantics instead of unconditional upsert semantics
   - return `404` when the requested rule ID no longer exists
   - preserve the stored creation timestamp during a successful replacement without mutating the request object
   - cover the service/repository behavior and the controller error response
   
   Fixes #757.
   
   ## Root cause
   
   `AclService.updateRule` delegated to the same `saveRule` operation as the create path. The in-memory repository implements that operation with `ConcurrentHashMap.put`, so an update for an unknown ID silently inserted a new rule and returned success. The replacement now uses `computeIfPresent` and publishes a detached value while retaining the stored `createdAt`.
   
   ## Verification
   
   - unmodified Java 21 baseline: deterministic regression failed in 5/5 isolated Maven processes
   - fixed targeted regressions: 20 isolated Java 21 Maven processes, 3/3 each (60/60)
   - complete backend suite: 489 tests, 0 failures, 0 errors, 0 skipped
   - Maven package: passed
   - Checkstyle: passed
   - `git diff --check`: passed
   


-- 
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] [studio] fix: reject ACL rule updates for unknown IDs [rocketmq-dashboard]

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


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