mirror of
https://github.com/tiennm99/zfoo.git
synced 2026-08-20 22:24:27 +00:00
perf[module]: Router发送消息增加高低水位判断
This commit is contained in:
@@ -173,6 +173,10 @@ public class Router implements IRouter {
|
||||
var packetInfo = EncodedPacketInfo.valueOf(packet, attachment);
|
||||
|
||||
var channel = session.getChannel();
|
||||
if (!channel.isActive() || !channel.isWritable()) {
|
||||
logger.error("send msg error, protocolId=[{}] isActive=[{}] isWritable=[{}]", packet.protocolId(), channel.isActive(), channel.isWritable());
|
||||
return;
|
||||
}
|
||||
channel.writeAndFlush(packetInfo);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user