From 8a72c81358dae789f40f1e8461bc1f3d05968e7b Mon Sep 17 00:00:00 2001 From: Michael Levin Date: Fri, 18 Oct 2024 11:06:56 -0400 Subject: [PATCH 1/3] [Feature] Increase consumer old heap size --- manifest.consumer.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/manifest.consumer.yml b/manifest.consumer.yml index e64bd1b1..4c4eb0ba 100644 --- a/manifest.consumer.yml +++ b/manifest.consumer.yml @@ -26,7 +26,7 @@ applications: NEW_RELIC_APP_NAME: ${NEW_RELIC_APP_NAME} NEW_RELIC_LICENSE_KEY: ${NEW_RELIC_LICENSE_KEY} NODE_ENV: production - NODE_OPTIONS: --max-old-space-size=192 + NODE_OPTIONS: --max-old-space-size=312 PGSSLMODE: true PROXY_USERNAME: ${PROXY_USERNAME} PROXY_PASSWORD: ${PROXY_PASSWORD} From f9dfa71d087dbe67f27b6d7ac61ee308663708f4 Mon Sep 17 00:00:00 2001 From: Michael Levin Date: Fri, 18 Oct 2024 12:21:22 -0400 Subject: [PATCH 2/3] [Feature] Add retry settings for failed jobs --- index.js | 3 +++ 1 file changed, 3 insertions(+) diff --git a/index.js b/index.js index 4672d7b6..81f95d14 100644 --- a/index.js +++ b/index.js @@ -143,6 +143,9 @@ async function runQueuePublish(options = {}) { ), { priority: _messagePriority(reportConfig), + retryLimit: 2, + retryDelay: 10, + retryBackoff: true, singletonKey: `${appConfig.scriptName}-${agency.agencyName}-${reportConfig.name}`, }, ); From 3bcc69a35552106d3d74b6b0f2dcd956c4624023 Mon Sep 17 00:00:00 2001 From: Michael Levin Date: Fri, 18 Oct 2024 14:53:48 -0400 Subject: [PATCH 3/3] [Tech Debt] Decrease memory for publisher, increase for consumer --- manifest.consumer.yml | 2 +- manifest.publisher.yml | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/manifest.consumer.yml b/manifest.consumer.yml index 4c4eb0ba..16ad4b8b 100644 --- a/manifest.consumer.yml +++ b/manifest.consumer.yml @@ -4,7 +4,7 @@ applications: # 1GB is needed right at startup because many child processes are spawned in # parallel. This could be reduced if we limited the number of simultaneous # processes. - memory: 384M + memory: 416M disk_quota: 512M health-check-type: process buildpacks: diff --git a/manifest.publisher.yml b/manifest.publisher.yml index 871d25ed..12a2ed8d 100644 --- a/manifest.publisher.yml +++ b/manifest.publisher.yml @@ -4,7 +4,7 @@ applications: # 1GB is needed right at startup because many child processes are spawned in # parallel. This could be reduced if we limited the number of simultaneous # processes. - memory: 256M + memory: 192M disk_quota: 512M health-check-type: process buildpacks: