Making fix for out of order events by moving registerWebSockets to doStart and not the constructor
This commit is contained in:
parent
4549afbcf0
commit
89bd36dbaf
|
@ -68,7 +68,6 @@ public abstract class WebSocketHandler extends HandlerWrapper
|
|||
WebSocketPolicy policy = new WebSocketPolicy(WebSocketBehavior.SERVER);
|
||||
configurePolicy(policy);
|
||||
webSocketFactory = new WebSocketServerFactory(policy);
|
||||
registerWebSockets(webSocketFactory);
|
||||
}
|
||||
|
||||
public void configurePolicy(WebSocketPolicy policy)
|
||||
|
@ -76,6 +75,13 @@ public abstract class WebSocketHandler extends HandlerWrapper
|
|||
/* leave at default */
|
||||
}
|
||||
|
||||
@Override
|
||||
protected void doStart() throws Exception
|
||||
{
|
||||
super.doStart();
|
||||
registerWebSockets(webSocketFactory);
|
||||
}
|
||||
|
||||
public WebSocketServerFactory getWebSocketFactory()
|
||||
{
|
||||
return webSocketFactory;
|
||||
|
|
Loading…
Reference in New Issue