[PHP-DB] MySQL persistent connections

2004-06-11 Thread Radek Zajkowski


Hey there PHP fiends,

I have a bit of cookie here. We're designing a PHP based app that uses MySQL as
the data storage. Scalability is an issue, we want to be able to handle up to
1 people utilizing the system (not at once of course).

Question is, should I be connecting and disconnecting from the DB on each
operation or increase the maximum number of allowed connections with MySQL and
connect just once.

TIA

R>

-

-- 
PHP Database Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP-DB] MySQL persistent connections

2004-06-13 Thread Michael Gale
Hello,

I am no expert but I believe more information is required, like what
would be the average return of a mysql operation ? How many different
DB's are you accessing ? How many different usernames and passwords for
mysql are you using ??

I believe persistent connections are only useful when the amount of DB
connections being made is inversely proportional to the amount of data
being returned.

That is if you have 50 connections being created to check the same one
field in one table. Then persistent connections would be worth it. But
is you are returning 4-5MB of data per-query then persistent connections
would not be worth it.

Plus with persistent connections I have heard most people have issues
with hitting the too many open connections limit. Because the
connections are not being closed or reused.

Michael.




On Fri, 11 Jun 2004 11:38:37 -0400
Radek Zajkowski <[EMAIL PROTECTED]> wrote:

> 
> 
> Hey there PHP fiends,
> 
> I have a bit of cookie here. We're designing a PHP based app that uses
> MySQL as the data storage. Scalability is an issue, we want to be able
> to handle up to 1 people utilizing the system (not at once of
> course).
> 
> Question is, should I be connecting and disconnecting from the DB on
> each operation or increase the maximum number of allowed connections
> with MySQL and connect just once.
> 
> TIA
> 
> R>
> 
> -
> 
> -- 
> PHP Database Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
> 

-- 
PHP Database Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php