HomePhorge

Add retry loop when trying to establish db connection, log retries

Description

Add retry loop when trying to establish db connection, log retries

Summary:
We retried if a db connection was lost when executing a query, but not when
establishing a connection. I've seen a lot of failures establishing connections
in our install (they go away when retrying), so this diff retries when
establishing connections, and logs when we retry.

Test Plan:

  • Loaded phabricator in a sandbox
  • Temporarily added a check in the try block to throw if there were still retries (to test logging, retry logic)

Reviewers: epriestley, blair

Reviewed By: epriestley

CC: aran, btrahan

Differential Revision: https://secure.phabricator.com/D1460

Details

Provenance
Nick HarperAuthored on Jan 19 2012, 3:04 PM
themackabuPushed on Mar 25 2025, 8:07 PM
Parents
rP27f52efd37ee: Minor, fix spelling issues detected by linter.
Branches
Loading...
Tags
Loading...

Event Timeline