On Thu, Jul 10, 2008 at 7:18 AM, Kevac Marko <[EMAIL PROTECTED]> wrote:
> Thank you, but i need pool of connections too. So i think i'll fix
> mod_dbd to allow more than one connection pool and slightly change api
> to allow choosing pool of connections.

I am planning to implement something like this:

<DBDPool pool_name_1>
    DBDriver mysql
    DBDParam ...
    ...
</DBDPool>

<DBDPool pool_name_1>
    DBDriver mysql
    DBDParam ...
    ...
</DBDPool>

API will require pool name, something like this:
ap_dbd_acquire(request_rec*, const char *pool_name);
ap_dbd_open(apr_pool_t*, server_rec*, const char *pool_name);

Now what about groups...
User will be available to use same pool, by giving only pool name and
prepare statements:

<DBDPool name_that_already_exists>
    DBDPrepare ...
</DBDPool>

And if user set some variable, that is different from previous pool declaration:

<DBDPool name_that_already_exists>
    DBDriver different_from_that_one_in_name_that_already_exists
</DBDPool>

Than user will get something like "Your name_that_already_exists
definition contradicts with another definition. Please rename your
pool, or remove contradicting parameters".

What do you think about all that?

-- 
С уважением, Кевац Марко
Sincerely yours, Kevac Marko

Reply via email to