org.springframework.integration.util
Class ErrorHandlingTaskExecutor

java.lang.Object
  extended by org.springframework.integration.util.ErrorHandlingTaskExecutor
All Implemented Interfaces:
org.springframework.core.task.TaskExecutor

public class ErrorHandlingTaskExecutor
extends java.lang.Object
implements org.springframework.core.task.TaskExecutor

A TaskExecutor implementation that wraps an existing TaskExecutor instance in order to catch any exceptions. If an exception is thrown, it will be handled by the provided ErrorHandler.

Author:
Jonas Partner, Mark Fisher

Constructor Summary
ErrorHandlingTaskExecutor(org.springframework.core.task.TaskExecutor taskExecutor, ErrorHandler errorHandler)
           
 
Method Summary
 void execute(java.lang.Runnable task)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ErrorHandlingTaskExecutor

public ErrorHandlingTaskExecutor(org.springframework.core.task.TaskExecutor taskExecutor,
                                 ErrorHandler errorHandler)
Method Detail

execute

public void execute(java.lang.Runnable task)
Specified by:
execute in interface org.springframework.core.task.TaskExecutor