Package hudson.model
Class RestartListener
java.lang.Object
hudson.model.RestartListener
- All Implemented Interfaces:
ExtensionPoint
- Direct Known Subclasses:
Jenkins.MasterRestartNotifyier,RestartListener.Default
Extension point that allows plugins to veto the restart.
- Since:
- 1.376
- Author:
- Kohsuke Kawaguchi
-
Nested Class Summary
Nested ClassesNested classes/interfaces inherited from interface hudson.ExtensionPoint
ExtensionPoint.LegacyInstancesAreScopedToHudson -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic ExtensionList<RestartListener> all()Returns all the registeredLabelFinders.static booleanReturns true iff all the listeners OKed the restart.abstract booleanCalled periodically during the safe restart.voidCalled immediately before the restart is actually triggered.
-
Constructor Details
-
RestartListener
public RestartListener()
-
-
Method Details
-
isReadyToRestart
Called periodically during the safe restart.- Returns:
- false to block the restart
- Throws:
IOExceptionInterruptedException
-
onRestart
public void onRestart()Called immediately before the restart is actually triggered. -
all
Returns all the registeredLabelFinders. -
isAllReady
Returns true iff all the listeners OKed the restart.- Throws:
IOExceptionInterruptedException
-