How modules are called during request processing phase

Hi All,

If I have two modules mod_A and mod_B. Both has defined a hook handler with
APR_HOOK_MIDDLE then which module will be called first to check handler.
Whether calling of module will be random for each request or it depends
which module is loaded first in httpd.conf.



Re: How modules are called during request processi

By Eric Covener at 04/16/2018 - 09:06

On Mon, Apr 16, 2018 at 6:51 AM, Hemant Chaudhary
<hemantdude. ... at gmail dot com> wrote:
mod_info can show the order. You can teach one about the other to
force the order w/ the successor/predecessor fields.

When they are the same placement and neither is a predecssor/successor
of the other:
- It is arbitrary
- It may be affected by the LoadModule order
- It may change over a long time span due to e.g. OS update or OS
change (it is related to whether your C libraries qsort() preserves
the order of equal items)
- it technically could change at any time.

Thanks to Jeff Trawick for this trivia!