On Tue, Nov 17, 2015 at 7:29 PM, Dan Axtell <
dax...@linescale.com> wrote:
> I was under the impression from the Apache docs that running a monolithic
> Apache instance that serves your static content as well as mod_perl or other
> apps was not recommended.
It's generally not recommended because it's a huge hammer if you're
only proxying to a backend app that does all the logic.
But there's nothing wrong with it. Apache's a fine webserver.
> Some time ago I did some load testing
> that showed a noticeable improvement when I did nginx + Apache/mod_perl vs.
> monolithic Apache.
Interesting. I did the migration of all the Booking.com webserving
systems from Apache+mod_perl to nginx+uWSGI. There were a lot of
reasons we did that, but performance was not one of them.
We saw no performance improvement by migrating, and we're measuring
performance down to the millisecond-level.
I'd say the most likely cause of performance differences is that you
were either doing something really high performance <1ms apps, or
misconfiguration, most likely you ran out of Apache workers, which'll
butcher your performance since now you have a backlog.
> Also, I was under the impression that until recently, Apache 2.4 was
> incompatible with mod_perl because of API changes. I think mod_perl 2.0.9
> came out this summer which finally addressed this, but I still use Apache
> 2.2 for building mod_perl legacy apps. If you are not using any Apache API
> calls it seems simpler just to use a dedicated Plack server.
Yeah I don't know about that, I stopped using it in 2.2 IIRC. This was
February 2014-ish.
I'd totally recommend Apache+mod_perl for Plack, actually more so than
a lot of the homegrown CPAN-servers that don't have some really handy
stuff like async cleanup handlers and advanced worker configuration
etc.
uWSGI gives you a few more bells & wistles, but most won't care about
them, and if you have an existing Apache setup you're happy with just
use Apache+mod_perl for Plack.