You are viewing a plain text version of this content. The canonical link for it is here.
Posted to oak-issues@jackrabbit.apache.org by "Chetan Mehrotra (JIRA)" <ji...@apache.org> on 2013/06/19 16:21:19 UTC
[jira] [Updated] (OAK-863) Enable stats for various caches used in
Oak by default
[ https://issues.apache.org/jira/browse/OAK-863?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Chetan Mehrotra updated OAK-863:
--------------------------------
Issue Type: Sub-task (was: Improvement)
Parent: OAK-865
> Enable stats for various caches used in Oak by default
> ------------------------------------------------------
>
> Key: OAK-863
> URL: https://issues.apache.org/jira/browse/OAK-863
> Project: Jackrabbit Oak
> Issue Type: Sub-task
> Reporter: Chetan Mehrotra
> Assignee: Chetan Mehrotra
> Priority: Minor
>
> To get a better picture around the usage of cache it would be helpful to enable the [statistics|http://code.google.com/p/guava-libraries/wiki/CachesExplained#Statistics] for various caches used in Oak
> {code:java}
> nodeCache = CacheBuilder.newBuilder()
> .weigher(...)
> .maximumWeight(...)
> .recordStats()
> .build();
> {code}
> Once enabled it allows to get stats like below
> {noformat}
> CacheStats{hitCount=763322, missCount=51333, loadSuccessCount=0, loadExceptionCount=0, totalLoadTime=0, evictionCount=3496}
> {noformat}
> As stats collection adds a very minor overhead we can look into making this setting configurable.
> Untill we expose the stats via JMX one can extract the value in Sling env via approach mentioned in [this gist|https://gist.github.com/chetanmeh/5748650]
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira