Files
bigcapital/server/src/loaders/agenda.ts
Ahmed Bouhuolia d423365a19 feat: Re-compute the given items cost job.
feat: Optimize the architecture.
2020-08-18 02:28:08 +02:00

12 lines
313 B
TypeScript

import Agenda from 'agenda';
import config from '@/../config/config';
export default ({ mongoConnection }) => {
return new Agenda({
mongo: mongoConnection,
db: { collection: config.agenda.dbCollection },
processEvery: config.agenda.pooltime,
maxConcurrency: config.agenda.concurrency,
});
};