{"id":17888278,"url":"https://github.com/squat/retry","last_synced_at":"2025-04-03T02:42:51.614Z","repository":{"id":57605085,"uuid":"102672592","full_name":"squat/retry","owner":"squat","description":"A utility library for retrying operations","archived":false,"fork":false,"pushed_at":"2017-09-07T06:03:40.000Z","size":4,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-02-08T16:44:33.963Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Go","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/squat.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2017-09-07T00:44:07.000Z","updated_at":"2017-09-07T00:44:34.000Z","dependencies_parsed_at":"2022-09-26T20:01:13.920Z","dependency_job_id":null,"html_url":"https://github.com/squat/retry","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/squat%2Fretry","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/squat%2Fretry/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/squat%2Fretry/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/squat%2Fretry/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/squat","download_url":"https://codeload.github.com/squat/retry/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":246927809,"owners_count":20856193,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","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":"2024-10-28T13:37:00.064Z","updated_at":"2025-04-03T02:42:51.593Z","avatar_url":"https://github.com/squat.png","language":"Go","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Retry\n\n[![Build Status](https://travis-ci.org/squat/retry.svg?branch=master)](https://travis-ci.org/squat/retry)\n[![Go Report Card](https://goreportcard.com/badge/github.com/squat/retry)](https://goreportcard.com/report/github.com/squat/retry)\n[![GoDoc](https://godoc.org/github.com/squat/retry?status.png)](https://godoc.org/github.com/squat/retry)\n\n## Usage\n```go\nb := ConstantBackOff{5 * time.Second}\noperation := func() error {\n\t// ... do some work\n\treturn nil\n}\nr := NewRetrier(operation, b)\nr.Notify(func(m Message) {\n\tif m.Error != nil {\n\t\tfmt.Println(m.Error)\n\t}\n})\n// Wait until the operation is done.\nr.Done()\nfmt.Println(\"All done!\")\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsquat%2Fretry","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fsquat%2Fretry","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsquat%2Fretry/lists"}