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

[chore] Bump rate at which we process issues #22825

Merged
merged 3 commits into from
May 26, 2023

Conversation

TylerHelmuth
Copy link
Member

Description:
This PR attempts to increase the amount of issues/PRs the Close State Issues/PRs actions can process by:

  • increase the number of operations it may perform. We have at least 1000 per hour via actions, so 400 an hour from this job should still leave plenty for the ping-code-owners and other jobs that interact with our PRs/Issues.
  • Increase how many times it runs a night. This is a temporary solution to try and get us caught up.
  • Allow manually triggering the job. I am hoping to use this to test and to manually run the job while we try an catch up.

@TylerHelmuth TylerHelmuth requested review from a team and mx-psi May 26, 2023 17:35
@TylerHelmuth
Copy link
Member Author

Added a rate_limit check before and after to monitor how this change affects our limits. Output will look something like this:

❯ curl https://api.github.com/rate_limit
{
  "resources": {
    "core": {
      "limit": 60,
      "remaining": 59,
      "reset": 1685127794,
      "used": 1,
      "resource": "core"
    },
    "graphql": {
      "limit": 0,
      "remaining": 0,
      "reset": 1685128196,
      "used": 0,
      "resource": "graphql"
    },
    "integration_manifest": {
      "limit": 5000,
      "remaining": 5000,
      "reset": 1685128196,
      "used": 0,
      "resource": "integration_manifest"
    },
    "search": {
      "limit": 10,
      "remaining": 10,
      "reset": 1685124656,
      "used": 0,
      "resource": "search"
    }
  },
  "rate": {
    "limit": 60,
    "remaining": 59,
    "reset": 1685127794,
    "used": 1,
    "resource": "core"
  }
}

@evan-bradley
Copy link
Contributor

Those numbers look a little off, the docs say we should have a larger request count than that. Could you try printing the headers from a request like this?

curl --request GET \
          --include \
          --silent \
          --show-errors \
          --dump-header - \
          --url https://api.github.com/repos/${{ github.repository }}/issues \
          --header 'authorization: Bearer ${{ secrets.GITHUB_TOKEN }}' \
          --header 'content-type: application/json' \
          --output /dev/null \
          --fail

@TylerHelmuth
Copy link
Member Author

TylerHelmuth commented May 26, 2023

@evan-bradley Those numbers are from my own token which is why they are so low.

But looking at the command again maybe it isn't smart enough to use our token. I'll update the command.

@evan-bradley
Copy link
Contributor

Got it, thanks. Looks like that API is the right one to use too, let's go with that.

@TylerHelmuth
Copy link
Member Author

@evan-bradley here is what it looks like run in my fork, so I'm not confident in it anymore: https://github.com/TylerHelmuth/opentelemetry-collector-contrib/actions/runs/5093968840/jobs/9157205402

@TylerHelmuth TylerHelmuth force-pushed the increase-operations branch from f9a64a5 to d603081 Compare May 26, 2023 18:43
@TylerHelmuth
Copy link
Member Author

@evan-bradley
Copy link
Contributor

Agreed, looks better. I think the issue was that the auth token was missing on the curl request.

@TylerHelmuth TylerHelmuth merged commit 6eb548d into open-telemetry:main May 26, 2023
@github-actions github-actions bot added this to the next release milestone May 26, 2023
@TylerHelmuth TylerHelmuth deleted the increase-operations branch May 27, 2023 01:44
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants