You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@shardingsphere.apache.org by GitBox <gi...@apache.org> on 2022/03/07 14:11:31 UTC
[GitHub] [shardingsphere] TeslaCN opened a new issue #15858: Possibly poor performance in OrderedServicesCache's cache
TeslaCN opened a new issue #15858:
URL: https://github.com/apache/shardingsphere/issues/15858
## Performance
The overhead of `org.apache.shardingsphere.spi.ordered.OrderedSPIRegistry` is a little heavy.
<img width="1663" alt="image" src="https://user-images.githubusercontent.com/20503072/157048884-072ff83f-0c62-4c83-89d7-5b9f5fb5c80d.png">
I try replacing Guava cache with ConcurrentHashMap in `org.apache.shardingsphere.spi.ordered.cache.OrderedServicesCache` and found the overhead is reduced.
```java
private static final Map<Key, Map<?, ?>> CACHED_SERVICES = new ConcurrentHashMap<>();
```
But the ConcurrentHashMap is strong reference, we may need a higher-performance cache implementation.
--
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: notifications-unsubscribe@shardingsphere.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [shardingsphere] terrymanu closed issue #15858: Possibly poor performance in OrderedServicesCache's cache
Posted by GitBox <gi...@apache.org>.
terrymanu closed issue #15858:
URL: https://github.com/apache/shardingsphere/issues/15858
--
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: notifications-unsubscribe@shardingsphere.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org