com.ibm.wsspi.batch

Class LifeCycle

  • All Implemented Interfaces:
    java.lang.Comparable


    public abstract class LifeCycle
    extends SPI
    LifeCycle is the abstract base class for the LifeCycle System Programming Interface (SPI). Use the LifeCycle SPI to receive job state change notifications. Each time a job transitions from one state to another, this SPI is invoked, indicating the new state for the affected job.

    Implement the LifeCycle SPI, by extending this class and implementing the stateChanged method.

    Configure this SPI with the following declaration in the xd.spi.properties file:

     spi.LifeCycle=<fully-qualified implementation class name>
     

    Notes:

    1. The xd.spi.properties file is located in:

       <WAS install root>/properties.  E.g.
       
             /WebSphere/AppServer/properties
       
    2. The jar file containing the implementation of this SPI should be stored in:

       <WAS install root>/lib/classes.  E.g.
       
             /WebSphere/AppServer/lib/classes
       
      You are responsible for creating the classes directory if it does not already exist.
    • Constructor Summary

      Constructors 
      Constructor and Description
      LifeCycle() 
    • Method Summary

      Methods 
      Modifier and Type Method and Description
      java.lang.String getName()
      Returns the name of this SPI instance.
      abstract void stateChanged(java.lang.String jobID, int newState)
      Callback invoked by job scheduler when a job changes state.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
    • Constructor Detail

      • LifeCycle

        public LifeCycle()
    • Method Detail

      • stateChanged

        public abstract void stateChanged(java.lang.String jobID,
                        int newState)
        Callback invoked by job scheduler when a job changes state.
        Parameters:
        jobID - specifies the job ID of the job that has changed state.
        newState - specifies the new state of the job.
        See Also:
        Job State Constants
      • getName

        public java.lang.String getName()
        Description copied from class: SPI
        Returns the name of this SPI instance. Should return a unique identifier.
        Specified by:
        getName in class SPI
IBM WebSphere Application ServerTM
Release 8.5