mysql.connect_timeout default
| From: | Brian Moon | Date: | Mon, 07 Jan 2008 23:54:48 +0000 |
| Subject: | mysql.connect_timeout default | ||
| Groups: | php.internals | ||
| Request: | Send a blank email to internals+get-34598@lists.php.net to get a copy of this message | ||
I would like to propose we set this default value to something more appropriate for a web app. It is currently 60 seconds. That is a really long time for a web page to wait to find a mysql server, IMO. And in the spirit of PHP being web first, I think it should be shorter.
The place where this is an issue is when the server is down completely. This bit me in the butt today. If the server is up, but mysqld is not, PHP will disconnect immediately. But if there is no server answering on that IP address, PHP will wait
mysql.connection_timeout seconds before telling you it could not connect to the server.
FWIW, the default for MySQL server is 10 seconds (increased from 5 last fall) for a connection timeout.
I personally like 5 seconds for the default unless someone knows a reason this is a bad idea. Is there some other internal trigger to the connection that could cause this to be hit at 5 seconds?
Other thoughts?
--
Brian Moon
Senior Developer
------------------------------
When you care enough to spend the very least.
http://dealnews.com/