diff --git a/docs/integrations/github/discovery.md b/docs/integrations/github/discovery.md index 3200a55bd2..a0c3fed153 100644 --- a/docs/integrations/github/discovery.md +++ b/docs/integrations/github/discovery.md @@ -60,8 +60,9 @@ And then add the processors to your catalog builder: ## Configuration To use the discovery processor, you'll need a GitHub integration -[set up](locations.md) with a `GITHUB_TOKEN`. Then you can add a location target -to the catalog configuration: +[set up](locations.md) with either a [Personal Access Token](../../getting-started/configuration.md#setting-up-a-github-integration) or [GitHub Apps](./github-apps.md). + +Then you can add a location target to the catalog configuration: ```yaml catalog: @@ -96,14 +97,12 @@ When using a custom pattern, the target is composed of three parts: ## GitHub API Rate Limits -GitHub [rate limits] API requests to 5,000 per hour (or more for Enterprise +GitHub [rate limits](https://docs.github.com/en/rest/overview/resources-in-the-rest-api#rate-limiting) API requests to 5,000 per hour (or more for Enterprise accounts). The default Backstage catalog backend refreshes data every 100 seconds, which issues an API request for each discovered location. This means if you have more than ~140 catalog entities, you may get throttled by -rate limiting. This will soon be resolved once catalog refreshes make use of -ETags; to work around this in the meantime, you can change the refresh rate of -the catalog in your `packages/backend/src/plugins/catalog.ts` file: +rate limiting. You can change the refresh rate of the catalog in your `packages/backend/src/plugins/catalog.ts` file: ```typescript const builder = await CatalogBuilder.create(env); @@ -117,5 +116,3 @@ which carries a much higher rate limit at GitHub. This is true for any method of adding GitHub entities to the catalog, but especially easy to hit with automatic discovery. - -[rate limits]: https://docs.github.com/en/rest/overview/resources-in-the-rest-api#rate-limiting