zyket 1.0.17 → 1.0.18
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/index.js +2 -0
- package/package.json +1 -1
- package/src/services/bullmq/index.js +2 -2
package/index.js
CHANGED
|
@@ -6,6 +6,7 @@ const {Route, Middleware} = require("./src/services/express");
|
|
|
6
6
|
const { Handler, Guard } = require("./src/services/socketio");
|
|
7
7
|
const Schedule = require("./src/services/scheduler/Schedule");
|
|
8
8
|
const Event = require("./src/services/events/Event");
|
|
9
|
+
const Worker = require("./src/services/bullmq/Worker");
|
|
9
10
|
|
|
10
11
|
|
|
11
12
|
module.exports = {
|
|
@@ -13,5 +14,6 @@ module.exports = {
|
|
|
13
14
|
Route, Middleware,
|
|
14
15
|
Handler, Guard,
|
|
15
16
|
Schedule, Event,
|
|
17
|
+
Worker,
|
|
16
18
|
EnvManager
|
|
17
19
|
}
|
package/package.json
CHANGED
|
@@ -21,7 +21,7 @@ module.exports = class BullMQ extends Service {
|
|
|
21
21
|
for (const queueName of queusConfig) {
|
|
22
22
|
this.queues[queueName] = new Queue(queueName, this.#connection());
|
|
23
23
|
this.queuesEvents[queueName] = new QueueEvents(queueName, this.#connection());
|
|
24
|
-
await this.#container.
|
|
24
|
+
await this.#container.get('logger').info(`Queue ${queueName} initialized`);
|
|
25
25
|
}
|
|
26
26
|
|
|
27
27
|
const workers = await this.#loadWorkersFromFolder(path.join(process.cwd(), "src", "workers"));
|
|
@@ -68,7 +68,7 @@ module.exports = class BullMQ extends Service {
|
|
|
68
68
|
#connection() {
|
|
69
69
|
return {
|
|
70
70
|
connection: {
|
|
71
|
-
url: process.env.
|
|
71
|
+
url: process.env.CACHE_URL || "redis://localhost:6379"
|
|
72
72
|
}
|
|
73
73
|
};
|
|
74
74
|
}
|