Interface ServerJob

  • All Superinterfaces:
    Runnable

    public interface ServerJob
    extends Runnable
    The server-side representation of a Job is responsible for the management of the job execution.
    • Method Detail

      • abort

        void abort()
        Cancel this Job.
      • getClientJob

        Job getClientJob()
        Returns the associated client Job this ServerJob is associated with
        Returns:
        the associated client Job
      • processingFailed

        void processingFailed​(NodeWorker<?> worker,
                              org.jadice.util.log.qualified.QualifiedLogEvent message)
        Handle a processing failure, possibly pertaining to a particular node and worker. Calling this method will ultimately abort the job.
        Parameters:
        worker - The worker that caused the failure
        message - Reason of the failure
      • warning

        void warning​(NodeWorker<?> worker,
                     org.jadice.util.log.qualified.QualifiedLogEvent message)
        Propagate a warning, possibly pertaining to a particular node and worker.
        Parameters:
        worker - The worker that caused the warning
        message - Reason of the warning
      • error

        void error​(NodeWorker<?> worker,
                   org.jadice.util.log.qualified.QualifiedLogEvent message)
        Propagate a non-fatal, possibly pertaining to a particular node and worker.
        Parameters:
        worker - The worker that caused the error
        message - Reason of the error
      • startWorkers

        void startWorkers​(Collection<NodeWorker<?>> workers)
        Start worker threads for a given sub-pipeline.
        Parameters:
        workers - the NodeWorker instances to start
      • getServerTempDir

        File getServerTempDir()
        Get the temporary directory jadice server uses. This method is only relevant for certain cases. The usual way to create temporary files is via method getTempDir().
        Returns:
        the temporary directory jadice server uses.
        Since:
        jadice server 5.0.5.0
        See Also:
        getTempDir()
      • announceSubPipelineCreation

        void announceSubPipelineCreation​(Node parent,
                                         Set<? extends Node> createdNodes)
        Propagate that new Nodes were created in a sub-pipeline on behalf of another node.
        Parameters:
        parent - The node that triggered the creation
        createdNodes - The nodes that were created.
      • getAge

        long getAge()
        Calculate the age of this job, i.e. the time since it has been started
        Returns:
        The age in ms