Skip to content

Commit

Permalink
allow more alert query retries
Browse files Browse the repository at this point in the history
  • Loading branch information
haseebrabbani committed Sep 28, 2023
1 parent f9d2d48 commit 06c7ad4
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions cli/utils/get.subscription.alerts.ts
Original file line number Diff line number Diff line change
Expand Up @@ -85,8 +85,8 @@ async function runQuery(
// if alerts API returned 500, its likely due to response size being over 10MB AWS gateway limit
if (e.response?.status === 500) {
// reduce the page size in order to reduce the response size and try again
pageSize = Math.round(pageSize / 2);
shouldRetryFromError = pageSize > 50; // retry up to 4 times
pageSize = Math.floor(pageSize / 2);
shouldRetryFromError = pageSize > 1;
} else {
throw e;
}
Expand Down

0 comments on commit 06c7ad4

Please sign in to comment.