Class PreventJobExecutionUntilCompletedTriggerListener

java.lang.Object
org.quartz.listeners.TriggerListenerSupport
com.atlassian.bamboo.quartz.PreventJobExecutionUntilCompletedTriggerListener
All Implemented Interfaces:
org.quartz.TriggerListener

public class PreventJobExecutionUntilCompletedTriggerListener extends org.quartz.listeners.TriggerListenerSupport
This trigger listener will allow only one job (identified by JobDetail) to be executed at a time by given trigger.
  • Field Summary

    Fields
    Modifier and Type
    Field
    Description
    static final org.quartz.TriggerListener
     
  • Constructor Summary

    Constructors
  • Method Summary

    Modifier and Type
    Method
    Description
     
    void
    triggerComplete(org.quartz.Trigger trigger, org.quartz.JobExecutionContext context, org.quartz.Trigger.CompletedExecutionInstruction triggerInstructionCode)
     
    void
    triggerFired(org.quartz.Trigger trigger, org.quartz.JobExecutionContext context)
    Register context only if there's no already registered context for given Trigger and JobDetail pair
    boolean
    vetoJobExecution(org.quartz.Trigger trigger, org.quartz.JobExecutionContext context)
    Veto job execution Register context only if there's no already registered context for given Trigger and JobDetail pair

    Methods inherited from class org.quartz.listeners.TriggerListenerSupport

    getLog, triggerMisfired

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Field Details

    • INSTANCE

      public static final org.quartz.TriggerListener INSTANCE
  • Constructor Details

    • PreventJobExecutionUntilCompletedTriggerListener

      public PreventJobExecutionUntilCompletedTriggerListener()
  • Method Details

    • getName

      public String getName()
    • triggerComplete

      public void triggerComplete(org.quartz.Trigger trigger, org.quartz.JobExecutionContext context, org.quartz.Trigger.CompletedExecutionInstruction triggerInstructionCode)
      Specified by:
      triggerComplete in interface org.quartz.TriggerListener
      Overrides:
      triggerComplete in class org.quartz.listeners.TriggerListenerSupport
    • triggerFired

      public void triggerFired(org.quartz.Trigger trigger, org.quartz.JobExecutionContext context)
      Register context only if there's no already registered context for given Trigger and JobDetail pair
      Specified by:
      triggerFired in interface org.quartz.TriggerListener
      Overrides:
      triggerFired in class org.quartz.listeners.TriggerListenerSupport
      Parameters:
      trigger -
      context -
    • vetoJobExecution

      public boolean vetoJobExecution(org.quartz.Trigger trigger, org.quartz.JobExecutionContext context)
      Veto job execution Register context only if there's no already registered context for given Trigger and JobDetail pair
      Specified by:
      vetoJobExecution in interface org.quartz.TriggerListener
      Overrides:
      vetoJobExecution in class org.quartz.listeners.TriggerListenerSupport
      Parameters:
      trigger -
      context -