All Notable changes to guzzle_retry_middleware
will be documented in this file.
Updates should follow the Keep a CHANGELOG principles.
- Added GitHub build action for PHP 8.4
- Updated GitHub build
action/checkout
andaction/cache
- Implicit nullable in
doRetry
method (for PHP 8.4)
- Support for connection reset by peer (thanks @fredericgboutin-yapla)
- Include RequestInterface as
should_retry_callback
argument when triggered (thanks @Nicolai-).
.scrutinizer.yml
file (not used anymore)
- Include
on_retry_callback
argument when triggered byonRejected
(thanks @ViktorCollin) - PHP 8.3 tests in GitHub builds
- Ensure that no requests are sent after the
give_up_after_secs
expires, and fail quickly (thanks @rubentebogt) - Minor code syntax and comment fixes
- Cleaned up this CHANGELOG a bit
- New
should_retry_callback
option. - GitHub Action build for PHP 8.2
- Added some extra parameters to PHPStan checks to make sure they don't fail on automated builds
- Minor
README
updates
- Composer 2.2+ security issue with installing
phpstan/extension-installer
- Ensure
XDEBUG_MODE
environment variable is set when running PHPUnit
- Support PHP v8.1
- New
give_up_after_secs
parameter
- Upgraded to PHPStan 1.2
- Improved comments for options array
- PHPStan in dev dependencies
- Additional build checks (PHPStan and PHP-CS)
- Automatic SVG badge generation for code coverage
- Made
GuzzleRetryMiddleware::__construct
method final $options
parameter comments PHPStan was complaining aboutshouldRetryHttpResponse
values assume that the$response
parameter is not null- Ensure date
$dateFormat
is never NULL or empty string inderiveTimeoutFromHeader
- Additional cleanup based on PHPStan report
- Build dependency on scrutinizer.org service
- GitHub Actions build status badge in
README.md
- Support for custom date formats in
Retry-After
header via newretry_after_date_format
option max_allowable_timeout_secs
option to set a ceiling on the maximum time the client is willing to wait between requests- Support for Guzzle 7 class-based static methods
- Removed unnecessary comments
- Name of GitHub Action to
Github Build
.travis.yml
build support (switched to GitHub Actions)
- Ability to handle non-integer values in
Retry-After
headers (thanks @andrewdalpino) - Beginning GitHub Workflows code (support for Travis-CI will be removed in the next minor version)
- Support for PHP v8.0 in
composer.json
- Option to specify custom HTTP header name other than
Retry-After
(thanks @jamesaspence)
- Added a few things to
.gitignore
(minor) - Updated
phpunit.xml.dist
to latest spec
- Removed build tests for PHP 7.1 in
.travis.yml
- Minimum allowed version of PHPUnit is v7.5
- Made version constraint syntax consistent in
composer.json
- Updated alias for
dev-master
to2.0-dev
incomposer.json
- Cleaned up comments and updated syntax in tests to be compatible with newer versions of PHPUnit (v8 and v9)
- PHP 7.4 build test in
.travis.yml
(thanks @alexeyshockov) - Guzzle v7 support in
composer.json
(thanks @alexeyshockov)
declare(strict_types=1)
in unit test file
- Fixes to README.md
- Code tweaks: Upgrade to PSR-12 compliance
- PHP 7 goodness:
declare(strict_types=1)
and method return signatures - PHP v7.3 tests in
.travis.yml
- Made minimum requirement for PHP v7.1 (note: this is considered a compatible change)
- Updated to Carbon 2.0 (only affects tests)
- The
$request
and$options
variables are now passed by reference in the retry callback to allow for modification (thanks @Krunch!)
- Removed unsupported tests for unsupported PHP versions from
.travis.yml
file - Removed support for older versions of PHPUnit
- Always ensure positive integer used when calculating delay timeout (fixes #12)
- Retry connect exception regardless of cURL error code (thanks @LeoniePhiline) (fixes #14)
- Added
expose_retry_header
andretry_header
options for debugging purposes (thanks, @coudenysj) - Travis CI now tests PHP v7.2
- Allow newer versions of PHPUnit in
composer.json
(match Guzzle composer.json PHPUnit requirements)
- Refactored data provider method name in PHPUnit test (
testRetryOccursWhenStatusCodeMatchesProvider
→providerForRetryOccursWhenStatusCodeMatches
) - Use PHPUnit new namespaced class name
- Fix
phpunit.xml.dist
specification so that PHPUnit no longer emits warnings - Travis CI should use lowest library versions on lowest supported version of PHP (v5.5, not 5.6)
hhvm
tests in Travis CI; they were causing builds to fail
- Added
retry_enabled
parameter to allow quick disable of retry on specific requests - Added ability to pass in a callable to
default_retry_multiplier
in order to implement custom delay logic
- Added ability to retry on connect or request timeout (
retry_on_timeout
option) - Added better tests for retry callback
- Changed callback signature for
on_retry_callback
callback. Response object is no longer guaranteed to be present, so the callback signature now looks like this:(int $retryCount, int $delayTimeout, RequestInterface $request, array $options, ResponseInterface|null $response)
. - Updated Guzzle requirement to v6.3 or newer
- Clarified and cleaned up some documentation in README, including a typo.
- Everything; this is the initial version.