lhotari commented on code in PR #25293: URL: https://github.com/apache/pulsar/pull/25293#discussion_r2904124934
########## pulsar-broker/src/main/java/org/apache/pulsar/utils/SimpleCache.java: ########## Review Comment: Just wondering if this we could use `ConcurrentHashMap` here to reduce locking further. In that case, it should be possible to eliminate `synchronized` for the `getWithCacheInfo` and `get` methods. Since there's need for locking for expiration handling, it should be done in the `ExpirableValue` class. The `ExpirableValue` could hold expired state which could be reset if the `ExpirableValue` isn't removed from the cache before it gets reactivated. -- 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]
