Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

DND-1928 Fixed order when searching for repositories in org #1

Open
wants to merge 24 commits into
base: master
Choose a base branch
from

Conversation

vanta
Copy link

@vanta vanta commented Aug 1, 2023

Description

When scanning the organization, repositories are obtained using search GH API. Results are paged by 100 items, in SR we have more repositories so the final result is the result of multiple paged calls. There is no sorting order set when repos are fetched, resulting in a best-match sorting (according to GH), which occurred to be not stable sort - the same repository was returned twice or even three times on multiple pages and other repositories were lost and as a result, we observed disappearing jobs on Jenkins in Org Folder.

This PR adds a stable sorting, based on the repository name, so no results are lost.

DND-1928

Submitter checklist

  • Link to JIRA ticket in description, if appropriate.
  • Change is code complete and matches issue description
  • Automated tests have been added to exercise the changes
  • Reviewer's manual test instructions provided in PR description. See Reviewer's first task below.

Reviewer checklist

  • Run the changes and verify that the change matches the issue description
  • Reviewed the code
  • Verified that the appropriate tests have been written or valid explanation given

Documentation changes

  • Link to jenkins.io PR, or an explanation for why no doc changes are needed

Users/aliases to notify

@vanta vanta changed the title Fixed order when searching for repositories in org DND-1928 Fixed order when searching for repositories in org Aug 1, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

7 participants