jenkinsci / jenkinsci/rest-list-parameter-plugin

[FEATURE] add option to follow links on paged JSON API responses

Open
#61 0 comments 0 reactions 0 assignees View on GitHub
enhancement
Dominant language
Java
Stars
14
Forks
13
PR merge metrics
No merged PRs in 30d

Description

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

Not really, but I today notices that GitHub paginates most of its API responses and has a hard limit to 100 items per page.
This then lead to me discovering that I failed to think of this kind of situation and the logic as it is now not following the `link` header. :sweat_smile:

(unrelated, but I also noticed that the REST API of GH does not allow for server side filtering of values :disappointed: )

**Describe the solution you'd like**

If a API returns with a `link` header to the next page of values follow it and collect ALL values of the API response.

**Describe alternatives you've considered**

well there are none I can think of :thinking:

**Additional context**

n/a

Contributor guide

Open the contributing guide

Research direction

Start by locating the code that processes REST API responses and inspect how response headers and returned values are handled. Add support for following the next URL in the Link header and collecting every page's values, then verify that a paginated response produces the complete list.

Written by the indexing model from the issue text.

Assessment

Tech stack
java
Domain
api, backend
Issue type
Feature
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
45/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.