Class ExceptionHandlingAsyncTaskExecutor

  • All Implemented Interfaces:
    Executor, org.springframework.beans.factory.DisposableBean, org.springframework.beans.factory.InitializingBean, org.springframework.core.task.AsyncTaskExecutor, org.springframework.core.task.TaskExecutor

    public class ExceptionHandlingAsyncTaskExecutor
    extends Object
    implements org.springframework.core.task.AsyncTaskExecutor, org.springframework.beans.factory.InitializingBean, org.springframework.beans.factory.DisposableBean

    ExceptionHandlingAsyncTaskExecutor class.

    • Constructor Detail

      • ExceptionHandlingAsyncTaskExecutor

        public ExceptionHandlingAsyncTaskExecutor​(org.springframework.core.task.AsyncTaskExecutor executor)

        Constructor for ExceptionHandlingAsyncTaskExecutor.

        Parameters:
        executor - a AsyncTaskExecutor object.
    • Method Detail

      • execute

        public void execute​(Runnable task)
        Specified by:
        execute in interface Executor
        Specified by:
        execute in interface org.springframework.core.task.TaskExecutor
      • execute

        public void execute​(Runnable task,
                            long startTimeout)
        Specified by:
        execute in interface org.springframework.core.task.AsyncTaskExecutor
      • handle

        protected void handle​(Exception e)

        handle.

        Parameters:
        e - a Exception object.
      • submit

        public Future<?> submit​(Runnable task)
        Specified by:
        submit in interface org.springframework.core.task.AsyncTaskExecutor
      • submit

        public <T> Future<T> submit​(Callable<T> task)
        Specified by:
        submit in interface org.springframework.core.task.AsyncTaskExecutor
      • destroy

        public void destroy()
                     throws Exception
        Specified by:
        destroy in interface org.springframework.beans.factory.DisposableBean
        Throws:
        Exception
      • afterPropertiesSet

        public void afterPropertiesSet()
                                throws Exception
        Specified by:
        afterPropertiesSet in interface org.springframework.beans.factory.InitializingBean
        Throws:
        Exception