Class WebSocketInterceptor
java.lang.Object
com.predic8.membrane.core.interceptor.AbstractInterceptor
com.predic8.membrane.core.interceptor.tunnel.WebSocketInterceptor
- All Implemented Interfaces:
Interceptor
- Default
- false
- Description
- Allow HTTP protocol upgrades to the WebSocket protocol. After the upgrade, the connection's data packets are simply forwarded and not inspected.
-
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
Modifier and TypeMethodDescriptiongetUrl()handleRequest(Exchange exc) voidinit()Called after parsing is complete and this has been added to the object tree (whose root is Router).voidvoidsetInterceptors(List<WebSocketInterceptorInterface> interceptors) voidMethods inherited from class com.predic8.membrane.core.interceptor.AbstractInterceptor
getDisplayName, getFlow, getHelpId, getLongDescription, getMessage, getRouter, getRule, handleAbort, handleResponse, setDisplayName, setFlow
-
Constructor Details
-
WebSocketInterceptor
public WebSocketInterceptor()
-
-
Method Details
-
init
- Specified by:
initin interfaceInterceptor- Overrides:
initin classAbstractInterceptor- Throws:
Exception
-
init
Description copied from class:AbstractInterceptorCalled after parsing is complete and this has been added to the object tree (whose root is Router).- Overrides:
initin classAbstractInterceptor- Throws:
Exception
-
handleRequest
- Specified by:
handleRequestin interfaceInterceptor- Overrides:
handleRequestin classAbstractInterceptor- Throws:
Exception
-
getShortDescription
- Specified by:
getShortDescriptionin interfaceInterceptor- Overrides:
getShortDescriptionin classAbstractInterceptor
-
getUrl
-
setUrl
- Description
- The URL the WebSocket connection will be forwarded to. The (host,port) pair specifies the target server. The (path,query) part are sent to the target server on the initial request. (For example, ActiveMQ listens on port 61614 and expects the incoming WebSocket connection to have a path '/' and empty query.)
- Example
- http://localhost:61614/
-
getInterceptors
-
setInterceptors
-