Class DelegatingSecurityContextAsyncTaskExecutor
java.lang.Object
org.springframework.security.concurrent.DelegatingSecurityContextExecutor
org.springframework.security.task.DelegatingSecurityContextTaskExecutor
org.springframework.security.task.DelegatingSecurityContextAsyncTaskExecutor
- All Implemented Interfaces:
- Executor,- org.springframework.core.task.AsyncTaskExecutor,- org.springframework.core.task.TaskExecutor
- Direct Known Subclasses:
- DelegatingSecurityContextSchedulingTaskExecutor
public class DelegatingSecurityContextAsyncTaskExecutor
extends DelegatingSecurityContextTaskExecutor
implements org.springframework.core.task.AsyncTaskExecutor
An 
AsyncTaskExecutor which wraps each Runnable in a
 DelegatingSecurityContextRunnable and each Callable in a
 DelegatingSecurityContextCallable.- Since:
- 3.2
- 
Field SummaryFields inherited from interface org.springframework.core.task.AsyncTaskExecutorTIMEOUT_IMMEDIATE, TIMEOUT_INDEFINITE
- 
Constructor SummaryConstructorsConstructorDescriptionDelegatingSecurityContextAsyncTaskExecutor(org.springframework.core.task.AsyncTaskExecutor delegateAsyncTaskExecutor) Creates a newDelegatingSecurityContextAsyncTaskExecutorthat uses the currentSecurityContext.DelegatingSecurityContextAsyncTaskExecutor(org.springframework.core.task.AsyncTaskExecutor delegateAsyncTaskExecutor, SecurityContext securityContext) Creates a newDelegatingSecurityContextAsyncTaskExecutorthat uses the specifiedSecurityContext.
- 
Method SummaryMethods inherited from class org.springframework.security.concurrent.DelegatingSecurityContextExecutorexecute, getDelegateExecutor, setSecurityContextHolderStrategyMethods inherited from class java.lang.Objectclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface org.springframework.core.task.AsyncTaskExecutorsubmitCompletable, submitCompletableMethods inherited from interface org.springframework.core.task.TaskExecutorexecute
- 
Constructor Details- 
DelegatingSecurityContextAsyncTaskExecutorpublic DelegatingSecurityContextAsyncTaskExecutor(org.springframework.core.task.AsyncTaskExecutor delegateAsyncTaskExecutor, SecurityContext securityContext) Creates a newDelegatingSecurityContextAsyncTaskExecutorthat uses the specifiedSecurityContext.- Parameters:
- delegateAsyncTaskExecutor- the- AsyncTaskExecutorto delegate to. Cannot be null.
- securityContext- the- SecurityContextto use for each- DelegatingSecurityContextRunnableand- DelegatingSecurityContextCallable
 
- 
DelegatingSecurityContextAsyncTaskExecutorpublic DelegatingSecurityContextAsyncTaskExecutor(org.springframework.core.task.AsyncTaskExecutor delegateAsyncTaskExecutor) Creates a newDelegatingSecurityContextAsyncTaskExecutorthat uses the currentSecurityContext.- Parameters:
- delegateAsyncTaskExecutor- the- AsyncTaskExecutorto delegate to. Cannot be null.
 
 
- 
- 
Method Details- 
execute- Specified by:
- executein interface- org.springframework.core.task.AsyncTaskExecutor
 
- 
submit- Specified by:
- submitin interface- org.springframework.core.task.AsyncTaskExecutor
 
- 
submit- Specified by:
- submitin interface- org.springframework.core.task.AsyncTaskExecutor
 
- 
wrap
- 
wrap
 
-