@Factory public class ExecutorFactory extends java.lang.Object
ExecutorService
instances based on UserExecutorConfiguration
instances.Constructor and Description |
---|
ExecutorFactory(java.util.concurrent.ThreadFactory threadFactory) |
Modifier and Type | Method and Description |
---|---|
java.util.concurrent.ExecutorService |
executorService(ExecutorConfiguration executorConfiguration)
Create the ExecutorService with the given configuration.
|
public ExecutorFactory(java.util.concurrent.ThreadFactory threadFactory)
threadFactory
- The factory to create new threads@EachBean(value=ExecutorConfiguration.class) @Bean(preDestroy="shutdown") public java.util.concurrent.ExecutorService executorService(ExecutorConfiguration executorConfiguration)
executorConfiguration
- The configuration to create a thread pool that creates new threads as needed