Class ThreadLocalJobContext

java.lang.Object
org.jobrunr.server.runner.ThreadLocalJobContext

public class ThreadLocalJobContext extends Object
  • Method Details

    • getJobContext

      public static JobContext getJobContext()
      Returns the JobContext for the currently executing job. This method retrieves the JobContext associated with the job being processed, allowing access to job metadata, progress reporting, and logging capabilities.
      Returns:
      the JobContext for the currently executing job
      Throws:
      JobRunrException - if no JobContext is available
    • hasJobContext

      public static boolean hasJobContext()