blob: 7d1c0f111c67f50b3e4cfdb91c322d2aa19b620f (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
|
import { Worker } from "bullmq";
import {
LinkCrawlerQueue,
queueConnectionDetails,
} from "@remember/shared/queues";
import logger from "@remember/shared/logger";
import runCrawler from "./crawler";
logger.info("Starting crawler worker ...");
const crawlerWorker = new Worker(LinkCrawlerQueue.name, runCrawler, {
connection: queueConnectionDetails,
autorun: false,
});
await Promise.all([crawlerWorker]);
|