CaffeineCache description

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|

CaffeineCache description

Dawn
Hi:

Using CaffeineCache as the cache, if maxRamMB is set at the interface, it is not clearly shown in the description.

It is recommended that the maxRamMB cleanupThread maxIdleTime parameter  in the description.

Solr8.7.0, 9.*

Now:



After:
/** Returns the description of this cache. */
private String generateDescription() {
int maxRamBytes = maxRamBytes != Long.MAX_VALUE ? (maxRamBytes / (1024L * 1024L)) : -1;
return String.format(Locale.ROOT, "TinyLfu Cache(maxSize=%d, initialSize=%d, maxIdleTimeSec=%d, maxRamMB=%d, cleanupThread=%b%s)",
this.maxSize, initialSize, maxIdleTimeSec, maxRamBytes, cleanupThread, isAutowarmingOn() ? (", " + getAutowarmDescription()) : "");
}