Package hudson.model
Class AsyncAperiodicWork
java.lang.Object
java.util.TimerTask
hudson.triggers.SafeTimerTask
hudson.model.AperiodicWork
hudson.model.AsyncAperiodicWork
- All Implemented Interfaces:
ExtensionPoint
,Runnable
AperiodicWork
that takes a long time to run. Similar to AsyncPeriodicWork
, see AsyncPeriodicWork
for
details and AperiodicWork
for differences between AperiodicWork
and PeriodicWork
.- Since:
- 1.410
- Author:
- vjuranek
-
Nested Class Summary
Nested classes/interfaces inherited from class hudson.triggers.SafeTimerTask
SafeTimerTask.ExceptionRunnable
Nested classes/interfaces inherited from interface hudson.ExtensionPoint
ExtensionPoint.LegacyInstancesAreScopedToHudson
-
Field Summary
Fields inherited from class hudson.model.AperiodicWork
logger
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionprotected StreamTaskListener
final void
Schedules this periodic work now in a new thread, if one isn't already running.protected abstract void
execute
(TaskListener listener) Executes the task.protected Level
Returns the logging level at which error messages are displayed.protected File
Determines the log file that records the result of this task.protected Level
Returns the logging level at which normal messages are displayed.protected Level
Returns the logging level at which previous task still executing messages is displayed.Methods inherited from class hudson.model.AperiodicWork
all, doRun, getInitialDelay, getNewInstance, getRecurrencePeriod, init
Methods inherited from class hudson.triggers.SafeTimerTask
getLogsRoot, of, run
Methods inherited from class java.util.TimerTask
cancel, scheduledExecutionTime
-
Field Details
-
name
Name of the work.
-
-
Constructor Details
-
AsyncAperiodicWork
-
-
Method Details
-
doAperiodicRun
public final void doAperiodicRun()Schedules this periodic work now in a new thread, if one isn't already running.- Specified by:
doAperiodicRun
in classAperiodicWork
-
createListener
-
getLogFile
Determines the log file that records the result of this task. -
getNormalLoggingLevel
Returns the logging level at which normal messages are displayed.- Returns:
- The logging level.
- Since:
- 1.651
-
getSlowLoggingLevel
Returns the logging level at which previous task still executing messages is displayed.- Returns:
- The logging level.
- Since:
- 1.651
-
getErrorLoggingLevel
Returns the logging level at which error messages are displayed.- Returns:
- The logging level.
- Since:
- 1.651
-
execute
Executes the task.- Parameters:
listener
- Output sent will be reported to the users. (this work is TBD.)- Throws:
InterruptedException
- The caller will record the exception and moves on.IOException
- The caller will record the exception and moves on.
-