public interface WebsocketDispatcher
Websocket support is done by creating a class implementing this interface. By placing an Register
annotation is is found by the WebServerHandler
which then initiates the
websocket protocol for requests on the given uri.
Modifier and Type | Method and Description |
---|---|
WebsocketSession |
createSession(ChannelHandlerContext ctx,
HttpRequest req)
Creates a new session for a given channel (context) and request.
|
String |
getWebsocketUri()
Returns the URI which is used to determine if a request is eligble for upgrading to web sockets.
|
String getWebsocketUri()
WebsocketSession createSession(ChannelHandlerContext ctx, HttpRequest req)
ctx
- the channel which was used to initialize a websocketreq
- the request which was made before upgrading to websocketsCopyright © 2018. All rights reserved.