httpd-modules-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "William A. Rowe, Jr." <>
Subject Re: server config apr_table_t
Date Tue, 10 Oct 2006 20:08:08 GMT
Brian McQueen wrote:
> Here is how I'm initializing the table - here with a root pool:
> ASSERT(apr_pool_create(&server_config_p->stats_pool, NULL) == APR_SUCCESS);

FYI - the config pool is *nonvolatile* - your approach blows up on threaded
MPM's and further it's just bad practice.

The pool you probably want for server process lifetime is s->process->pool.

You are responsible for mutexing; and remember unless you alloc before fork
and never modify the data, it's per-process private.  If you like, you can
create an mmap in the parent if your data is going to span the process, but
again you are responsible for crossthread/crossproc mutexing of that data.

View raw message