Welcome! Log In Create A New Profile

Advanced

Re: AJP

Jérôme Loyet
October 25, 2012 12:36PM
2012/10/25 rmalayter <nginx-forum@nginx.us>:
> Jérôme Loyet Wrote:
> -------------------------------------------------------
>> We were in the same situation and didn't want to take the risk to use
>> a third party module, so we switched to HTTP and it's just perfect.
>>
>> my 2 cents ;)
>
> We did the same here. Now that nginx does keep-alives to the back-ends,
> there's really no advantage to using AJP between the web server and Tomcat.
>
>
> In fact, our internal load testing showed nginx->HTTP->Tomcat performing
> marginally better than Apache->AJP->Tomcat with Tomcat serving a simple test
> JSP.

Same results here. In fact the way nginx works (async) compensate the
loss due to switching to HTTP (and even more than expected).

>I suspect this is because the HTTP code in Tomcat has been optimized
> far more than the AJP code. However, in the real world your bottlenecks will
> always be DB, disk IO, and memory/garbage collection caused by your app at
> the Tomcat layer.
>
> Profile your app, and find out where the bottlenecks actually are. Address
> the worst ones first. I suspect communication overhead between your web
> server and Tomcat isn't even visible no matter what you use. Proper caching,
> efficient client-side layout and script, DB query tuning, etc. all matter
> far more. Spend whatever optimization time you have on that which will make
> a real difference for the end-user.

in all the cases, there's 99% chances that you'll gain more by
tweaking your app than trying to optimize the protocol between nginx
and tomcat !

>
> --
> RPM
>
> Posted at Nginx Forum: http://forum.nginx.org/read.php?2,232172,232225#msg-232225
>
> _______________________________________________
> nginx mailing list
> nginx@nginx.org
> http://mailman.nginx.org/mailman/listinfo/nginx

_______________________________________________
nginx mailing list
nginx@nginx.org
http://mailman.nginx.org/mailman/listinfo/nginx
Subject Author Posted

AJP

Alex Samad - Yieldbroker October 24, 2012 11:50PM

Re: AJP

姚伟斌 October 25, 2012 01:40AM

RE: AJP

Alex Samad - Yieldbroker October 25, 2012 01:44AM

Re: AJP

Jérôme Loyet October 25, 2012 02:12AM

RE: AJP

Alex Samad - Yieldbroker October 25, 2012 05:04AM

Re: AJP

rmalayter October 25, 2012 12:31PM

Re: AJP

Jérôme Loyet October 25, 2012 12:36PM

RE: AJP

Alex Samad - Yieldbroker October 25, 2012 03:14PM

Re: AJP

Jérôme Loyet October 25, 2012 03:24PM

RE: AJP

Alex Samad - Yieldbroker October 25, 2012 04:14PM

Re: AJP

Jérôme Loyet October 25, 2012 04:24PM



Sorry, only registered users may post in this forum.

Click here to login

Online Users

Guests: 315
Record Number of Users: 8 on April 13, 2023
Record Number of Guests: 421 on December 02, 2018
Powered by nginx      Powered by FreeBSD      PHP Powered      Powered by MariaDB      ipv6 ready