Class AbsoluteTimeOutStrategy
java.lang.Object
hudson.plugins.build_timeout.BuildTimeOutStrategy
hudson.plugins.build_timeout.impl.AbsoluteTimeOutStrategy
- All Implemented Interfaces:
Describable<BuildTimeOutStrategy>
If the build took longer than
timeoutMinutes
amount of minutes, it will be terminated.-
Nested Class Summary
-
Field Summary
Fields inherited from class hudson.plugins.build_timeout.BuildTimeOutStrategy
LOG, MINUTES
-
Constructor Summary
ConstructorDescriptionAbsoluteTimeOutStrategy
(int timeoutMinutes) Deprecated.AbsoluteTimeOutStrategy
(String timeoutMinutes) -
Method Summary
Modifier and TypeMethodDescriptionlong
getTimeOut
(AbstractBuild<?, ?> build, BuildListener listener) Define the delay (in milliseconds) to wait for the build to complete before interrupting.toString()
Methods inherited from class hudson.plugins.build_timeout.BuildTimeOutStrategy
expandAll, getTimeOut, hasMacros, onWrite, onWrite, wantsCaptureLog
-
Field Details
-
DESCRIPTOR
-
-
Constructor Details
-
AbsoluteTimeOutStrategy
Deprecated. -
AbsoluteTimeOutStrategy
-
-
Method Details
-
getTimeoutMinutes
- Returns:
- minutes to timeout.
-
getTimeOut
public long getTimeOut(@NonNull AbstractBuild<?, ?> build, @NonNull BuildListener listener) throws InterruptedException, org.jenkinsci.plugins.tokenmacro.MacroEvaluationException, IOExceptionDescription copied from class:BuildTimeOutStrategy
Define the delay (in milliseconds) to wait for the build to complete before interrupting.- Overrides:
getTimeOut
in classBuildTimeOutStrategy
- Parameters:
build
- the buildlistener
- the build listener- Throws:
InterruptedException
org.jenkinsci.plugins.tokenmacro.MacroEvaluationException
IOException
-
getDescriptor
- Specified by:
getDescriptor
in interfaceDescribable<BuildTimeOutStrategy>
- Overrides:
getDescriptor
in classBuildTimeOutStrategy
- Returns:
- See Also:
-
toString
-