Skip to content

[332123] Fetch GitHub repos via GraphQL API

Rostyslav Safonov requested to merge rs-332123-fix-414-github-fetch into master

What does this MR do and why?

Fix for GitHub API (Octokit) search query can grow too long and run into a HTTP 414 (URI Too Long)

Query that we send to GitHub to fetch repositories list could be too big to fit into REST GET request by its size. That is the reason why we should migrate into GraphQL query which is basically POST and much bigger limit size.

Screenshots or screen recordings

Local test

Note: I changed Import::GithubController::PAGE_LENGTH to 5 to make it more clear that it works with few pages fetching.

How to set up and validate locally

Go to the import GitHub page and see the list (FF remove_legacy_github_client should be enabled).

Edited by Rostyslav Safonov

Merge request reports

Loading