Package jenkins.slaves.restarter
Class WinswSlaveRestarter
- java.lang.Object
-
- jenkins.slaves.restarter.SlaveRestarter
-
- jenkins.slaves.restarter.WinswSlaveRestarter
-
- All Implemented Interfaces:
ExtensionPoint
,Serializable
@Extension public class WinswSlaveRestarter extends SlaveRestarter
With winsw, restart via winsw- See Also:
- Serialized Form
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from interface hudson.ExtensionPoint
ExtensionPoint.LegacyInstancesAreScopedToHudson
-
-
Constructor Summary
Constructors Constructor Description WinswSlaveRestarter()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description boolean
canWork()
Called on the agent to see if this restarter can work on this agent.void
restart()
IfSlaveRestarter.canWork()
method returns true, this method is called later when the connection is lost to restart the agent.-
Methods inherited from class jenkins.slaves.restarter.SlaveRestarter
all
-
-
-
-
Method Detail
-
canWork
public boolean canWork()
Description copied from class:SlaveRestarter
Called on the agent to see if this restarter can work on this agent.- Specified by:
canWork
in classSlaveRestarter
-
restart
public void restart() throws Exception
Description copied from class:SlaveRestarter
IfSlaveRestarter.canWork()
method returns true, this method is called later when the connection is lost to restart the agent.Note that by the time this method is called, classloader is no longer capable of loading any additional classes. Therefore
SlaveRestarter.canWork()
method must have exercised enough of the actual restart process so that this call can proceed without trying to load additional classes nor resources.This method is not expected to return, and the JVM should terminate before this call returns. If the method returns normally, the agent will move on to the reconnection without restart. If an exception is thrown, it is reported as an error and then the agent will move on to the reconnection without restart.
- Specified by:
restart
in classSlaveRestarter
- Throws:
Exception
-
-