GoogleChrome / GoogleChrome/webstatus.dev
[ENHANCEMENT] Perform automated retries for GitHub API
- Dominant language
- Go
- Stars
- 254
- Forks
- 62
- Avg merge
- 1d 10h
- Merged PRs (30d)
- 64
Description
We currently have a leaf package named `gh` for GitHub API requests. In order to make it more resilient, we should try to handle and log automated retries when rate limited
This will become extremely important as we are integrating more with GitHub APIs.
In the library we use, there is a RetryAfter [value](https://github.com/google/go-github/blob/3ca13b04b6a500cc3864c58fdcd0f90a31b0b5a8/README.md?plain=1#L254) we could use.
In order to make it simple, we should use a common way for all the operations to use this. Additionally, we should also be conscious of the caller which could add a timeout to the context so that it doesn't wait forever.
Contributor guide
Research direction
Start by inspecting the leaf `gh` package and its GitHub API operations, then review the linked go-github `RetryAfter` value and how callers provide context timeouts. Done means rate-limited requests use one common retry approach, retries are logged, and caller cancellation or deadlines prevent waiting forever.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- github, go
- Domain
- api, backend
- Issue type
- Feature
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Active
- Clarity
- Mostly clear
- Newbie friendliness
- 50/100