public class DelegatingExecutor extends Object implements org.springframework.core.task.TaskExecutor
In addition to the delegate, the async configuration properties and the task name is stored, so we know which task this executor is for and we are able to determine the timeout.
Constructor and Description |
---|
DelegatingExecutor(org.springframework.scheduling.concurrent.ThreadPoolTaskExecutor delegate,
ExecutorConfigurationProperties executorConfigurationProperties,
String taskName)
Constructor.
|
Modifier and Type | Method and Description |
---|---|
void |
execute(Runnable task) |
ExecutorStatisticsView |
getExecutorStatistics()
Return the view on the statistics.
|
public DelegatingExecutor(org.springframework.scheduling.concurrent.ThreadPoolTaskExecutor delegate, ExecutorConfigurationProperties executorConfigurationProperties, String taskName)
delegate
- the delegateexecutorConfigurationProperties
- the configuration propertiestaskName
- the task namepublic void execute(Runnable task)
Configures a SharedTaskContextHolder
before delegating execution.
public ExecutorStatisticsView getExecutorStatistics()