Class JobControl

java.lang.Object
com.yahoo.concurrent.maintenance.JobControl

public class JobControl extends Object
Provides status over running maintenance jobs. This is multi-thread safe.
Author:
bratseth
  • Constructor Details

  • Method Details

    • started

      public void started(String jobSimpleClassName, Maintainer maintainer)
      Notifies this that a job was started
    • jobs

      public Set<String> jobs()
      Returns a snapshot of the set of jobs started on this system (whether deactivated or not). Each job is represented by its simple (omitting package) class name.
    • inactiveJobs

      public Set<String> inactiveJobs()
      Returns a snapshot containing the currently inactive jobs in this
    • isActive

      public boolean isActive(String jobSimpleClassName)
      Returns true if this job is not currently deactivated
    • run

      public void run(String jobSimpleClassName)
      Run given job (inactive or not) immediately
    • lockJob

      public Mutex lockJob(String jobSimpleClassName)
      Acquire lock for running given job