Beefy Boxes and Bandwidth Generously Provided by pair Networks
The stupid question is the question not asked
 
PerlMonks  

Re: Re: Database Connection Pooling: Take 2

by iguanodon (Curate)
on Mar 11, 2003 at 01:44 UTC ( #241908=note: print w/ replies, xml ) Need Help??


in reply to Re: Database Connection Pooling: Take 2
in thread Database Connection Pooling: Take 2

Very interesting. I always accepted it as Conventional Wisdom that connection pooling was the 'right' thing to do, because making connections is 'expensive'. I have to confess to some cargo cult belief here because I've always just accepted this without understanding it. Is it your opinion then that the overhead of connection pooling is as expensive or more expensive than making new connections?


Comment on Re: Re: Database Connection Pooling: Take 2
Re: Re: Re: Database Connection Pooling: Take 2
by perrin (Chancellor) on Mar 11, 2003 at 03:43 UTC
    Making new connections is expensive, but connection pooling is not the only alternative. The Apache::DBI module keeps connections open so that you don't need to re-connect. It is not "pooling" because the connections are not shared -- each process opens a connection and keeps it open.

    This will change with the thread support in mod_perl 2 and a future release of DBI which will include direct support for connection pooling. In the meantime, what Apache::DBI does is fine for most sites.

Re: Re: Re: Database Connection Pooling: Take 2
by mpeppler (Vicar) on Mar 11, 2003 at 19:38 UTC
    The reason I've used connection pooling is when the total number of clients is potentially very large (5-10 thousand or more). Maintaining a very large number of connections on the database server generates quite a bit of overhead. If these connections aren't active all the time then pooling them can make sense.

    Michael

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://241908]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others browsing the Monastery: (9)
As of 2014-12-22 17:50 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    Is guessing a good strategy for surviving in the IT business?





    Results (126 votes), past polls