Page MenuHomePhabricator

Support an explicit connection timeout parameter for database connections
ClosedPublic

Authored by epriestley on Dec 8 2014, 1:22 PM.
Tags
None
Referenced Files
F13162547: D10944.id.diff
Mon, May 6, 2:12 PM
Unknown Object (File)
Thu, Apr 25, 1:13 PM
Unknown Object (File)
Thu, Apr 25, 1:13 PM
Unknown Object (File)
Thu, Apr 25, 1:13 PM
Unknown Object (File)
Sat, Apr 20, 7:56 PM
Unknown Object (File)
Sun, Apr 14, 3:24 AM
Unknown Object (File)
Mar 6 2024, 2:42 PM
Unknown Object (File)
Mar 4 2024, 7:34 PM
Subscribers

Details

Summary

Ref T6238. On the instance management interface, I want to check if an instance's database is reachable by connecting to it.

If it isn't, we hang for 30-60 seconds (default connection timeout). Allow explicit specification of a timeout when establishing a connection instead.

This only does MySQLi, not MySQL. We don't need MySQL for now, although it would be nice to support it eventually (Ref T6710).

Test Plan
  • Browsed around.
  • Used short timeouts to get instance database status in instance management.

Diff Detail

Repository
rPHU libphutil
Branch
timeout
Lint
Lint Errors
SeverityLocationCodeMessage
Errorsrc/aphront/storage/connection/mysql/AphrontMySQLiDatabaseConnection.php:143XHP45PHP Compatibility
Unit
No Test Coverage
Build Status
Buildable 3196
Build 3202: [Placeholder Plan] Wait for 30 Seconds

Event Timeline

epriestley retitled this revision from to Support an explicit connection timeout parameter for database connections.
epriestley updated this object.
epriestley edited the test plan for this revision. (Show Details)
epriestley added a reviewer: btrahan.
btrahan edited edge metadata.
This revision is now accepted and ready to land.Dec 8 2014, 5:11 PM
This revision was automatically updated to reflect the committed changes.