Loadable runtime modules?

Hi,

I much prefer Nginx over Apache, and would use it as our primary HTTP
server
at my place of work (as I already do for my personal sites), but the
thing
that limits my willingness to do this is the fact that one must
recompile
Nginx to turn on/off modules. This can get tedious and problematic when
you
have multiple 3rd party modules like Phusion Passenger that you need to
compile into Nginx, especially when those modules need to be updated
with a
new version.

Are there any plans to support loadable modules at runtime like Apache?
I
figure this has probably already been discussed, in which case I’d
appreciate links to those discussions.

Cheers,
Tom

Posted at Nginx Forum:

Hi.

Maybe you need Tengine, its a fork of NGINX

http://tengine.taobao.org/

~GL

Posted at Nginx Forum:

Thanks, that’s handy to be aware of, but would still like to enquire as
to
why Nginx doesn’t support such loadable modukes?

Posted at Nginx Forum:

Thanks, that’s handy to be aware of, but would still like to enquire as to
why Nginx doesn’t support such loadable modukes?

I don’t see how that makes any harder (or more time consuming) when the
modules are linked into the binary.

There is no need to always recompile the whole source as you can just
delete
the particular module *.o files files from objs/ (objs/addon/ if for
third
party modules) and then just do ‘make’ which will recompile those and
relink
into binary.

This way you can always do a live upgrade (kill -usr2/kill -quit) for
the
running process (or roll back to the old/prev binary) without the mess
what
involves dynamically (un)loading a module on the fly.

rr

Thanks for the replies guys. Reines, I didn’t know about the method of
upgrading modules that you described. I also appreciate the reasoning in
the
link that you shared Vladmir. Much appreciated. One thing about Nginx I
do
appreciate is how much less painful it is to compile compared to Apache,
which you’re often best installing via your operating system package
manager, in which you’re choice of versioning is not great.

I just can’t wait for more distributions to abandon those painful legacy
init.d scripts in favor of the much less painful alternatives that are
much
easier to setup. Most have moved away, but I still deal with a lot of
older
distro’s where the biggest pain in setting up Nginx is getting it
working as
a managed daemon.

Anyway, cheers guys.

Posted at Nginx Forum:

On Wed, Feb 19, 2014 at 06:15:55PM -0500, wardrop wrote:

Are there any plans to support loadable modules at runtime like Apache? I
figure this has probably already been discussed, in which case I’d
appreciate links to those discussions.

http://mailman.nginx.org/pipermail/nginx/2012-September/035405.html