Interface PersistedJobsManagerMBean


public interface PersistedJobsManagerMBean
This MBean manages jobs persisted by the driver.
Author:
Laurent Cohen
  • Field Details

  • Method Details

    • getPersistedJobUuids

      List<String> getPersistedJobUuids(JobSelector selector) throws Exception
      Get the uuids of all persisted jobs that match the selector.
      Parameters:
      selector - used to filter the jobs.
      Returns:
      a list of job uuids, possiblu empty if no job matches the selector.
      Throws:
      Exception - if any error occurs.
    • getPersistedJobObject

      Object getPersistedJobObject(String uuid, PersistenceObjectType type, int position) throws Exception
      Get the specified object of the persisted job with the specified uuid.
      Parameters:
      uuid - the uuid of the persisted job to lookup.
      type - the type of object to lookup.
      position - the position of the object in the job, if a position applies.
      Returns:
      the object in serialized format.
      Throws:
      Exception - if any error occurs.
    • getPersistedJobPositions

      int[][] getPersistedJobPositions(String uuid) throws Exception
      Get the positions of all tasks and task results for the specified persisted job.
      Parameters:
      uuid - the uuid of the persisted job to lookup.
      Returns:
      an array of int arrays, where the first array represents the positions of all tasks before execution, and the second array represents the positions of all task results. The second array may be empty if no task result was received.
      Throws:
      Exception - if any error occurs.
    • deletePersistedJobs

      List<String> deletePersistedJobs(JobSelector selector) throws Exception
      Delete all the persisted jobs that match the selector from the persistence store.
      Parameters:
      selector - used to filter the jobs.
      Returns:
      a list of actually deleted job uuids, possibly empty if no job matches the selector.
      Throws:
      Exception - if any error occurs.
    • isJobersisted

      boolean isJobersisted(String uuid) throws Exception
      Determine whether the specified job is persisted.
      Parameters:
      uuid - the uuid of the job to check.
      Returns:
      true if the job is persisted, false otherwise.
      Throws:
      Exception - if any error occurs while accessing the persistence store.
    • isJobComplete

      boolean isJobComplete(String uuid) throws Exception
      Determines whether the job has completed and all execution results are available.
      Parameters:
      uuid - the UUID of the jonb to check.
      Returns:
      true if the job has completed, false otherwise.
      Throws:
      Exception - if any error occurs while communicating with the driver.
    • requestLoad

      long requestLoad(Collection<PersistenceInfo> infos) throws Exception
      Request loading of the specified job's elements.
      Parameters:
      infos - information on the elements to load.
      Returns:
      a load request id, to reuse in later method calls.
      Throws:
      Exception - if any error occurs.
    • getPersistedJobObject

      Object getPersistedJobObject(long requestId, String uuid, PersistenceObjectType type, int position) throws Exception
      Get the specified object of the already-loaded persisted job with the specified uuid.
      Parameters:
      requestId - the id of the prior load request.
      uuid - the uuid of the persisted job to lookup.
      type - the type of object to lookup.
      position - the position of the object in the job, if a position applies.
      Returns:
      the object in serialized format.
      Throws:
      Exception - if any error occurs.
    • deleteLoadRequest

      boolean deleteLoadRequest(long requestId) throws Exception
      Get the specified object of the already-loaded persisted job with the specified uuid.
      Parameters:
      requestId - the id of the prior load request to delete.
      Returns:
      true if the delete succeeded, false otherwise.
      Throws:
      Exception - if any error occurs.