com.ibm.websphere.batch

Interface RetryListener


  1. public interface RetryListener
RetryListener defines the callback interface for job step failure-retry processing.

The RetryListener gets control at several points during job step failure and retry.

The RetryListener is registered with the JobStepContext via JobStepContext.addRetryListener(RetryListener).

For example:

 JobStepContext jsCtx= JobStepContextMgr.getContext();
 jsCtx.addRetryListener(new MyRetryListener());
 

Method Summary

Modifier and Type Method and Description
  1. void
onError(java.lang.Throwable t)
This method gets called after the error occurs and before the transaction rolls back.
  1. void
onRetry(java.lang.Throwable t)
This method gets control before the job step is restarted.

Method Detail

onError

  1. void onError(java.lang.Throwable t)
This method gets called after the error occurs and before the transaction rolls back.
Parameters:
t - The error that caused the retry.

onRetry

  1. void onRetry(java.lang.Throwable t)
This method gets control before the job step is restarted.
Parameters:
t - The error that caused the retry.