Skip to content

Commit

Permalink
fixups post reviews
Browse files Browse the repository at this point in the history
  • Loading branch information
benzekrimaha committed May 15, 2024
1 parent be0f3e1 commit b70e257
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions CountItems/masterProcess.js
Original file line number Diff line number Diff line change
Expand Up @@ -22,11 +22,11 @@ const loggerConfig = {
werelogs.configure(loggerConfig);
const log = new werelogs.Logger('S3Utils::CountItems::Master');

const frequency = process.env.PROMETHEUS_POLLING_FREQUENCY && !Number.isNaN(process.env.PROMETHEUS_POLLING_FREQUENCY)
const prometheusPollingFrequency = process.env.PROMETHEUS_POLLING_FREQUENCY && !Number.isNaN(process.env.PROMETHEUS_POLLING_FREQUENCY)
? Number.parseInt(process.env.PROMETHEUS_POLLING_FREQUENCY, 10)
: 30;

const threshold = process.env.PROMETHEUS_POLLING_THRESHOLD && !Number.isNaN(process.env.PROMETHEUS_POLLING_THRESHOLD)
const promtheusPollingThreshold = process.env.PROMETHEUS_POLLING_THRESHOLD && !Number.isNaN(process.env.PROMETHEUS_POLLING_THRESHOLD)
? Number.parseInt(process.env.PROMETHEUS_POLLING_THRESHOLD, 10)
: 5;

Expand Down Expand Up @@ -78,5 +78,5 @@ countMaster.start(err => {
}
setTimeout(() => {
countMaster.stop(null, () => process.exit(0));
}, threshold * frequency * 1000 * 4);
}, promtheusPollingThreshold * prometheusPollingFrequency * 1000 * 4);
});

0 comments on commit b70e257

Please sign in to comment.