httpd-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Ben Laurie <>
Subject Re: cvs commit: apache-2.0/mpm/src/modules/standard mod_access.c mod_alias.c mod_asis.c mod_auth.c mod_autoindex.c mod_dir.c mod_env.c mod_imap.c mod_log_config.c mod_mime.c mod_negotiation.c mod_setenvif.c mod_userdir.c
Date Sun, 11 Jul 1999 16:18:17 GMT
Rasmus Lerdorf wrote:
> >   Log:
> >   Add topological sorting to hook ordering.
> 'scuse my cranial density here, but what does this actually mean?  It
> sounds cool.

It means that each hook can specify two lists of other modules, those it
wants to come after, and those it wants to come before. A topological
sort is the type of sort that orders the hooks given these constraints.

I intend to also add a cruder "put me at the front/back" style of
ordering, for things like http_core, which want to do name_translate
last of all (err, I think), no matter what, and the like. This will be
done before the topological sort (since the topological sort is stable,
and will therefore preserve as much as it can of this ordering).

My intention is to completely avoid any requirement for "magic" ordering
of modules. It also makes it possible for one module to be called first
for one hook and last for another, which is currently impossible.

See the name_translate hook in mod_alias and mod_userdir for an example
(they redundantly specify each other, but that's allowed).

BTW, I'm pretty sure not all such dependencies are documented (or even
necessarily known) so it would be good if people would keep it in the
backs of their minds when they happen to be thinking about such things.

Double-BTW: specify -DSHOW_HOOKS to see this stuff going on...




"My grandfather once told me that there are two kinds of people: those
who work and those who take the credit. He told me to try to be in the
first group; there was less competition there."
     - Indira Gandhi

View raw message