OpenAPITools / OpenAPITools/openapi-generator

Rate limiting

Open
#18,240 1 comment 1 reaction 0 assignees View on GitHub

Nobody has claimed this yet.

Enhancement: Feature
Dominant language
Java
Stars
26.8k
Forks
7.7k
PR merge metrics
PR metrics pending

Description

Is your feature request related to a problem? Please describe.

I'm using the Go generator to implement a CLI version of my api's
A need to implement rate limiting : when status code 429 : retry x times with different duration between retries

Describe the solution you'd like

A configurable solution saying : retries= true, list of durations between different retries

Describe alternatives you've considered

I will now update the generated code replacing client.go : CallApi : replace line resp, err := c.cfg.HTTPClient.Do(request) by a wrapper function.

Additional context

If there is already a more elegant solution then updating generated code, I would very much like to hear.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with the Go generator's generated client.go and the CallApi entry point, focusing on the HTTPClient.Do(request) call described in the issue. Determine how configurable retries and per-retry durations for HTTP 429 responses should be represented, then verify that generated clients support the behavior without manual edits.

Written by the indexing model from the issue text.

Assessment

Tech stack
go, openapi
Domain
api, tooling
Issue type
Feature
Difficulty
5/5
Estimated time
Over a week
Activity status
Quiet
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.