[nycphp-talk] p_connect
Hans Zaunere
hans at nyphp.org
Tue Aug 5 10:09:57 EDT 2003
Brian Pang wrote:
> I've always used mysql_pconnect and haven't had any problems with it,
> perhaps because, as you say, it works very quickly. I guess I copped the
> pconnect style from original db connect scripts when I was first
> learning and, since it wasn't broke, never thought about it again.
>
>
> off the subject... maybe I should just DL my own copy of the PHP manual,
> but is it me or is the php.net site really slow right now?
Yeah, it's always slow :)
http://us2.php.net/ is always pretty snappy for me.
H
>
>
>>
>>Daniel Kushner wrote:
>>
>>>Hi Matt,
>>>
>>>The main reason would be if you have more Web processes than Database
>>>connections. There just wouldn't be enough to go around :(
>>>
>>>>Anyone know why you wouldn't use p_connect to make a connection
>>>>to a database?
>>>>It seems like it would be better than regular connect in every case.
>>>>
>>>>Or at least does anyone know of any problems with it?
>>
>>It depends on the DB for the most part. PHP's integration with some
>
> APIs, like OCI8 isn't 100% from what I've seen, and you can get stale
> connections or other odd behavior. On Oracle, this is important, since
> creating and tearing down connections are extremely expensive. With
> MySQL, connections open and close very quickly, and I've found it rare
> to see much benefit from persistent connections.
>
>>H
>>
>>
>>_______________________________________________
>>talk mailing list
>>talk at lists.nyphp.org
>>http://lists.nyphp.org/mailman/listinfo/talk
>>
>>
>
>
>
>
> _______________________________________________
> talk mailing list
> talk at lists.nyphp.org
> http://lists.nyphp.org/mailman/listinfo/talk
More information about the talk
mailing list