简体   繁体   中英

Netty Connections in TIME_WAIT

I have created a netty server and client, which is using a Connection Factory build over DBCP, to maintain a pool of active connections. To make the connections alive, I am using keepAlive.

However, I have noticed that the sockets are increasing at a rapid rate beyond the channel pool size, because all of them are in a TIME_WAIT state.

What am I doing wrong? Is there any implementation of Channel Pool of Netty.

There is no pool included in Netty itself. You will need to send some kind of HEARTBEAT to keep the alive. How this is implemented depends on the protocol itself. For example SMTP has a NOOP command for this.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM