-
-
Save tobias/c9575eec411174ae7829 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public static CacheContainer<?> cacheContainerWithDefaults(final String name) { | |
return new CacheContainer<>(name) | |
// from https://github.com/wildfly/wildfly/tree//clustering/infinispan/extension/src/main/java/org/jboss/as/clustering/infinispan/subsystem/ThreadPoolResourceDefinition.java#L71 | |
.asyncOperationsThreadPool(p -> p.minThreads(25) | |
.maxThreads(25) | |
.queueLength(1000) | |
.keepaliveTime(60000L)) | |
.listenerThreadPool(p -> p.minThreads(1) | |
.maxThreads(1) | |
.queueLength(100000) | |
.keepaliveTime(60000L)) | |
.persistenceThreadPool(p -> p.minThreads(1) | |
.maxThreads(4) | |
.queueLength(0) | |
.keepaliveTime(60000L)) | |
.remoteCommandThreadPool(p -> p.minThreads(1) | |
.maxThreads(200) | |
.queueLength(0) | |
.keepaliveTime(60000L)) | |
.stateTransferThreadPool(p -> p.minThreads(1) | |
.maxThreads(60) | |
.queueLength(0) | |
.keepaliveTime(60000L)) | |
.transportThreadPool(p -> p.minThreads(25) | |
.maxThreads(25) | |
.queueLength(100000) | |
.keepaliveTime(60000L)) | |
// from https://github.com/wildfly/wildfly/tree//clustering/infinispan/extension/src/main/java/org/jboss/as/clustering/infinispan/subsystem/ScheduledThreadPoolResourceDefinition.java#L72 | |
.expirationThreadPool(p -> p.maxThreads(1) | |
.keepaliveTime(60000L)) | |
.noneTransport(); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment