Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[7.x] Add PDOException's try again as a lost connection message #32544

Merged
merged 1 commit into from
Apr 26, 2020

Conversation

IanBrison
Copy link
Contributor

Since switching to AWS Fargate, we started to encounter the error below time to time when connecting to the databases. It just suddenly comes out from nowhere and disappears in a second or so.

SQLSTATE[HY000] [2002] php_network_getaddresses: getaddrinfo failed: Try again (SQL: select * from this_is_an_example)

Of course we are investigating what's going on under there, but at the same time, I feel that Laravel should retry to create connection since it's saying "try again".

I added the whole message including SQLSTATE[HY000] [2002] since there was a discussion taken place before, claiming there was a side effect when the message was too general.
( added here #25289, but reverted here #27053 )

@taylorotwell taylorotwell merged commit 67ee649 into laravel:7.x Apr 26, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants