简体   繁体   English

跳船9.0.3中的Close_wait太多

[英]Too many Close_wait in jetty 9.0.3

We have an application REST gateway deployed over jetty 9.0.3 server.For authentication and authorization of services deployed in jetty is taken care by apache commons-httpclient3.1. 我们在Jetty 9.0.3服务器上部署了一个应用程序REST网关.apache commons-httpclient3.1负责对部署在jetty中的服务进行身份验证和授权。 when there are huge number of concurrent threads hitting Rest gateway, lot of CLOSE_WAIT are piling up in REST gateway machine. 当大量并发线程访问Rest网关时,REST网关计算机中会堆积很多CLOSE_WAIT。 Http connections which are opened for sending request to enabler(END POINT)are closed properly by calling releaseConnections method of apache commons. 通过调用apache commons的releaseConnections方法可以正确关闭为发送请求到启动器(END POINT)而打开的Http连接。 Please let me know how to handle these CLOSE_WAIT or any clues why connections are ending up in CLOSE_WAIT. 请让我知道如何处理这些CLOSE_WAIT或任何线索,为什么连接会以CLOSE_WAIT结尾。

The close_wait connections vanished when closeIdleConnections(0) provided by Apache commons http Client 3.1. 当Apache commons http Client 3.1提供的closeIdleConnections(0)时,close_wait连接消失。 But now too many TIME_WAIT are getting established and back end i am getting errors like "Address already in use" :( 但是现在建立了太多的TIME_WAIT,后端我收到诸如“地址已在使用中”之类的错误消息:(

Finally CLOSE_WAIT connections were not seen after using closeIdleConnections(0). 最后,在使用closeIdleConnections(0)之后看不到CLOSE_WAIT连接。 Hope this solution might help others :) 希望这个解决方案可以帮助其他人:)

CLOSE_WAIT means that TCP is waiting for the local application to close its end of the connection, which has already been closed by the peer. CLOSE_WAIT表示TCP正在等待本地应用程序关闭其连接的末端,该末端已被对等方关闭。

Ergo you aren't closing them. 因此,您没有关闭它们。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

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