Hi folks,

I've got some questions regarding module development and the possible situation 
that apache reloads its configuration.

My module holds a reslist of connected sockets which are acquired and 
released/invalidated on each request. These connections are persistent and 
keeping them alive is a must (so there's no workaround for the reslist). The 
connections are themselves stateless - they're just for gathering some bits of 
information.

I've got a handful of questions regarding this situation. When the 
configuration is reloaded (the socket endpoint is configured via the config), 
the configuration pool is destroyed. So it is obviously the wrong choice for 
allocating my reslist? I currently allocate them from the child pool in 
child_init.
I thought about allocating the connections from the config pool (respectively a 
subpool of it), if and only if the reload happens when apache isn't currently 
handling any requests. Otherwise the reslist cleanup would abort() when any 
resource is still acquired, according to the documentation.
I couldn't find any documentation when the config reload is exactly invoked, so 
it's really not clear to me if this would be the right way. Besides I think 
using the config pool wouldn't be thread safe?

Just another question, to point things out for me: Each worker has its own copy 
of the (same) server_rec, right? And following, each server_rec in each worker 
has its own module configuration?

I tried the following steps to find the information myself:
- searched google
- checked tutorials on the net
- checked the apr and apr-util documentiation
- bought and considered The Apache Modules Book by Nick Kew

Besides, I took a deeper look at mod_dbd, which does a similar job and it 
wasn't really clear to me. I guess the "groups" are there for handling a config 
change? As the connections are stateful, I'm unsure that this concept (if it 
works as I suspect) is a little bit overpowered for me?

Oh and by the way:
I'm developing for Apache 2.2(.14 currently) with the worker-mpm.

I hope you can help me out with my questions. Any help will be greatly 
appreciated.

Regards,
Edgar

---------------------------------------------------------------------
The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:http://httpd.apache.org/userslist.html> for more info.
To unsubscribe, e-mail: users-unsubscr...@httpd.apache.org
   "   from the digest: users-digest-unsubscr...@httpd.apache.org
For additional commands, e-mail: users-h...@httpd.apache.org

Reply via email to