psdi.common.asyncjob

Class AsyncJobSubmitter

    • Constructor Detail

      • AsyncJobSubmitter

        public AsyncJobSubmitter(MboServerInterface ms)
                          throws java.rmi.RemoteException
        Construct the set of Custom Mbos.
        Parameters:
        ms - The MboServerInterface CustomMboSet uses to access internals of the MXServer.
        Throws:
        java.rmi.RemoteException
    • Method Detail

      • getMboInstance

        protected abstract Mbo getMboInstance(MboSet ms)
                                       throws MXException,
                                              java.rmi.RemoteException
        The derived class needs to provide the actual non-persistent object
        Specified by:
        getMboInstance in class MboSet
        Throws:
        MXException
        java.rmi.RemoteException
      • getAsyncJobHandlerClassName

        public abstract java.lang.String getAsyncJobHandlerClassName()
        Returns the job handler class name that will be written to the queue when job is created.
        Returns:
      • getCompleteWhereClause

        public abstract java.lang.String getCompleteWhereClause()
        Get the where clause to identify one or more records of the main object that the async process is to apply on. Normally it is obtained from the owner set of the non-persistent mbo set.
        Returns:
      • getObjectName

        public abstract java.lang.String getObjectName()
        Returns the main object name that this async process will operate on.
        Returns:
      • getParameters

        public java.util.ArrayList getParameters()
                                          throws MXException,
                                                 java.rmi.RemoteException
        Returns an array of the parameter name, value and maxtype that are needed if the parameters from the job is retrieved from the non-persistent fields on this non-persistent mbo. By default, all the fields on this non-persistent mbo will be treated as parameters.
        Returns:
        Throws:
        MXException
        java.rmi.RemoteException
      • getJobName

        public abstract java.lang.String getJobName()
        Get the name of the job. The name of the job should also be added into the ASYNCJOBNAME internal ALN domain.
        Returns:
      • getDescription

        public abstract java.lang.String getDescription()
        Returns the description of the particular job, it is not the general description of this type of the job, it is the description that user enters to describe the particular job.
        Returns:
      • isImmediate

        public boolean isImmediate()
                            throws MXException,
                                   java.rmi.RemoteException
        Whether this job is foreground. If there is a yorn field on this non-persistent mbo that the name is "foreground", its value will be returned, otherwise false will be returned. Overwrite this method if this is not the case.
        Returns:
        Throws:
        MXException
        java.rmi.RemoteException
      • getEmail

        public boolean getEmail()
                         throws MXException,
                                java.rmi.RemoteException
        Gets whether email will be sent for this job. The value came from the email boolean field on the non-persistent MBO. If this is not the case, overwrite this method.
        Returns:
        Throws:
        MXException
        java.rmi.RemoteException
      • getEmailAddress

        public java.lang.String getEmailAddress()
                                         throws MXException,
                                                java.rmi.RemoteException
        Gets the email address that will be sent for this job. The value came from the emailaddress ALN field on the non-persistent MBO. If this is not the case, overwrite this method.
        Returns:
        Throws:
        MXException
        java.rmi.RemoteException
      • overwriteJobDefault

        public void overwriteJobDefault(MboRemote queue)
                                 throws MXException,
                                        java.rmi.RemoteException
        Overwrite this method if you don't need to overwrite execute() but need to change the default values of the job, such as userid, locale. Set the value to the queue object.
        Parameters:
        the - mb
        value -
        Throws:
        MXException
        java.rmi.RemoteException