fix: add injection for jobqueque
This commit is contained in:
1 parent
4c92922d40
commit
93fa4ca13b
2 files changed
+3
-3
No files matched your search
@@ -192,6 +192,7 @@ const startApp = async () => {
|
|||||||
networkService,
|
networkService,
|
||||||
notificationService,
|
notificationService,
|
||||||
settingsService,
|
settingsService,
|
||||||
|
stringService,
|
||||||
logger,
|
logger,
|
||||||
Queue,
|
Queue,
|
||||||
Worker
|
Worker
|
||||||
|
|||||||
@@ -12,8 +12,6 @@ const QUEUE_LOOKUP = {
|
|||||||
};
|
};
|
||||||
const getSchedulerId = (monitor) => `scheduler:${monitor.type}:${monitor._id}`;
|
const getSchedulerId = (monitor) => `scheduler:${monitor.type}:${monitor._id}`;
|
||||||
|
|
||||||
import ServiceRegistry from "../service/serviceRegistry.js";
|
|
||||||
import StringService from "../service/stringService.js";
|
|
||||||
|
|
||||||
class NewJobQueue {
|
class NewJobQueue {
|
||||||
static SERVICE_NAME = SERVICE_NAME;
|
static SERVICE_NAME = SERVICE_NAME;
|
||||||
@@ -24,6 +22,7 @@ class NewJobQueue {
|
|||||||
networkService,
|
networkService,
|
||||||
notificationService,
|
notificationService,
|
||||||
settingsService,
|
settingsService,
|
||||||
|
stringService,
|
||||||
logger,
|
logger,
|
||||||
Queue,
|
Queue,
|
||||||
Worker
|
Worker
|
||||||
@@ -46,7 +45,7 @@ class NewJobQueue {
|
|||||||
this.settingsService = settingsService;
|
this.settingsService = settingsService;
|
||||||
this.logger = logger;
|
this.logger = logger;
|
||||||
this.Worker = Worker;
|
this.Worker = Worker;
|
||||||
this.stringService = ServiceRegistry.get(StringService.SERVICE_NAME);
|
this.stringService = stringService;
|
||||||
|
|
||||||
QUEUE_NAMES.forEach((name) => {
|
QUEUE_NAMES.forEach((name) => {
|
||||||
this.queues[name] = new Queue(name, { connection });
|
this.queues[name] = new Queue(name, { connection });
|
||||||
|
|||||||
Reference in new issue
Block a user