xujiantop-crypto opened a new pull request, #11225:
URL: https://github.com/apache/rocketmq/pull/11225

   ## What is changed?
   
   Fixes #11189.
   
   The ACL and user managers previously modified objects returned from the 
local Caffeine caches before persisting them. The authorization/authentication 
hot paths could therefore observe partially updated state, and a failed 
persistence operation could leave the in-memory value changed.
   
   This change builds a defensive copy before applying updates or deletions:
   
   - deep-copy `User`, `Acl`, `Policy`, and `PolicyEntry` metadata;
   - apply manager mutations to the copy and persist only that copy;
   - add regression assertions that the cached old value remains unchanged 
after an update.
   
   ## How was this tested?
   
   - `git diff --check` passed.
   - Attempted: `mvn -pl auth 
"-Dtest=AuthenticationMetadataManagerTest,AuthorizationMetadataManagerTest" 
-DfailIfNoTests=false -Djacoco.skip=true -Dcheckstyle.skip=true 
-Dspotless.check.skip=true -DskipITs test`
   - Maven could not enter compilation because the local Maven configuration 
points to an unavailable/unwritable 
`D:\software\maven\apache-maven-3.8.8\repo`; no test result is claimed from 
that run.


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