mirror of
https://git.krews.org/morningstar/nitrowebsockets-for-ms
synced 2024-11-26 08:50:51 +01:00
update ping handler -- fixes cloudflare timeout
This commit is contained in:
parent
aea83f4282
commit
0d68f58466
2
pom.xml
2
pom.xml
@ -6,7 +6,7 @@
|
|||||||
|
|
||||||
<groupId>org.krews.plugin.nitro</groupId>
|
<groupId>org.krews.plugin.nitro</groupId>
|
||||||
<artifactId>NitroWebsockets</artifactId>
|
<artifactId>NitroWebsockets</artifactId>
|
||||||
<version>2.0</version>
|
<version>3.0</version>
|
||||||
<build>
|
<build>
|
||||||
<plugins>
|
<plugins>
|
||||||
<plugin>
|
<plugin>
|
||||||
|
@ -30,9 +30,6 @@ public class NetworkChannelInitializer extends ChannelInitializer<SocketChannel>
|
|||||||
public void initChannel(SocketChannel ch) {
|
public void initChannel(SocketChannel ch) {
|
||||||
ch.pipeline().addLast("logger", new LoggingHandler());
|
ch.pipeline().addLast("logger", new LoggingHandler());
|
||||||
|
|
||||||
ch.pipeline().addLast("idleStateHandler", new IdleStateHandler(60, 30, 0));
|
|
||||||
ch.pipeline().addAfter("idleStateHandler", "idleEventHandler", new IdleTimeoutHandler());
|
|
||||||
|
|
||||||
if(isSSL) {
|
if(isSSL) {
|
||||||
ch.pipeline().addLast(context.newHandler(ch.alloc()));
|
ch.pipeline().addLast(context.newHandler(ch.alloc()));
|
||||||
}
|
}
|
||||||
@ -51,6 +48,7 @@ public class NetworkChannelInitializer extends ChannelInitializer<SocketChannel>
|
|||||||
ch.pipeline().addLast(new GameClientMessageLogger());
|
ch.pipeline().addLast(new GameClientMessageLogger());
|
||||||
}
|
}
|
||||||
|
|
||||||
|
ch.pipeline().addLast("idleEventHandler", new IdleTimeoutHandler(30, 60));
|
||||||
ch.pipeline().addLast(new GameMessageRateLimit());
|
ch.pipeline().addLast(new GameMessageRateLimit());
|
||||||
ch.pipeline().addLast(new GameMessageHandler());
|
ch.pipeline().addLast(new GameMessageHandler());
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user