{"id":26494729,"url":"https://github.com/compwright/should-retry","last_synced_at":"2026-02-17T15:01:09.762Z","repository":{"id":282438121,"uuid":"948616211","full_name":"compwright/should-retry","owner":"compwright","description":null,"archived":false,"fork":false,"pushed_at":"2025-03-14T16:47:12.000Z","size":9,"stargazers_count":1,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-09-30T19:52:23.032Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"","language":"PHP","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/compwright.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2025-03-14T16:42:34.000Z","updated_at":"2025-06-13T09:13:35.000Z","dependencies_parsed_at":"2025-03-14T18:30:26.541Z","dependency_job_id":null,"html_url":"https://github.com/compwright/should-retry","commit_stats":null,"previous_names":["compwright/should-retry"],"tags_count":1,"template":false,"template_full_name":null,"purl":"pkg:github/compwright/should-retry","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/compwright%2Fshould-retry","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/compwright%2Fshould-retry/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/compwright%2Fshould-retry/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/compwright%2Fshould-retry/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/compwright","download_url":"https://codeload.github.com/compwright/should-retry/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/compwright%2Fshould-retry/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":29548201,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-02-17T14:33:00.708Z","status":"ssl_error","status_checked_at":"2026-02-17T14:32:58.657Z","response_time":100,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.5:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2025-03-20T10:24:28.651Z","updated_at":"2026-02-17T15:01:09.712Z","avatar_url":"https://github.com/compwright.png","language":"PHP","funding_links":[],"categories":[],"sub_categories":[],"readme":"# compwright/should-retry\n\n## Installation\n\n    $ composer require compwright/should-retry\n\n## Usage with Guzzle HTTP library\n\nThe popular Guzzle HTTP library includes a retry middleware:\n\n```php\nuse Compwright\\ShouldRetry\\ShouldRetry;\nuse Compwright\\ShouldRetry\\RetryAfter;\n\n$handler = GuzzleHttp\\HandlerStack::create();\n\n$handler-\u003epush(\n    GuzzleHttp\\Middleware::retry(\n        new ShouldRetry(),\n        new RetryAfter()\n    ),\n    'retry'\n);\n\n$client = new GuzzleHttp\\Client([\n    'handler' =\u003e $handler,\n]);\n```\n\n## Configuration\n\nBoth ShouldRetry and RetryAfter are configurable via setters:\n\n```php\n$shouldRetry = (new ShouldRetry())\n    -\u003esetMaxRetries(5)\n    -\u003esetRetryOnStatusCodes(429)\n    -\u003esetLogger($logger); // attach PSR-3 debug logger\n\n$retryAfter = (new RetryAfter())\n    -\u003esetRetryAfterHeader('x-rate-limit-reset')\n    -\u003esetFallbackStrategy($fallback);\n```\n\nDefault configuration:\n\n* Retry up to 3 times\n* Retry on 429, 500, 502, 503, 504 error codes\n* When retrying, wait `Retry-After` seconds\n* If header is missing, use exponential backoff\n\n## License\n\nMIT License\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcompwright%2Fshould-retry","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fcompwright%2Fshould-retry","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcompwright%2Fshould-retry/lists"}