-
Notifications
You must be signed in to change notification settings - Fork 46
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Use separate queues to fetch fresh vs. old PRs.
Closes #15.
- Loading branch information
Showing
3 changed files
with
24 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,14 @@ | ||
queue: | ||
- name: default | ||
# Queue used for fetching recently-updated PRs. | ||
# Has a faster processing rate so that the site stays up-to-date. | ||
- name: fresh-prs | ||
rate: 100/m | ||
bucket_size: 100 | ||
max_concurrent_requests: 100 | ||
# Queue used for fetching older PRs. | ||
# Has a lower processing rate so that bulk-loading doesn't exhaust | ||
# the GitHub API call rate-limit. | ||
- name: old-prs | ||
rate: 2500/h # GitHub's default limit is 5000 requests per hour | ||
bucket_size: 20 | ||
max_concurrent_requests: 20 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,2 +1,8 @@ | ||
# OAuth key used for issuing requests against GitHub API | ||
GITHUB_OAUTH_KEY = '' | ||
|
||
# Threshold (in seconds) used for classifying "fresh" pull requests. | ||
# If a pull request has been updated within the last FRESHNESS_THRESHOLD | ||
# seconds, then updates for it are fetched using a task queue with a higher | ||
# processing rate. | ||
FRESHNESS_THRESHOLD = 60 * 60 * 24 |