vona-module-a-queue 5.0.13 → 5.0.14

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.
@@ -1,20 +1,7 @@
1
- /** startup: begin */
2
- export * from '../bean/startup.loadQueueWorkers.ts';
3
- import { type IDecoratorStartupOptions } from 'vona-module-a-startup';
4
- declare module 'vona-module-a-startup' {
5
- interface IStartupRecord {
6
- 'a-queue:loadQueueWorkers': IDecoratorStartupOptions;
7
- }
8
- }
9
- declare module 'vona-module-a-queue' {
10
- interface StartupLoadQueueWorkers {
11
- }
12
- }
13
- /** startup: end */
14
1
  /** service: begin */
15
2
  export * from '../service/queue.ts';
16
3
  import 'vona';
17
- declare module 'vona-module-a-web' {
4
+ declare module 'vona-module-a-bean' {
18
5
  interface IServiceRecord {
19
6
  'a-queue:queue': never;
20
7
  }
@@ -38,6 +25,19 @@ declare module 'vona' {
38
25
  }
39
26
  }
40
27
  /** service: end */
28
+ /** startup: begin */
29
+ export * from '../bean/startup.loadQueueWorkers.ts';
30
+ import { type IDecoratorStartupOptions } from 'vona-module-a-startup';
31
+ declare module 'vona-module-a-startup' {
32
+ interface IStartupRecord {
33
+ 'a-queue:loadQueueWorkers': IDecoratorStartupOptions;
34
+ }
35
+ }
36
+ declare module 'vona-module-a-queue' {
37
+ interface StartupLoadQueueWorkers {
38
+ }
39
+ }
40
+ /** startup: end */
41
41
  /** config: begin */
42
42
  export * from '../config/config.ts';
43
43
  import type { config } from '../config/config.ts';
package/dist/index.js CHANGED
@@ -1,28 +1,12 @@
1
1
  import { BeanInfo, BeanBase, uuidv4, deepExtend, instanceDesp, beanFullNameFromOnionName, BeanSimple, BeanScopeBase, createBeanDecorator } from 'vona';
2
- import { Startup } from 'vona-module-a-startup';
3
2
  import * as Bull from 'bullmq';
4
- import { Service } from 'vona-module-a-web';
5
- import { Scope } from 'vona-module-a-bean';
3
+ import { Service, Scope } from 'vona-module-a-bean';
4
+ import { Startup } from 'vona-module-a-startup';
6
5
 
7
6
  var _dec$2, _dec2$2, _class$2;
8
- let StartupLoadQueueWorkers = (_dec$2 = Startup({
9
- instance: true,
10
- after: true
11
- }), _dec2$2 = BeanInfo({
12
- module: "a-queue"
13
- }), _dec$2(_class$2 = _dec2$2(_class$2 = class StartupLoadQueueWorkers extends BeanBase {
14
- async execute() {
15
- // load queue workers
16
- if (!this.app.meta.isTest) {
17
- this.scope.service.queue.loadQueueWorkers(this.ctx.instanceName);
18
- }
19
- }
20
- }) || _class$2) || _class$2);
21
-
22
- var _dec$1, _dec2$1, _class$1;
23
- let ServiceQueue = (_dec$1 = Service(), _dec2$1 = BeanInfo({
7
+ let ServiceQueue = (_dec$2 = Service(), _dec2$2 = BeanInfo({
24
8
  module: "a-queue"
25
- }), _dec$1(_class$1 = _dec2$1(_class$1 = class ServiceQueue extends BeanBase {
9
+ }), _dec$2(_class$2 = _dec2$2(_class$2 = class ServiceQueue extends BeanBase {
26
10
  constructor(...args) {
27
11
  super(...args);
28
12
  this._workers = {};
@@ -283,6 +267,21 @@ let ServiceQueue = (_dec$1 = Service(), _dec2$1 = BeanInfo({
283
267
  options
284
268
  };
285
269
  }
270
+ }) || _class$2) || _class$2);
271
+
272
+ var _dec$1, _dec2$1, _class$1;
273
+ let StartupLoadQueueWorkers = (_dec$1 = Startup({
274
+ instance: true,
275
+ after: true
276
+ }), _dec2$1 = BeanInfo({
277
+ module: "a-queue"
278
+ }), _dec$1(_class$1 = _dec2$1(_class$1 = class StartupLoadQueueWorkers extends BeanBase {
279
+ async execute() {
280
+ // load queue workers
281
+ if (!this.app.meta.isTest) {
282
+ this.scope.service.queue.loadQueueWorkers(this.ctx.instanceName);
283
+ }
284
+ }
286
285
  }) || _class$1) || _class$1);
287
286
 
288
287
  function config(_app) {
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "vona-module-a-queue",
3
3
  "type": "module",
4
- "version": "5.0.13",
4
+ "version": "5.0.14",
5
5
  "title": "a-queue",
6
6
  "vonaModule": {
7
7
  "dependencies": {},