-
-
Notifications
You must be signed in to change notification settings - Fork 1.3k
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
Properly handle MySQL error code 4031 from PHP 8.4 #6363
Conversation
We need to target the 3.8.x branch with this change. Did I understand this correctly: we need the change in PHP which has not been merged yet? |
@derrabus ok I will update the PR to target 3.8. Basically the change had been merged from PHP 8.2 up, but it was breaking DBAL properly recognising the connection being lost. As it is a BC-breaking change, it has been reverted and it will be soon merged to master only. |
It has been introduced in: mysql/mysql-server@14508bb And PHP 8.4 will support it: php/php-src#13618
There hasn't been any activity on this pull request in the past 90 days, so it has been marked as stale and it will be closed automatically if no further activity occurs in the next 7 days. |
And that's my fault, dear bot. |
I'm going to merge this PR although the corresponding PR for PHP is still open. Worst-case would be that we're able to handle an error code that PHP won't ever raise. That should not break anything, I suppose. |
* 3.8.x: Properly handle MySQL error code 4031 from PHP 8.4 (doctrine#6363) CI: Add MySQL 9, reduce test matrix (doctrine#6462) Complete sentence mariadb: add nightly workflow to facilitate mariadb "nightlies" (doctrine#6435)
* 3.8.x: Properly handle MySQL error code 4031 from PHP 8.4 (doctrine#6363) CI: Add MySQL 9, reduce test matrix (doctrine#6462) Complete sentence mariadb: add nightly workflow to facilitate mariadb "nightlies" (doctrine#6435)
* 3.8.x: Properly handle MySQL error code 4031 from PHP 8.4 (doctrine#6363) CI: Add MySQL 9, reduce test matrix (doctrine#6462) Complete sentence
* 4.0.x: Properly handle MySQL error code 4031 from PHP 8.4 (doctrine#6363) CI: Add MySQL 9, reduce test matrix (doctrine#6462) Fix update/delete aliases in documentation (doctrine#6470) Complete sentence Docs: update custom platform example to use middlewares (doctrine#6460) ci: nightly - php-8.1 only + workflow_dispatch ci: nightly - php-8.1 min version (doctrine#6457) mariadb: add nightly workflow to facilitate mariadb "nightlies" (doctrine#6435)
* 4.1.x: Properly handle MySQL error code 4031 from PHP 8.4 (doctrine#6363) Add SmallFloat type (doctrine#6471) CI: Add MySQL 9, reduce test matrix (doctrine#6462) Fix update/delete aliases in documentation (doctrine#6470) Complete sentence Docs: update custom platform example to use middlewares (doctrine#6460) ci: nightly - php-8.1 only + workflow_dispatch ci: nightly - php-8.1 min version (doctrine#6457) mariadb: add nightly workflow to facilitate mariadb "nightlies" (doctrine#6435)
Summary
PHP 8.4 will support a new error code 4031 in mysqlnd when the connection is dropped due to timeouts.
It has been introduced in:
mysql/mysql-server@14508bb
And PHP 8.4 will support it:
php/php-src#13618
The PR gets the test suite green again (mysqli + pdo_mysql). I have used 4.0.x as base, but feel free to change according to your preferences.