{"issue":{"state":"closed","pull_request":{"diff_url":null,"html_url":null,"patch_url":null},"user":{"avatar_url":"https://secure.gravatar.com/avatar/930846ab155b28744172b092bed3c2da?d=https://a248.e.akamai.net/assets.github.com%2Fimages%2Fgravatars%2Fgravatar-140.png","gravatar_id":"930846ab155b28744172b092bed3c2da","url":"https://api.github.com/users/HelloJamesLee","login":"HelloJamesLee","id":714426},"milestone":null,"labels":[],"updated_at":"2011-11-04T09:31:39Z","assignee":null,"closed_at":"2011-11-04T09:31:39Z","comments":3,"url":"https://api.github.com/repos/yaoweibin/nginx_ajp_module/issues/5","body":"Hi, \r\n\r\nWhen I use Nginx+ajp_module+tomcat and Apache+mod_jk+tomcat, I found two problems. What's the reason? Can you help?\r\n\r\n(1) There are too many TIME_WAIT between nginx and tomcat\r\nThe TIME_WAIT/Total connection is 13890/16030\r\nWhen I use the Apache+mod_jk+tomcat, the TIME_WAIT/Total is 92/952.\r\n\r\n\r\n(2) The %CPU of tomcat in Nginx is higher than that of tomcat in apache.  -- This is the main problem.\r\nThe tomcat in Apache used  all the maxThreads(512), but tomcat in Nginx only uses 125 threads, via \"ps -efL | grep catalina \"  \r\n\r\nThe configuration of tomcats in these two situatin are the same, and the concurrency is also the same. The configuration of ajp module is as follow:\r\najp_connect_timeout 10;\r\najp_read_timeout 10;\r\nupstream loadbalancer {\r\n        server 127.0.0.1:8001;\r\n        server 127.0.0.1:8002;\r\n        server 127.0.0.1:8003;\r\n\r\n        #keepalive 6400;\r\n    }\r\nWhether i enable keepalive in upstream directive or not, the two problem exists all the same.  \r\nThe ajp_module version is 0.2.5, the latest version.\r\n\r\nCan you give me some clues to reslove these problems? Thank you!\r\n\r\n","html_url":"https://github.com/yaoweibin/nginx_ajp_module/issues/5","title":"There are too many \"TIME_WAIT\" between nginx and tomcat when your ajp module is in use.","number":5,"id":2140872,"created_at":"2011-11-04T05:17:34Z"},"action":"closed"}