Skip to content

Commit

Permalink
chore: removed reset task interval from config
Browse files Browse the repository at this point in the history
  • Loading branch information
wwills2 committed May 31, 2024
1 parent 2b015c2 commit 7de1b68
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 11 deletions.
12 changes: 2 additions & 10 deletions src/tasks/reset-audit-table.js
Original file line number Diff line number Diff line change
@@ -1,9 +1,6 @@
import { SimpleIntervalJob, Task } from 'toad-scheduler';
import { Audit, Meta } from '../models';
import { logger } from '../config/logger.cjs';
import { getConfig } from '../utils/config-loader';
const CONFIG = getConfig().APP;

import dotenv from 'dotenv';
import _ from 'lodash';
dotenv.config();
Expand Down Expand Up @@ -53,18 +50,13 @@ const task = new Task('reset-audit-table', async () => {
);
}
} catch (error) {
logger.error(
`Retrying in ${
CONFIG?.TASKS?.GOVERNANCE_SYNC_TASK_INTERVAL || 30
} seconds`,
error,
);
logger.error('Retrying in 600 seconds', error);
}
});

const job = new SimpleIntervalJob(
{
seconds: CONFIG?.TASKS?.RESET_AUDIT_TASK_INTERVAL || 30,
seconds: 600,
runImmediately: true,
},
task,
Expand Down
1 change: 0 additions & 1 deletion src/utils/defaultConfig.js
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,6 @@ export const defaultConfig = {
ORGANIZATION_META_SYNC_TASK_INTERVAL: 300,
PICKLIST_SYNC_TASK_INTERVAL: 60,
MIRROR_CHECK_TASK_INTERVAL: 86460,
RESET_AUDIT_TASK_INTERVAL: 300,
},
},
GOVERNANCE: {
Expand Down

0 comments on commit 7de1b68

Please sign in to comment.