Class DeadlineTimeOutStrategy
java.lang.Object
hudson.plugins.build_timeout.BuildTimeOutStrategy
hudson.plugins.build_timeout.impl.DeadlineTimeOutStrategy
- All Implemented Interfaces:
- Describable<BuildTimeOutStrategy>
If the build reaches 
deadlineTime, it will be terminated.- Author:
- Fernando Miguélez Palomo (fernando.miguelez@gmail.com)
- 
Nested Class SummaryNested Classes
- 
Field SummaryFieldsModifier and TypeFieldDescriptionprotected static final Stringstatic final intprotected static final Stringprotected static final Stringprotected static final StringFields inherited from class hudson.plugins.build_timeout.BuildTimeOutStrategyLOG, MINUTES
- 
Constructor SummaryConstructorsConstructorDescriptionDeadlineTimeOutStrategy(String deadlineTime, int deadlineToleranceInMinutes) 
- 
Method SummaryModifier and TypeMethodDescriptionintlonggetTimeOut(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.BuildTimeOutStrategyexpandAll, getDescriptor, getTimeOut, hasMacros, onWrite, onWrite, wantsCaptureLog
- 
Field Details- 
MINIMUM_DEADLINE_TOLERANCE_IN_MINUTESpublic static final int MINIMUM_DEADLINE_TOLERANCE_IN_MINUTES- See Also:
 
- 
DEADLINE_REGEXP- See Also:
 
- 
TIME_LONG_FORMAT_PATTERN- See Also:
 
- 
TIME_SHORT_FORMAT_PATTERN- See Also:
 
- 
TIMESTAMP_FORMAT_PATTERN- See Also:
 
 
- 
- 
Constructor Details- 
DeadlineTimeOutStrategy@DataBoundConstructor public DeadlineTimeOutStrategy(String deadlineTime, int deadlineToleranceInMinutes) 
 
- 
- 
Method Details- 
getDeadlineTime- Returns:
- deadline time
 
- 
getDeadlineToleranceInMinutespublic int getDeadlineToleranceInMinutes()- Returns:
- deadline tolerance in minutes
 
- 
getTimeOutpublic long getTimeOut(@NonNull AbstractBuild<?, ?> build, @NonNull BuildListener listener) throws InterruptedException, org.jenkinsci.plugins.tokenmacro.MacroEvaluationException, IOException, IllegalArgumentExceptionDescription copied from class:BuildTimeOutStrategyDefine the delay (in milliseconds) to wait for the build to complete before interrupting.- Overrides:
- getTimeOutin class- BuildTimeOutStrategy
- Parameters:
- build- the build
- listener- the build listener
- Throws:
- InterruptedException
- org.jenkinsci.plugins.tokenmacro.MacroEvaluationException
- IOException
- IllegalArgumentException
 
- 
toString
 
-