keboola / doctrine-retry-bundle
Doctrine Retry Bundle
Package info
github.com/keboola/doctrine-retry-bundle
Type:symfony-bundle
pkg:composer/keboola/doctrine-retry-bundle
1.2.0
2026-06-29 19:44 UTC
Requires
- php: ^8.4
- doctrine/dbal: ^4.2
- doctrine/doctrine-bundle: ^3.0
- keboola/retry: ^0.5.0
- symfony/dependency-injection: ^8.0|^7.4
- symfony/http-kernel: ^8.0|^7.4
Requires (Dev)
- ext-pdo: *
- ihsw/toxiproxy-php-client: ^3.0
- keboola/coding-standard: ^16.0
- monolog/monolog: ^3.9
- phpstan/phpstan: ^2.1
- phpstan/phpstan-doctrine: ^2.0
- phpstan/phpstan-phpunit: ^2.0
- phpstan/phpstan-symfony: ^2.0
- phpunit/phpunit: ^13.0
- symfony/dotenv: ^8.0|^7.4
This package is auto-updated.
Last update: 2026-07-01 09:08:27 UTC
README
Installation
composer require keboola/doctrine-retry-bundle
Usage
Include the following code in your config/packages/doctrine.yaml file:
doctrine: dbal: options: x_connect_retries: 3
Environment
The tests connect to MySQL through a Toxiproxy instance
(used to simulate connection failures). Both are provided by the dev-doctrine-retry-bundle
Docker Compose service, so the simplest way to run them is:
docker compose run --rm dev-doctrine-retry-bundle composer ci
The following variables are required:
TEST_DATABASE_HOST - MySQL host (e.g. mysql)
TEST_DATABASE_PORT - MySQL port (e.g. 3306)
TEST_DATABASE_USER - MySQL user (e.g. root)
TEST_DATABASE_PASSWORD - MySQL password
TEST_DATABASE_DB - MySQL database name (e.g. testdatabase)
TEST_PROXY_HOST - Toxiproxy host (e.g. toxiproxy); its API is reached at http://<host>:8474