|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
org.quartz.core Class JobRunShell
java.lang.Object org.quartz.listeners.SchedulerListenerSupport org.quartz.core.JobRunShell
- All Implemented Interfaces:
- Runnable, SchedulerListener
- Direct Known Subclasses:
- JTAJobRunShell
public class JobRunShell
- extends SchedulerListenerSupport
- implements Runnable
JobRunShell instances are responsible for providing the 'safe' environment
for Job
s to run in, and for performing all of the work of
executing the Job
, catching ANY thrown exceptions, updating
the Trigger
with the Job
's completion code,
etc.
A JobRunShell
instance is created by a JobRunShellFactory
on behalf of the QuartzSchedulerThread
which then runs the
shell in a thread from the configured ThreadPool
when the
scheduler determines that a Job
has been triggered.
- Author:
- James House
- See Also:
JobRunShellFactory
,QuartzSchedulerThread
,Job
,Trigger
Field Summary | |
---|---|
protected org.quartz.spi.TriggerFiredBundle |
firedTriggerBundle
|
protected JobExecutionContextImpl |
jec
|
protected QuartzScheduler |
qs
|
protected Scheduler |
scheduler
|
protected boolean |
shutdownRequested
|
Constructor Summary | |
---|---|
JobRunShell(Scheduler scheduler,
org.quartz.spi.TriggerFiredBundle bndle)
Create a JobRunShell instance with the given settings. |
Method Summary | |
---|---|
protected void |
begin()
|
protected void |
complete(boolean successfulExecution)
|
boolean |
completeTriggerRetryLoop(org.quartz.spi.OperableTrigger trigger,
JobDetail jobDetail,
Trigger.CompletedExecutionInstruction instCode)
|
protected org.slf4j.Logger |
getLog()
Get the
Logger for this
class's category. |
void |
initialize(QuartzScheduler qs)
|
void |
passivate()
|
void |
requestShutdown()
|
void |
run()
|
void |
schedulerShuttingdown()
Called by the
Scheduler to inform the listener
that it has begun the shutdown sequence. |
boolean |
vetoedJobRetryLoop(org.quartz.spi.OperableTrigger trigger,
JobDetail jobDetail,
Trigger.CompletedExecutionInstruction instCode)
|
Methods inherited from class org.quartz.listeners.SchedulerListenerSupport |
---|
jobAdded, jobDeleted, jobPaused, jobResumed, jobScheduled, jobsPaused, jobsResumed, jobUnscheduled, schedulerError, schedulerInStandbyMode, schedulerShutdown, schedulerStarted, schedulingDataCleared, triggerFinalized, triggerPaused, triggerResumed, triggersPaused, triggersResumed |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
jec
protected JobExecutionContextImpl jec
qs
protected QuartzScheduler qs
firedTriggerBundle
protected org.quartz.spi.TriggerFiredBundle firedTriggerBundle
scheduler
protected Scheduler scheduler
shutdownRequested
protected volatile boolean shutdownRequested
Constructor Detail |
---|
JobRunShell
public JobRunShell(Scheduler scheduler, org.quartz.spi.TriggerFiredBundle bndle)
Create a JobRunShell instance with the given settings.
- Parameters:
jobRunShellFactory
- A handle to theJobRunShellFactory
that produced thisJobRunShell
.scheduler
- TheScheduler
instance that should be made available within theJobExecutionContext
.schdCtxt
- theSchedulingContext
that should be used by theJobRunShell
when making updates to theJobStore
.
Method Detail |
---|
schedulerShuttingdown
public void schedulerShuttingdown()
- Description copied from interface:
SchedulerListener
Called by the
Scheduler
to inform the listener that it has begun the shutdown sequence.- Specified by:
schedulerShuttingdown
in interfaceSchedulerListener
- Overrides:
schedulerShuttingdown
in classSchedulerListenerSupport
getLog
protected org.slf4j.Logger getLog()
- Description copied from class:
SchedulerListenerSupport
- Get the
Logger
for this class's category. This should be used by subclasses for logging. - Overrides:
getLog
in classSchedulerListenerSupport
initialize
public void initialize(QuartzScheduler qs) throws SchedulerException
- Throws:
SchedulerException
requestShutdown
public void requestShutdown()
run
public void run()
begin
protected void begin() throws SchedulerException
- Throws:
SchedulerException
complete
protected void complete(boolean successfulExecution) throws SchedulerException
- Throws:
SchedulerException
passivate
public void passivate()
completeTriggerRetryLoop
public boolean completeTriggerRetryLoop(org.quartz.spi.OperableTrigger trigger, JobDetail jobDetail, Trigger.CompletedExecutionInstruction instCode)
vetoedJobRetryLoop
public boolean vetoedJobRetryLoop(org.quartz.spi.OperableTrigger trigger, JobDetail jobDetail, Trigger.CompletedExecutionInstruction instCode)
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
Copyright 2001-2011, Terracotta, Inc.