Class ShutdownInterceptor
java.lang.Object
com.predic8.membrane.core.interceptor.AbstractInterceptor
com.predic8.membrane.core.interceptor.shutdown.ShutdownInterceptor
- All Implemented Interfaces:
Interceptor
- Description
- Shutdown interceptor.
- Explanation
Adds the ability to shutdown main router thread via an HTTP request. Don't forget to setup security for this interceptor.
Has undefined behavior when Membrane is not started from command line (=via the RouterCLI class, which service-proxy.bat/service-proxy.sh do use).
Only actually terminates the running JVM, when used in the first <router> bean (which implicitly stands for <router id="router">) called "router".
- Topic
- 4. Interceptors/Features
-
Nested Class Summary
Nested classes/interfaces inherited from interface com.predic8.membrane.core.interceptor.Interceptor
Interceptor.Flow -
Field Summary
Fields inherited from class com.predic8.membrane.core.interceptor.AbstractInterceptor
name, router -
Constructor Summary
Constructors -
Method Summary
Methods inherited from class com.predic8.membrane.core.interceptor.AbstractInterceptor
getDisplayName, getFlow, getHelpId, getMessage, getRouter, getRule, handleAbort, handleResponse, init, init, setDisplayName, setFlow
-
Constructor Details
-
ShutdownInterceptor
public ShutdownInterceptor()
-
-
Method Details
-
handleRequest
- Specified by:
handleRequestin interfaceInterceptor- Overrides:
handleRequestin classAbstractInterceptor- Throws:
Exception
-
getShortDescription
- Specified by:
getShortDescriptionin interfaceInterceptor- Overrides:
getShortDescriptionin classAbstractInterceptor
-
getLongDescription
- Specified by:
getLongDescriptionin interfaceInterceptor- Overrides:
getLongDescriptionin classAbstractInterceptor
-