Surya00011 opened a new pull request, #8399:
URL: https://github.com/apache/gravitino/pull/8399

   ### What changes were proposed in this pull request?
   
   - Made `JsonCodec` thread-safe by marking `mapper` and `jsonType` as 
`volatile`.
   - Applied double-checked locking in `getMapper` and `getJsonType` to ensure 
proper lazy initialization in concurrent scenarios.
   - No functional changes to the JSON serialization/deserialization behavior.
   
   ### Why are the changes needed?
   
   - `JsonCodec` was not thread-safe: concurrent access to `mapper` and 
`jsonType` could cause race conditions or inconsistent initialization.
   
   Fix: #8385
   
   ### Does this PR introduce  any user-facing change?
   
   - No user-facing API changes.
   - No properties or configuration keys were added or removed.
   - Existing functionality behaves identically, but now safely under 
concurrent access.


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