Package hudson.model
Interface Queue.Executable
- All Superinterfaces:
Runnable,WithConsoleUrl
- All Known Implementing Classes:
AbstractBuild,Build,FreeStyleBuild
- Enclosing class:
Queue
Represents the real meat of the computation run by
Executor.
Views
Implementation must have executorCell.jelly, which is
used to render the HTML that indicates this executable is executing.
-
Method Summary
Modifier and TypeMethodDescriptiondefault StringHandles cases such asPlaceholderExecutablefor Pipeline node steps.default longEstimate of how long will it take to execute this executable.Task from which this executable was created.default Queue.ExecutableAn umbrella executable (such as aRun) of which this is one part.voidrun()Called byExecutorto perform the task.toString()Used to render the HTML.
-
Method Details
-
getParent
Task from which this executable was created.Since this method went through a signature change in 1.377, the invocation may results in
AbstractMethodError. UseExecutables.getParentOf(Queue.Executable)that avoids this. -
getParentExecutable
An umbrella executable (such as aRun) of which this is one part. Some invariants:getParent().getOwnerTask() == getParent() || getParentExecutable().getParent() == getParent().getOwnerTask()getParent().getOwnerExecutable() == null || getParentExecutable() == getParent().getOwnerExecutable()
- Returns:
- a distinct executable (never
this, unlike the default ofSubTask.getOwnerTask()!); or null if this executable was already at top level - Since:
- 2.313, but implementations can already implement this with a lower core dependency.
- See Also:
-
run
Called byExecutorto perform the task.- Specified by:
runin interfaceRunnable- Throws:
AsynchronousExecution- if you would like to continue without consuming a thread
-
getEstimatedDuration
default long getEstimatedDuration()Estimate of how long will it take to execute this executable. Measured in milliseconds.- Returns:
- -1 if it's impossible to estimate; default,
SubTask.getEstimatedDuration() - Since:
- 1.383
-
getConsoleUrl
Handles cases such asPlaceholderExecutablefor Pipeline node steps.- Specified by:
getConsoleUrlin interfaceWithConsoleUrl- Returns:
- by default, that of
getParentExecutable()if defined
-
toString
String toString()Used to render the HTML. Should be a human readable text of what this executable is.
-