public class DefaultMainShutdownStrategy extends SimpleMainShutdownStrategy
MainShutdownStrategy that add a virtual machine shutdown hook to
properly stop the main instance.MainShutdownStrategy.ShutdownEventListener| Modifier and Type | Field and Description |
|---|---|
protected static org.slf4j.Logger |
LOG |
| Constructor and Description |
|---|
DefaultMainShutdownStrategy(BaseMainSupport main) |
| Modifier and Type | Method and Description |
|---|---|
void |
await()
Wait for main to complete.
|
void |
await(long timeout,
TimeUnit unit)
Wait for main to complete.
|
void |
disableHangupSupport()
Disable the hangup support.
|
void |
enableHangupSupport()
Hangup support is enabled by default.
|
addShutdownListener, isRunAllowed, shutdownpublic DefaultMainShutdownStrategy(BaseMainSupport main)
public void disableHangupSupport()
public void enableHangupSupport()
public void await()
throws InterruptedException
MainShutdownStrategyawait in interface MainShutdownStrategyawait in class SimpleMainShutdownStrategyInterruptedExceptionpublic void await(long timeout,
TimeUnit unit)
throws InterruptedException
MainShutdownStrategyawait in interface MainShutdownStrategyawait in class SimpleMainShutdownStrategytimeout - the maximum time to waitunit - the time unit of the timeout argumentInterruptedExceptionApache Camel