Save This Page
Home » quartz-1.6.0 » org » quartz » plugins » history » [javadoc | source]
org.quartz.plugins.history
public class: LoggingTriggerHistoryPlugin [javadoc | source]
java.lang.Object
   org.quartz.plugins.history.LoggingTriggerHistoryPlugin

All Implemented Interfaces:
    TriggerListener, SchedulerPlugin

Logs a history of all trigger firings via the Jakarta Commons-Logging framework.

The logged message is customizable by setting one of the following message properties to a String that conforms to the syntax of java.util.MessageFormat.

TriggerFiredMessage - available message data are:
Element Data Type Description
0 String The Trigger's Name.
1 String The Trigger's Group.
2 Date The scheduled fire time.
3 Date The next scheduled fire time.
4 Date The actual fire time.
5 String The Job's name.
6 String The Job's group.
7 Integer The re-fire count from the JobExecutionContext.
The default message text is "Trigger {1}.{0} fired job {6}.{5} at: {4, date, HH:mm:ss MM/dd/yyyy}"

TriggerMisfiredMessage - available message data are:
Element Data Type Description
0 String The Trigger's Name.
1 String The Trigger's Group.
2 Date The scheduled fire time.
3 Date The next scheduled fire time.
4 Date The actual fire time. (the time the misfire was detected/handled)
5 String The Job's name.
6 String The Job's group.
The default message text is "Trigger {1}.{0} misfired job {6}.{5} at: {4, date, HH:mm:ss MM/dd/yyyy}. Should have fired at: {3, date, HH:mm:ss MM/dd/yyyy}"

TriggerCompleteMessage - available message data are:
Element Data Type Description
0 String The Trigger's Name.
1 String The Trigger's Group.
2 Date The scheduled fire time.
3 Date The next scheduled fire time.
4 Date The job completion time.
5 String The Job's name.
6 String The Job's group.
7 Integer The re-fire count from the JobExecutionContext.
8 Integer The trigger's resulting instruction code.
9 String A human-readable translation of the trigger's resulting instruction code.
The default message text is "Trigger {1}.{0} completed firing job {6}.{5} at {4, date, HH:mm:ss MM/dd/yyyy} with resulting trigger instruction code: {9}"

Constructor:
 public LoggingTriggerHistoryPlugin() 
Method from org.quartz.plugins.history.LoggingTriggerHistoryPlugin Summary:
getLog,   getName,   getTriggerCompleteMessage,   getTriggerFiredMessage,   getTriggerMisfiredMessage,   initialize,   setTriggerCompleteMessage,   setTriggerFiredMessage,   setTriggerMisfiredMessage,   shutdown,   start,   triggerComplete,   triggerFired,   triggerMisfired,   vetoJobExecution
Methods from java.lang.Object:
equals,   getClass,   hashCode,   notify,   notifyAll,   toString,   wait,   wait,   wait
Method from org.quartz.plugins.history.LoggingTriggerHistoryPlugin Detail:
 protected Log getLog() 
 public String getName() 
 public String getTriggerCompleteMessage() 
    Get the message that is printed upon the completion of a trigger's firing.
 public String getTriggerFiredMessage() 
    Get the message that is printed upon a trigger's firing.
 public String getTriggerMisfiredMessage() 
    Get the message that is printed upon a trigger's mis-firing.
 public  void initialize(String name,
    Scheduler scheduler) throws SchedulerException 

    Called during creation of the Scheduler in order to give the SchedulerPlugin a chance to initialize.

 public  void setTriggerCompleteMessage(String triggerCompleteMessage) 
    Set the message that is printed upon the completion of a trigger's firing.
 public  void setTriggerFiredMessage(String triggerFiredMessage) 
    Set the message that is printed upon a trigger's firing.
 public  void setTriggerMisfiredMessage(String triggerMisfiredMessage) 
    Set the message that is printed upon a trigger's firing.
 public  void shutdown() 

    Called in order to inform the SchedulerPlugin that it should free up all of it's resources because the scheduler is shutting down.

 public  void start() 
 public  void triggerComplete(Trigger trigger,
    JobExecutionContext context,
    int triggerInstructionCode) 
 public  void triggerFired(Trigger trigger,
    JobExecutionContext context) 
 public  void triggerMisfired(Trigger trigger) 
 public boolean vetoJobExecution(Trigger trigger,
    JobExecutionContext context)