...
|
...
|
@@ -7,12 +7,13 @@ const {logger} = require('./libs/logger'); |
|
|
const spiderTask = require('./tasks/spider-task');
|
|
|
const calvAvgTask = require('./tasks/calc-task');
|
|
|
const clearTask = require('./tasks/clear-task');
|
|
|
const priceTask = require('./tasks/price-task');
|
|
|
|
|
|
// const priceTask = require('./tasks/price-task');
|
|
|
|
|
|
global.isProduction = process.env.NODE_ENV === 'production';
|
|
|
global.sender = new Sender(config.monitorReport); // 初始化数据上报
|
|
|
|
|
|
schedule.scheduleJob('0 */30 * * * *', () => {
|
|
|
schedule.scheduleJob('0 */15 * * * *', () => {
|
|
|
logger.info('[process]task start spiderTask');
|
|
|
spiderTask(dayjs().unix());
|
|
|
});
|
...
|
...
|
@@ -27,8 +28,7 @@ schedule.scheduleJob('0 59 23 * * *', () => { |
|
|
clearTask();
|
|
|
});
|
|
|
|
|
|
schedule.scheduleJob('0 10 * * * *', () => {
|
|
|
logger.info('[process]task start priceTask');
|
|
|
priceTask();
|
|
|
});
|
|
|
priceTask(); |
|
|
// schedule.scheduleJob('0 10 * * * *', () => {
|
|
|
// logger.info('[process]task start priceTask');
|
|
|
// priceTask();
|
|
|
// }); |
...
|
...
|
|