@tsed/bullmq 7.38.0
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/.barrelsby.json +5 -0
- package/README.md +180 -0
- package/coverage/clover.xml +180 -0
- package/coverage/coverage-final.json +5 -0
- package/coverage/coverage-summary.json +6 -0
- package/coverage/lcov-report/Job.ts.html +136 -0
- package/coverage/lcov-report/base.css +224 -0
- package/coverage/lcov-report/block-navigation.js +87 -0
- package/coverage/lcov-report/decorators/Job.ts.html +136 -0
- package/coverage/lcov-report/decorators/index.html +116 -0
- package/coverage/lcov-report/dispatchers/JobDispatcher.ts.html +148 -0
- package/coverage/lcov-report/dispatchers/index.html +116 -0
- package/coverage/lcov-report/favicon.png +0 -0
- package/coverage/lcov-report/index.html +161 -0
- package/coverage/lcov-report/prettify.css +1 -0
- package/coverage/lcov-report/prettify.js +2 -0
- package/coverage/lcov-report/sort-arrow-sprite.png +0 -0
- package/coverage/lcov-report/sorter.js +196 -0
- package/coverage/lcov-report/src/BullMQModule.ts.html +361 -0
- package/coverage/lcov-report/src/config/config.ts.html +142 -0
- package/coverage/lcov-report/src/config/index.html +116 -0
- package/coverage/lcov-report/src/decorators/Job.ts.html +136 -0
- package/coverage/lcov-report/src/decorators/index.html +116 -0
- package/coverage/lcov-report/src/dispatchers/JobDispatcher.ts.html +151 -0
- package/coverage/lcov-report/src/dispatchers/index.html +116 -0
- package/coverage/lcov-report/src/index.html +116 -0
- package/coverage/lcov-report/src/processors/ProcessorFactory.ts.html +166 -0
- package/coverage/lcov-report/src/processors/index.html +116 -0
- package/coverage/lcov.info +245 -0
- package/jest.config.js +11 -0
- package/lib/cjs/BullMQModule.js +98 -0
- package/lib/cjs/BullMQModule.js.map +1 -0
- package/lib/cjs/config/config.js +3 -0
- package/lib/cjs/config/config.js.map +1 -0
- package/lib/cjs/contracts/JobMethods.js +3 -0
- package/lib/cjs/contracts/JobMethods.js.map +1 -0
- package/lib/cjs/contracts/JobStore.js +3 -0
- package/lib/cjs/contracts/JobStore.js.map +1 -0
- package/lib/cjs/contracts/index.js +9 -0
- package/lib/cjs/contracts/index.js.map +1 -0
- package/lib/cjs/decorators/Job.js +17 -0
- package/lib/cjs/decorators/Job.js.map +1 -0
- package/lib/cjs/decorators/JobController.js +17 -0
- package/lib/cjs/decorators/JobController.js.map +1 -0
- package/lib/cjs/decorators/index.js +8 -0
- package/lib/cjs/decorators/index.js.map +1 -0
- package/lib/cjs/dispatchers/JobDispatcher.js +27 -0
- package/lib/cjs/dispatchers/JobDispatcher.js.map +1 -0
- package/lib/cjs/dispatchers/index.js +8 -0
- package/lib/cjs/dispatchers/index.js.map +1 -0
- package/lib/cjs/index.js +13 -0
- package/lib/cjs/index.js.map +1 -0
- package/lib/cjs/package.json +3 -0
- package/lib/cjs/processors/ProcessorFactory.js +20 -0
- package/lib/cjs/processors/ProcessorFactory.js.map +1 -0
- package/lib/esm/BullMQModule.js +95 -0
- package/lib/esm/BullMQModule.js.map +1 -0
- package/lib/esm/config/config.js +2 -0
- package/lib/esm/config/config.js.map +1 -0
- package/lib/esm/contracts/JobMethods.js +2 -0
- package/lib/esm/contracts/JobMethods.js.map +1 -0
- package/lib/esm/contracts/JobStore.js +2 -0
- package/lib/esm/contracts/JobStore.js.map +1 -0
- package/lib/esm/contracts/index.js +6 -0
- package/lib/esm/contracts/index.js.map +1 -0
- package/lib/esm/decorators/JobController.js +13 -0
- package/lib/esm/decorators/JobController.js.map +1 -0
- package/lib/esm/decorators/index.js +5 -0
- package/lib/esm/decorators/index.js.map +1 -0
- package/lib/esm/dispatchers/JobDispatcher.js +24 -0
- package/lib/esm/dispatchers/JobDispatcher.js.map +1 -0
- package/lib/esm/dispatchers/index.js +5 -0
- package/lib/esm/dispatchers/index.js.map +1 -0
- package/lib/esm/index.js +10 -0
- package/lib/esm/index.js.map +1 -0
- package/lib/esm/package.json +3 -0
- package/lib/tsconfig.esm.tsbuildinfo +1 -0
- package/lib/tsconfig.tsbuildinfo +1 -0
- package/lib/types/BullMQModule.d.ts +14 -0
- package/lib/types/config/config.d.ts +15 -0
- package/lib/types/contracts/JobMethods.d.ts +3 -0
- package/lib/types/contracts/JobStore.d.ts +6 -0
- package/lib/types/contracts/index.d.ts +5 -0
- package/lib/types/decorators/Job.d.ts +2 -0
- package/lib/types/decorators/JobController.d.ts +2 -0
- package/lib/types/decorators/index.d.ts +4 -0
- package/lib/types/dispatchers/JobDispatcher.d.ts +9 -0
- package/lib/types/dispatchers/index.d.ts +4 -0
- package/lib/types/index.d.ts +9 -0
- package/lib/types/processors/ProcessorFactory.d.ts +7 -0
- package/package.json +51 -0
- package/src/BullMQModule.js +149 -0
- package/src/BullMQModule.spec.js +236 -0
- package/src/BullMQModule.spec.ts +184 -0
- package/src/BullMQModule.ts +93 -0
- package/src/config/config.js +2 -0
- package/src/config/config.ts +19 -0
- package/src/contracts/JobMethods.js +2 -0
- package/src/contracts/JobMethods.ts +3 -0
- package/src/contracts/JobStore.js +2 -0
- package/src/contracts/JobStore.ts +7 -0
- package/src/contracts/index.js +21 -0
- package/src/contracts/index.ts +6 -0
- package/src/decorators/Job.js +18 -0
- package/src/decorators/JobController.js +18 -0
- package/src/decorators/JobController.spec.ts +50 -0
- package/src/decorators/JobController.ts +17 -0
- package/src/decorators/index.js +20 -0
- package/src/decorators/index.ts +5 -0
- package/src/dispatchers/JobDispatcher.js +72 -0
- package/src/dispatchers/JobDispatcher.spec.js +98 -0
- package/src/dispatchers/JobDispatcher.spec.ts +52 -0
- package/src/dispatchers/JobDispatcher.ts +22 -0
- package/src/dispatchers/index.js +20 -0
- package/src/dispatchers/index.ts +5 -0
- package/src/index.ts +10 -0
- package/tsconfig.esm.json +39 -0
- package/tsconfig.json +39 -0
package/.barrelsby.json
ADDED
package/README.md
ADDED
|
@@ -0,0 +1,180 @@
|
|
|
1
|
+
<p style="text-align: center" align="center">
|
|
2
|
+
<a href="https://tsed.io" target="_blank"><img src="https://tsed.io/tsed-og.png" width="200" alt="Ts.ED logo"/></a>
|
|
3
|
+
</p>
|
|
4
|
+
|
|
5
|
+
<div align="center">
|
|
6
|
+
|
|
7
|
+
<h1>BullMQ</h1>
|
|
8
|
+
|
|
9
|
+
[](https://github.com/tsedio/tsed/actions?query=workflow%3A%22Build+%26+Release%22)
|
|
10
|
+
[](https://github.com/tsedio/tsed/blob/master/CONTRIBUTING.md)
|
|
11
|
+
[](https://coveralls.io/github/tsedio/tsed?branch=production)
|
|
12
|
+
[](https://badge.fury.io/js/%40tsed%2Fcommon)
|
|
13
|
+
[](https://github.com/semantic-release/semantic-release)
|
|
14
|
+
[](https://github.com/prettier/prettier)
|
|
15
|
+
[](https://github.com/sponsors/romakita)
|
|
16
|
+
[](https://opencollective.com/tsed)
|
|
17
|
+
|
|
18
|
+
</div>
|
|
19
|
+
|
|
20
|
+
<div align="center">
|
|
21
|
+
<a href="https://tsed.io/">Website</a>
|
|
22
|
+
<span> • </span>
|
|
23
|
+
<a href="https://tsed.io/getting-started/">Getting started</a>
|
|
24
|
+
<span> • </span>
|
|
25
|
+
<a href="https://api.tsed.io/rest/slack/tsedio/tsed">Slack</a>
|
|
26
|
+
<span> • </span>
|
|
27
|
+
<a href="https://twitter.com/TsED_io">Twitter</a>
|
|
28
|
+
</div>
|
|
29
|
+
|
|
30
|
+
<hr />
|
|
31
|
+
|
|
32
|
+
A package of Ts.ED framework. See website: https://tsed.io
|
|
33
|
+
|
|
34
|
+
## Feature
|
|
35
|
+
|
|
36
|
+
The `@tsed/bullmq` package allows you to define jobs using the `@Job` decorator and the `JobMethods` interface and have them picked up by the `BullMQ` worker.
|
|
37
|
+
|
|
38
|
+
## Installation
|
|
39
|
+
|
|
40
|
+
To begin, install the `BullMQ` module and `BullMQ` itself.
|
|
41
|
+
|
|
42
|
+
```bash
|
|
43
|
+
npm install @tsed/bullmq bullmq
|
|
44
|
+
```
|
|
45
|
+
|
|
46
|
+
## Configure the Server
|
|
47
|
+
|
|
48
|
+
Import the `@tsed/bullmq` module in your server
|
|
49
|
+
|
|
50
|
+
```ts
|
|
51
|
+
import {Configuration} from "@tsed/common";
|
|
52
|
+
import "@tsed/bullmq"; // import bullmq ts.ed module
|
|
53
|
+
|
|
54
|
+
@Configuration({
|
|
55
|
+
bullmq: {
|
|
56
|
+
queues: ["default", "special"];
|
|
57
|
+
connection: {
|
|
58
|
+
// redisio connection options
|
|
59
|
+
};
|
|
60
|
+
// optional default job options
|
|
61
|
+
defaultJobOptions: {};
|
|
62
|
+
disableWorker: false;
|
|
63
|
+
// optionally specify for which queues to start a worker for
|
|
64
|
+
// in case not all queues should be worked on
|
|
65
|
+
workerQueues: ["default"];
|
|
66
|
+
}
|
|
67
|
+
})
|
|
68
|
+
export class Server {}
|
|
69
|
+
```
|
|
70
|
+
|
|
71
|
+
## Define a Job
|
|
72
|
+
|
|
73
|
+
A job is defined as a class decorated with the `@AsJob` decorator and implementing the `Job` interface of the `@tsed/bullmq` package
|
|
74
|
+
|
|
75
|
+
```ts
|
|
76
|
+
import {JobController, JobMethods} from "@tsed/bullmq";
|
|
77
|
+
|
|
78
|
+
@JobController("example")
|
|
79
|
+
class ExampleJob implements JobMethods {
|
|
80
|
+
public handle(payload: {msg: string}) {
|
|
81
|
+
console.info("New message incoming", payload.msg);
|
|
82
|
+
}
|
|
83
|
+
}
|
|
84
|
+
```
|
|
85
|
+
|
|
86
|
+
You can also specify a non default queue as the second argument in the decorator and add any other job specific options as a third argument
|
|
87
|
+
|
|
88
|
+
```ts
|
|
89
|
+
import {JobController, JobMethods} from "@tsed/bullmq";
|
|
90
|
+
|
|
91
|
+
@JobController("other-example", "other-queue", {
|
|
92
|
+
attempts: 42
|
|
93
|
+
})
|
|
94
|
+
class OtherExampleJob implements JobMethods {
|
|
95
|
+
public handle(payload: {num: number}) {
|
|
96
|
+
console.info("look at my awesome number: ", payload.num);
|
|
97
|
+
}
|
|
98
|
+
}
|
|
99
|
+
```
|
|
100
|
+
|
|
101
|
+
## Defining a repeating job
|
|
102
|
+
|
|
103
|
+
Jobs that should be run regularly on a schedule can also easily defined using the `@AsJob` decorator
|
|
104
|
+
|
|
105
|
+
```ts
|
|
106
|
+
import {JobController, JobMethods} from "@tsed/bullmq";
|
|
107
|
+
|
|
108
|
+
@JobController("my-cron-job", "default", {
|
|
109
|
+
repeat: {
|
|
110
|
+
pattern: "* * * * *"
|
|
111
|
+
}
|
|
112
|
+
})
|
|
113
|
+
class MyCronJob implements JobMethods {
|
|
114
|
+
public handle() {
|
|
115
|
+
console.info("I run every minute!");
|
|
116
|
+
}
|
|
117
|
+
}
|
|
118
|
+
```
|
|
119
|
+
|
|
120
|
+
To register the job you now have to import it in the server so they can be detected.
|
|
121
|
+
|
|
122
|
+
```ts
|
|
123
|
+
import {Configuration} from "@tsed/common";
|
|
124
|
+
import "@tsed/bullmq"; // import bullmq ts.ed module
|
|
125
|
+
|
|
126
|
+
import "./jobs/MyCronJob";
|
|
127
|
+
|
|
128
|
+
@Configuration()
|
|
129
|
+
// server configuration
|
|
130
|
+
export class Server {}
|
|
131
|
+
```
|
|
132
|
+
|
|
133
|
+
## Dispatching jobs
|
|
134
|
+
|
|
135
|
+
Dispatching jobs is done via the `JobDispatcher` service that takes the job to be dispatched and its payload.
|
|
136
|
+
|
|
137
|
+
```ts
|
|
138
|
+
import {Service} from "@tsed/di";
|
|
139
|
+
import {JobDispatcher} from "@tsed/bullmq";
|
|
140
|
+
import {ExampleJob} from "./jobs/ExampleJob";
|
|
141
|
+
|
|
142
|
+
@Service()
|
|
143
|
+
class MyService {
|
|
144
|
+
constructor(private readonly dispatcher: JobDispatcher) {}
|
|
145
|
+
|
|
146
|
+
public async doingSomething() {
|
|
147
|
+
await this.dispatcher.dispatch(ExampleJob, {msg: "this message is part of the payload for the job"});
|
|
148
|
+
|
|
149
|
+
console.info("I just dispatched a job!");
|
|
150
|
+
}
|
|
151
|
+
}
|
|
152
|
+
```
|
|
153
|
+
|
|
154
|
+
## Contributors
|
|
155
|
+
|
|
156
|
+
Please read [contributing guidelines here](https://tsed.io/contributing.html)
|
|
157
|
+
|
|
158
|
+
<a href="https://github.com/tsedio/tsed/graphs/contributors"><img src="https://opencollective.com/tsed/contributors.svg?width=890" /></a>
|
|
159
|
+
|
|
160
|
+
## Backers
|
|
161
|
+
|
|
162
|
+
Thank you to all our backers! 🙏 [[Become a backer](https://opencollective.com/tsed#backer)]
|
|
163
|
+
|
|
164
|
+
<a href="https://opencollective.com/tsed#backers" target="_blank"><img src="https://opencollective.com/tsed/backers.svg?width=890"></a>
|
|
165
|
+
|
|
166
|
+
## Sponsors
|
|
167
|
+
|
|
168
|
+
Support this project by becoming a sponsor. Your logo will show up here with a link to your website. [[Become a sponsor](https://opencollective.com/tsed#sponsor)]
|
|
169
|
+
|
|
170
|
+
## License
|
|
171
|
+
|
|
172
|
+
The MIT License (MIT)
|
|
173
|
+
|
|
174
|
+
Copyright (c) 2016 - 2021 Romain Lenzotti
|
|
175
|
+
|
|
176
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
|
|
177
|
+
|
|
178
|
+
The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
|
|
179
|
+
|
|
180
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
|
@@ -0,0 +1,180 @@
|
|
|
1
|
+
<?xml version="1.0" encoding="UTF-8"?>
|
|
2
|
+
<coverage generated="1697441917424" clover="3.2.0">
|
|
3
|
+
<project timestamp="1697441917424" name="All files">
|
|
4
|
+
<metrics statements="150" coveredstatements="150" conditionals="31" coveredconditionals="25" methods="14" coveredmethods="14" elements="195" coveredelements="189" complexity="0" loc="150" ncloc="150" packages="4" files="4" classes="4"/>
|
|
5
|
+
<package name="src">
|
|
6
|
+
<metrics statements="92" coveredstatements="92" conditionals="22" coveredconditionals="17" methods="9" coveredmethods="9"/>
|
|
7
|
+
<file name="BullMQModule.ts" path="/Volumes/workspaces/tsed/ts-express-decorators/packages/third-parties/bullmq/src/BullMQModule.ts">
|
|
8
|
+
<metrics statements="92" coveredstatements="92" conditionals="22" coveredconditionals="17" methods="9" coveredmethods="9"/>
|
|
9
|
+
<line num="1" count="1" type="stmt"/>
|
|
10
|
+
<line num="2" count="1" type="stmt"/>
|
|
11
|
+
<line num="3" count="1" type="stmt"/>
|
|
12
|
+
<line num="4" count="1" type="stmt"/>
|
|
13
|
+
<line num="5" count="1" type="stmt"/>
|
|
14
|
+
<line num="6" count="1" type="stmt"/>
|
|
15
|
+
<line num="7" count="1" type="stmt"/>
|
|
16
|
+
<line num="8" count="1" type="stmt"/>
|
|
17
|
+
<line num="9" count="1" type="stmt"/>
|
|
18
|
+
<line num="10" count="1" type="stmt"/>
|
|
19
|
+
<line num="11" count="1" type="cond" truecount="1" falsecount="0"/>
|
|
20
|
+
<line num="12" count="1" type="stmt"/>
|
|
21
|
+
<line num="13" count="1" type="cond" truecount="0" falsecount="1"/>
|
|
22
|
+
<line num="14" count="1" type="stmt"/>
|
|
23
|
+
<line num="15" count="1" type="cond" truecount="1" falsecount="2"/>
|
|
24
|
+
<line num="16" count="1" type="stmt"/>
|
|
25
|
+
<line num="17" count="1" type="cond" truecount="1" falsecount="0"/>
|
|
26
|
+
<line num="18" count="14" type="stmt"/>
|
|
27
|
+
<line num="19" count="14" type="stmt"/>
|
|
28
|
+
<line num="20" count="14" type="stmt"/>
|
|
29
|
+
<line num="21" count="14" type="cond" truecount="1" falsecount="0"/>
|
|
30
|
+
<line num="22" count="14" type="stmt"/>
|
|
31
|
+
<line num="23" count="1" type="stmt"/>
|
|
32
|
+
<line num="24" count="1" type="cond" truecount="1" falsecount="0"/>
|
|
33
|
+
<line num="25" count="14" type="cond" truecount="1" falsecount="0"/>
|
|
34
|
+
<line num="26" count="42" type="stmt"/>
|
|
35
|
+
<line num="27" count="42" type="stmt"/>
|
|
36
|
+
<line num="28" count="42" type="stmt"/>
|
|
37
|
+
<line num="29" count="42" type="stmt"/>
|
|
38
|
+
<line num="30" count="42" type="stmt"/>
|
|
39
|
+
<line num="31" count="42" type="stmt"/>
|
|
40
|
+
<line num="32" count="42" type="stmt"/>
|
|
41
|
+
<line num="33" count="42" type="cond" truecount="1" falsecount="0"/>
|
|
42
|
+
<line num="34" count="42" type="stmt"/>
|
|
43
|
+
<line num="35" count="42" type="stmt"/>
|
|
44
|
+
<line num="36" count="42" type="stmt"/>
|
|
45
|
+
<line num="37" count="42" type="stmt"/>
|
|
46
|
+
<line num="38" count="14" type="stmt"/>
|
|
47
|
+
<line num="39" count="1" type="stmt"/>
|
|
48
|
+
<line num="40" count="1" type="cond" truecount="1" falsecount="0"/>
|
|
49
|
+
<line num="41" count="14" type="cond" truecount="1" falsecount="1"/>
|
|
50
|
+
<line num="42" count="28" type="stmt"/>
|
|
51
|
+
<line num="43" count="28" type="stmt"/>
|
|
52
|
+
<line num="44" count="28" type="stmt"/>
|
|
53
|
+
<line num="45" count="28" type="stmt"/>
|
|
54
|
+
<line num="46" count="28" type="stmt"/>
|
|
55
|
+
<line num="47" count="28" type="stmt"/>
|
|
56
|
+
<line num="48" count="28" type="stmt"/>
|
|
57
|
+
<line num="49" count="28" type="cond" truecount="1" falsecount="0"/>
|
|
58
|
+
<line num="50" count="28" type="stmt"/>
|
|
59
|
+
<line num="51" count="28" type="stmt"/>
|
|
60
|
+
<line num="52" count="28" type="stmt"/>
|
|
61
|
+
<line num="53" count="28" type="stmt"/>
|
|
62
|
+
<line num="54" count="14" type="stmt"/>
|
|
63
|
+
<line num="55" count="1" type="stmt"/>
|
|
64
|
+
<line num="56" count="1" type="cond" truecount="1" falsecount="0"/>
|
|
65
|
+
<line num="57" count="3" type="stmt"/>
|
|
66
|
+
<line num="58" count="3" type="stmt"/>
|
|
67
|
+
<line num="59" count="1" type="stmt"/>
|
|
68
|
+
<line num="60" count="1" type="cond" truecount="1" falsecount="0"/>
|
|
69
|
+
<line num="61" count="3" type="stmt"/>
|
|
70
|
+
<line num="62" count="3" type="stmt"/>
|
|
71
|
+
<line num="63" count="3" type="cond" truecount="1" falsecount="0"/>
|
|
72
|
+
<line num="64" count="1" type="stmt"/>
|
|
73
|
+
<line num="65" count="1" type="stmt"/>
|
|
74
|
+
<line num="66" count="1" type="stmt"/>
|
|
75
|
+
<line num="67" count="1" type="stmt"/>
|
|
76
|
+
<line num="68" count="1" type="stmt"/>
|
|
77
|
+
<line num="69" count="1" type="stmt"/>
|
|
78
|
+
<line num="70" count="2" type="cond" truecount="1" falsecount="0"/>
|
|
79
|
+
<line num="71" count="2" type="stmt"/>
|
|
80
|
+
<line num="72" count="2" type="stmt"/>
|
|
81
|
+
<line num="73" count="2" type="stmt"/>
|
|
82
|
+
<line num="74" count="2" type="stmt"/>
|
|
83
|
+
<line num="75" count="3" type="stmt"/>
|
|
84
|
+
<line num="76" count="3" type="stmt"/>
|
|
85
|
+
<line num="77" count="3" type="stmt"/>
|
|
86
|
+
<line num="78" count="3" type="stmt"/>
|
|
87
|
+
<line num="79" count="3" type="stmt"/>
|
|
88
|
+
<line num="80" count="3" type="cond" truecount="1" falsecount="0"/>
|
|
89
|
+
<line num="81" count="3" type="cond" truecount="1" falsecount="0"/>
|
|
90
|
+
<line num="82" count="1" type="stmt"/>
|
|
91
|
+
<line num="83" count="1" type="stmt"/>
|
|
92
|
+
<line num="84" count="1" type="stmt"/>
|
|
93
|
+
<line num="85" count="1" type="stmt"/>
|
|
94
|
+
<line num="86" count="1" type="stmt"/>
|
|
95
|
+
<line num="87" count="1" type="stmt"/>
|
|
96
|
+
<line num="88" count="3" type="cond" truecount="1" falsecount="1"/>
|
|
97
|
+
<line num="89" count="2" type="stmt"/>
|
|
98
|
+
<line num="90" count="2" type="stmt"/>
|
|
99
|
+
<line num="91" count="3" type="stmt"/>
|
|
100
|
+
<line num="92" count="1" type="stmt"/>
|
|
101
|
+
</file>
|
|
102
|
+
</package>
|
|
103
|
+
<package name="src.config">
|
|
104
|
+
<metrics statements="19" coveredstatements="19" conditionals="0" coveredconditionals="0" methods="0" coveredmethods="0"/>
|
|
105
|
+
<file name="config.ts" path="/Volumes/workspaces/tsed/ts-express-decorators/packages/third-parties/bullmq/src/config/config.ts">
|
|
106
|
+
<metrics statements="19" coveredstatements="19" conditionals="0" coveredconditionals="0" methods="0" coveredmethods="0"/>
|
|
107
|
+
<line num="1" count="1" type="stmt"/>
|
|
108
|
+
<line num="2" count="1" type="stmt"/>
|
|
109
|
+
<line num="3" count="1" type="stmt"/>
|
|
110
|
+
<line num="4" count="1" type="stmt"/>
|
|
111
|
+
<line num="5" count="1" type="stmt"/>
|
|
112
|
+
<line num="6" count="1" type="stmt"/>
|
|
113
|
+
<line num="7" count="1" type="stmt"/>
|
|
114
|
+
<line num="8" count="1" type="stmt"/>
|
|
115
|
+
<line num="9" count="1" type="stmt"/>
|
|
116
|
+
<line num="10" count="1" type="stmt"/>
|
|
117
|
+
<line num="11" count="1" type="stmt"/>
|
|
118
|
+
<line num="12" count="1" type="stmt"/>
|
|
119
|
+
<line num="13" count="1" type="stmt"/>
|
|
120
|
+
<line num="14" count="1" type="stmt"/>
|
|
121
|
+
<line num="15" count="1" type="stmt"/>
|
|
122
|
+
<line num="16" count="1" type="stmt"/>
|
|
123
|
+
<line num="17" count="1" type="stmt"/>
|
|
124
|
+
<line num="18" count="1" type="stmt"/>
|
|
125
|
+
<line num="19" count="1" type="stmt"/>
|
|
126
|
+
</file>
|
|
127
|
+
</package>
|
|
128
|
+
<package name="src.decorators">
|
|
129
|
+
<metrics statements="17" coveredstatements="17" conditionals="4" coveredconditionals="4" methods="2" coveredmethods="2"/>
|
|
130
|
+
<file name="Job.ts" path="/Volumes/workspaces/tsed/ts-express-decorators/packages/third-parties/bullmq/src/decorators/Job.ts">
|
|
131
|
+
<metrics statements="17" coveredstatements="17" conditionals="4" coveredconditionals="4" methods="2" coveredmethods="2"/>
|
|
132
|
+
<line num="1" count="1" type="stmt"/>
|
|
133
|
+
<line num="2" count="1" type="stmt"/>
|
|
134
|
+
<line num="3" count="1" type="stmt"/>
|
|
135
|
+
<line num="4" count="1" type="stmt"/>
|
|
136
|
+
<line num="5" count="1" type="cond" truecount="2" falsecount="0"/>
|
|
137
|
+
<line num="6" count="8" type="stmt"/>
|
|
138
|
+
<line num="7" count="8" type="stmt"/>
|
|
139
|
+
<line num="8" count="8" type="stmt"/>
|
|
140
|
+
<line num="9" count="8" type="stmt"/>
|
|
141
|
+
<line num="10" count="8" type="stmt"/>
|
|
142
|
+
<line num="11" count="8" type="stmt"/>
|
|
143
|
+
<line num="12" count="8" type="stmt"/>
|
|
144
|
+
<line num="13" count="8" type="stmt"/>
|
|
145
|
+
<line num="14" count="8" type="cond" truecount="2" falsecount="0"/>
|
|
146
|
+
<line num="15" count="8" type="stmt"/>
|
|
147
|
+
<line num="16" count="8" type="stmt"/>
|
|
148
|
+
<line num="17" count="8" type="stmt"/>
|
|
149
|
+
</file>
|
|
150
|
+
</package>
|
|
151
|
+
<package name="src.dispatchers">
|
|
152
|
+
<metrics statements="22" coveredstatements="22" conditionals="5" coveredconditionals="4" methods="3" coveredmethods="3"/>
|
|
153
|
+
<file name="JobDispatcher.ts" path="/Volumes/workspaces/tsed/ts-express-decorators/packages/third-parties/bullmq/src/dispatchers/JobDispatcher.ts">
|
|
154
|
+
<metrics statements="22" coveredstatements="22" conditionals="5" coveredconditionals="4" methods="3" coveredmethods="3"/>
|
|
155
|
+
<line num="1" count="1" type="stmt"/>
|
|
156
|
+
<line num="2" count="1" type="stmt"/>
|
|
157
|
+
<line num="3" count="1" type="stmt"/>
|
|
158
|
+
<line num="4" count="1" type="stmt"/>
|
|
159
|
+
<line num="5" count="1" type="stmt"/>
|
|
160
|
+
<line num="6" count="1" type="stmt"/>
|
|
161
|
+
<line num="7" count="1" type="cond" truecount="1" falsecount="0"/>
|
|
162
|
+
<line num="8" count="1" type="cond" truecount="1" falsecount="1"/>
|
|
163
|
+
<line num="9" count="1" type="stmt"/>
|
|
164
|
+
<line num="10" count="1" type="stmt"/>
|
|
165
|
+
<line num="11" count="1" type="cond" truecount="1" falsecount="0"/>
|
|
166
|
+
<line num="12" count="2" type="stmt"/>
|
|
167
|
+
<line num="13" count="2" type="stmt"/>
|
|
168
|
+
<line num="14" count="2" type="stmt"/>
|
|
169
|
+
<line num="15" count="2" type="stmt"/>
|
|
170
|
+
<line num="16" count="2" type="cond" truecount="1" falsecount="0"/>
|
|
171
|
+
<line num="17" count="1" type="stmt"/>
|
|
172
|
+
<line num="18" count="1" type="stmt"/>
|
|
173
|
+
<line num="19" count="1" type="stmt"/>
|
|
174
|
+
<line num="20" count="1" type="stmt"/>
|
|
175
|
+
<line num="21" count="1" type="stmt"/>
|
|
176
|
+
<line num="22" count="1" type="stmt"/>
|
|
177
|
+
</file>
|
|
178
|
+
</package>
|
|
179
|
+
</project>
|
|
180
|
+
</coverage>
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
{"/Volumes/workspaces/tsed/ts-express-decorators/packages/third-parties/bullmq/src/BullMQModule.ts": {"path":"/Volumes/workspaces/tsed/ts-express-decorators/packages/third-parties/bullmq/src/BullMQModule.ts","all":false,"statementMap":{"0":{"start":{"line":1,"column":0},"end":{"line":1,"column":65}},"1":{"start":{"line":2,"column":0},"end":{"line":2,"column":59}},"2":{"start":{"line":3,"column":0},"end":{"line":3,"column":45}},"3":{"start":{"line":4,"column":0},"end":{"line":4,"column":42}},"4":{"start":{"line":5,"column":0},"end":{"line":5,"column":24}},"5":{"start":{"line":6,"column":0},"end":{"line":6,"column":45}},"6":{"start":{"line":7,"column":0},"end":{"line":7,"column":39}},"7":{"start":{"line":8,"column":0},"end":{"line":8,"column":44}},"8":{"start":{"line":9,"column":0},"end":{"line":9,"column":0}},"9":{"start":{"line":10,"column":0},"end":{"line":10,"column":9}},"10":{"start":{"line":11,"column":0},"end":{"line":11,"column":49}},"11":{"start":{"line":12,"column":0},"end":{"line":12,"column":21}},"12":{"start":{"line":13,"column":0},"end":{"line":13,"column":40}},"13":{"start":{"line":14,"column":0},"end":{"line":14,"column":0}},"14":{"start":{"line":15,"column":0},"end":{"line":15,"column":104}},"15":{"start":{"line":16,"column":0},"end":{"line":16,"column":0}},"16":{"start":{"line":17,"column":0},"end":{"line":17,"column":17}},"17":{"start":{"line":18,"column":0},"end":{"line":18,"column":24}},"18":{"start":{"line":19,"column":0},"end":{"line":19,"column":23}},"19":{"start":{"line":20,"column":0},"end":{"line":20,"column":0}},"20":{"start":{"line":21,"column":0},"end":{"line":21,"column":114}},"21":{"start":{"line":22,"column":0},"end":{"line":22,"column":3}},"22":{"start":{"line":23,"column":0},"end":{"line":23,"column":0}},"23":{"start":{"line":24,"column":0},"end":{"line":24,"column":25}},"24":{"start":{"line":25,"column":0},"end":{"line":25,"column":43}},"25":{"start":{"line":26,"column":0},"end":{"line":26,"column":19}},"26":{"start":{"line":27,"column":0},"end":{"line":27,"column":39}},"27":{"start":{"line":28,"column":0},"end":{"line":28,"column":38}},"28":{"start":{"line":29,"column":0},"end":{"line":29,"column":47}},"29":{"start":{"line":30,"column":0},"end":{"line":30,"column":60}},"30":{"start":{"line":31,"column":0},"end":{"line":31,"column":13}},"31":{"start":{"line":32,"column":0},"end":{"line":32,"column":18}},"32":{"start":{"line":33,"column":0},"end":{"line":33,"column":48}},"33":{"start":{"line":34,"column":0},"end":{"line":34,"column":11}},"34":{"start":{"line":35,"column":0},"end":{"line":35,"column":10}},"35":{"start":{"line":36,"column":0},"end":{"line":36,"column":48}},"36":{"start":{"line":37,"column":0},"end":{"line":37,"column":7}},"37":{"start":{"line":38,"column":0},"end":{"line":38,"column":3}},"38":{"start":{"line":39,"column":0},"end":{"line":39,"column":0}},"39":{"start":{"line":40,"column":0},"end":{"line":40,"column":26}},"40":{"start":{"line":41,"column":0},"end":{"line":41,"column":73}},"41":{"start":{"line":42,"column":0},"end":{"line":42,"column":19}},"42":{"start":{"line":43,"column":0},"end":{"line":43,"column":40}},"43":{"start":{"line":44,"column":0},"end":{"line":44,"column":32}},"44":{"start":{"line":45,"column":0},"end":{"line":45,"column":66}},"45":{"start":{"line":46,"column":0},"end":{"line":46,"column":46}},"46":{"start":{"line":47,"column":0},"end":{"line":47,"column":13}},"47":{"start":{"line":48,"column":0},"end":{"line":48,"column":18}},"48":{"start":{"line":49,"column":0},"end":{"line":49,"column":50}},"49":{"start":{"line":50,"column":0},"end":{"line":50,"column":11}},"50":{"start":{"line":51,"column":0},"end":{"line":51,"column":10}},"51":{"start":{"line":52,"column":0},"end":{"line":52,"column":50}},"52":{"start":{"line":53,"column":0},"end":{"line":53,"column":7}},"53":{"start":{"line":54,"column":0},"end":{"line":54,"column":3}},"54":{"start":{"line":55,"column":0},"end":{"line":55,"column":0}},"55":{"start":{"line":56,"column":0},"end":{"line":56,"column":51}},"56":{"start":{"line":57,"column":0},"end":{"line":57,"column":64}},"57":{"start":{"line":58,"column":0},"end":{"line":58,"column":3}},"58":{"start":{"line":59,"column":0},"end":{"line":59,"column":0}},"59":{"start":{"line":60,"column":0},"end":{"line":60,"column":37}},"60":{"start":{"line":61,"column":0},"end":{"line":61,"column":60}},"61":{"start":{"line":62,"column":0},"end":{"line":62,"column":0}},"62":{"start":{"line":63,"column":0},"end":{"line":63,"column":22}},"63":{"start":{"line":64,"column":0},"end":{"line":64,"column":33}},"64":{"start":{"line":65,"column":0},"end":{"line":65,"column":38}},"65":{"start":{"line":66,"column":0},"end":{"line":66,"column":61}},"66":{"start":{"line":67,"column":0},"end":{"line":67,"column":9}},"67":{"start":{"line":68,"column":0},"end":{"line":68,"column":13}},"68":{"start":{"line":69,"column":0},"end":{"line":69,"column":5}},"69":{"start":{"line":70,"column":0},"end":{"line":70,"column":0}},"70":{"start":{"line":71,"column":0},"end":{"line":71,"column":32}},"71":{"start":{"line":72,"column":0},"end":{"line":72,"column":30}},"72":{"start":{"line":73,"column":0},"end":{"line":73,"column":35}},"73":{"start":{"line":74,"column":0},"end":{"line":74,"column":44}},"74":{"start":{"line":75,"column":0},"end":{"line":75,"column":7}},"75":{"start":{"line":76,"column":0},"end":{"line":76,"column":0}},"76":{"start":{"line":77,"column":0},"end":{"line":77,"column":32}},"77":{"start":{"line":78,"column":0},"end":{"line":78,"column":0}},"78":{"start":{"line":79,"column":0},"end":{"line":79,"column":9}},"79":{"start":{"line":80,"column":0},"end":{"line":80,"column":78}},"80":{"start":{"line":81,"column":0},"end":{"line":81,"column":18}},"81":{"start":{"line":82,"column":0},"end":{"line":82,"column":25}},"82":{"start":{"line":83,"column":0},"end":{"line":83,"column":34}},"83":{"start":{"line":84,"column":0},"end":{"line":84,"column":28}},"84":{"start":{"line":85,"column":0},"end":{"line":85,"column":23}},"85":{"start":{"line":86,"column":0},"end":{"line":86,"column":9}},"86":{"start":{"line":87,"column":0},"end":{"line":87,"column":15}},"87":{"start":{"line":88,"column":0},"end":{"line":88,"column":15}},"88":{"start":{"line":89,"column":0},"end":{"line":89,"column":27}},"89":{"start":{"line":90,"column":0},"end":{"line":90,"column":5}},"90":{"start":{"line":91,"column":0},"end":{"line":91,"column":3}},"91":{"start":{"line":92,"column":0},"end":{"line":92,"column":1}}},"s":{"0":1,"1":1,"2":1,"3":1,"4":1,"5":1,"6":1,"7":1,"8":1,"9":1,"10":1,"11":1,"12":1,"13":1,"14":1,"15":1,"16":1,"17":14,"18":14,"19":14,"20":14,"21":14,"22":1,"23":1,"24":14,"25":42,"26":42,"27":42,"28":42,"29":42,"30":42,"31":42,"32":42,"33":42,"34":42,"35":42,"36":42,"37":14,"38":1,"39":1,"40":14,"41":28,"42":28,"43":28,"44":28,"45":28,"46":28,"47":28,"48":28,"49":28,"50":28,"51":28,"52":28,"53":14,"54":1,"55":1,"56":3,"57":3,"58":1,"59":1,"60":3,"61":3,"62":3,"63":1,"64":1,"65":1,"66":1,"67":1,"68":1,"69":2,"70":2,"71":2,"72":2,"73":2,"74":3,"75":3,"76":3,"77":3,"78":3,"79":3,"80":3,"81":1,"82":1,"83":1,"84":1,"85":1,"86":1,"87":3,"88":2,"89":2,"90":3,"91":1},"branchMap":{"0":{"type":"branch","line":13,"loc":{"start":{"line":13,"column":39},"end":{"line":13,"column":38}},"locations":[{"start":{"line":13,"column":39},"end":{"line":13,"column":38}}]},"1":{"type":"branch","line":15,"loc":{"start":{"line":15,"column":56},"end":{"line":15,"column":75}},"locations":[{"start":{"line":15,"column":56},"end":{"line":15,"column":75}}]},"2":{"type":"branch","line":15,"loc":{"start":{"line":15,"column":100},"end":{"line":15,"column":102}},"locations":[{"start":{"line":15,"column":100},"end":{"line":15,"column":102}}]},"3":{"type":"branch","line":11,"loc":{"start":{"line":11,"column":13},"end":{"line":11,"column":49}},"locations":[{"start":{"line":11,"column":13},"end":{"line":11,"column":49}}]},"4":{"type":"branch","line":17,"loc":{"start":{"line":17,"column":2},"end":{"line":22,"column":3}},"locations":[{"start":{"line":17,"column":2},"end":{"line":22,"column":3}}]},"5":{"type":"branch","line":21,"loc":{"start":{"line":21,"column":57},"end":{"line":21,"column":114}},"locations":[{"start":{"line":21,"column":57},"end":{"line":21,"column":114}}]},"6":{"type":"branch","line":24,"loc":{"start":{"line":24,"column":10},"end":{"line":38,"column":3}},"locations":[{"start":{"line":24,"column":10},"end":{"line":38,"column":3}}]},"7":{"type":"branch","line":25,"loc":{"start":{"line":25,"column":31},"end":{"line":37,"column":7}},"locations":[{"start":{"line":25,"column":31},"end":{"line":37,"column":7}}]},"8":{"type":"branch","line":33,"loc":{"start":{"line":33,"column":24},"end":{"line":33,"column":48}},"locations":[{"start":{"line":33,"column":24},"end":{"line":33,"column":48}}]},"9":{"type":"branch","line":40,"loc":{"start":{"line":40,"column":10},"end":{"line":54,"column":3}},"locations":[{"start":{"line":40,"column":10},"end":{"line":54,"column":3}}]},"10":{"type":"branch","line":41,"loc":{"start":{"line":41,"column":29},"end":{"line":41,"column":51}},"locations":[{"start":{"line":41,"column":29},"end":{"line":41,"column":51}}]},"11":{"type":"branch","line":41,"loc":{"start":{"line":41,"column":61},"end":{"line":53,"column":7}},"locations":[{"start":{"line":41,"column":61},"end":{"line":53,"column":7}}]},"12":{"type":"branch","line":49,"loc":{"start":{"line":49,"column":24},"end":{"line":49,"column":50}},"locations":[{"start":{"line":49,"column":24},"end":{"line":49,"column":50}}]},"13":{"type":"branch","line":56,"loc":{"start":{"line":56,"column":10},"end":{"line":58,"column":3}},"locations":[{"start":{"line":56,"column":10},"end":{"line":58,"column":3}}]},"14":{"type":"branch","line":60,"loc":{"start":{"line":60,"column":2},"end":{"line":91,"column":3}},"locations":[{"start":{"line":60,"column":2},"end":{"line":91,"column":3}}]},"15":{"type":"branch","line":63,"loc":{"start":{"line":63,"column":21},"end":{"line":69,"column":5}},"locations":[{"start":{"line":63,"column":21},"end":{"line":69,"column":5}}]},"16":{"type":"branch","line":70,"loc":{"start":{"line":70,"column":-1},"end":{"line":74,"column":44}},"locations":[{"start":{"line":70,"column":-1},"end":{"line":74,"column":44}}]},"17":{"type":"branch","line":81,"loc":{"start":{"line":81,"column":6},"end":{"line":88,"column":14}},"locations":[{"start":{"line":81,"column":6},"end":{"line":88,"column":14}}]},"18":{"type":"branch","line":88,"loc":{"start":{"line":88,"column":4},"end":{"line":88,"column":14}},"locations":[{"start":{"line":88,"column":4},"end":{"line":88,"column":14}}]},"19":{"type":"branch","line":88,"loc":{"start":{"line":88,"column":4},"end":{"line":90,"column":5}},"locations":[{"start":{"line":88,"column":4},"end":{"line":90,"column":5}}]},"20":{"type":"branch","line":80,"loc":{"start":{"line":80,"column":38},"end":{"line":80,"column":78}},"locations":[{"start":{"line":80,"column":38},"end":{"line":80,"column":78}}]},"21":{"type":"branch","line":15,"loc":{"start":{"line":15,"column":2},"end":{"line":15,"column":104}},"locations":[{"start":{"line":15,"column":2},"end":{"line":15,"column":104}}]}},"b":{"0":[0],"1":[0],"2":[0],"3":[3],"4":[14],"5":[14],"6":[14],"7":[42],"8":[42],"9":[14],"10":[0],"11":[28],"12":[28],"13":[3],"14":[3],"15":[1],"16":[2],"17":[1],"18":[0],"19":[2],"20":[2],"21":[14]},"fnMap":{"0":{"name":"get","decl":{"start":{"line":11,"column":13},"end":{"line":11,"column":49}},"loc":{"start":{"line":11,"column":13},"end":{"line":11,"column":49}},"line":11},"1":{"name":"$beforeInit","decl":{"start":{"line":17,"column":2},"end":{"line":22,"column":3}},"loc":{"start":{"line":17,"column":2},"end":{"line":22,"column":3}},"line":17},"2":{"name":"buildQueues","decl":{"start":{"line":24,"column":10},"end":{"line":38,"column":3}},"loc":{"start":{"line":24,"column":10},"end":{"line":38,"column":3}},"line":24},"3":{"name":"$onDestroy","decl":{"start":{"line":33,"column":24},"end":{"line":33,"column":48}},"loc":{"start":{"line":33,"column":24},"end":{"line":33,"column":48}},"line":33},"4":{"name":"buildWorkers","decl":{"start":{"line":40,"column":10},"end":{"line":54,"column":3}},"loc":{"start":{"line":40,"column":10},"end":{"line":54,"column":3}},"line":40},"5":{"name":"$onDestroy","decl":{"start":{"line":49,"column":24},"end":{"line":49,"column":50}},"loc":{"start":{"line":49,"column":24},"end":{"line":49,"column":50}},"line":49},"6":{"name":"getJob","decl":{"start":{"line":56,"column":10},"end":{"line":58,"column":3}},"loc":{"start":{"line":56,"column":10},"end":{"line":58,"column":3}},"line":56},"7":{"name":"onProcess","decl":{"start":{"line":60,"column":2},"end":{"line":91,"column":3}},"loc":{"start":{"line":60,"column":2},"end":{"line":91,"column":3}},"line":60},"8":{"name":"BullMQModule","decl":{"start":{"line":15,"column":2},"end":{"line":15,"column":104}},"loc":{"start":{"line":15,"column":2},"end":{"line":15,"column":104}},"line":15}},"f":{"0":3,"1":14,"2":14,"3":42,"4":14,"5":28,"6":3,"7":3,"8":14}}
|
|
2
|
+
,"/Volumes/workspaces/tsed/ts-express-decorators/packages/third-parties/bullmq/src/config/config.ts": {"path":"/Volumes/workspaces/tsed/ts-express-decorators/packages/third-parties/bullmq/src/config/config.ts","all":false,"statementMap":{"0":{"start":{"line":1,"column":0},"end":{"line":1,"column":70}},"1":{"start":{"line":2,"column":0},"end":{"line":2,"column":0}},"2":{"start":{"line":3,"column":0},"end":{"line":3,"column":28}},"3":{"start":{"line":4,"column":0},"end":{"line":4,"column":19}},"4":{"start":{"line":5,"column":0},"end":{"line":5,"column":32}},"5":{"start":{"line":6,"column":0},"end":{"line":6,"column":40}},"6":{"start":{"line":7,"column":0},"end":{"line":7,"column":26}},"7":{"start":{"line":8,"column":0},"end":{"line":8,"column":62}},"8":{"start":{"line":9,"column":0},"end":{"line":9,"column":47}},"9":{"start":{"line":10,"column":0},"end":{"line":10,"column":26}},"10":{"start":{"line":11,"column":0},"end":{"line":11,"column":2}},"11":{"start":{"line":12,"column":0},"end":{"line":12,"column":0}},"12":{"start":{"line":13,"column":0},"end":{"line":13,"column":16}},"13":{"start":{"line":14,"column":0},"end":{"line":14,"column":18}},"14":{"start":{"line":15,"column":0},"end":{"line":15,"column":29}},"15":{"start":{"line":16,"column":0},"end":{"line":16,"column":28}},"16":{"start":{"line":17,"column":0},"end":{"line":17,"column":5}},"17":{"start":{"line":18,"column":0},"end":{"line":18,"column":3}},"18":{"start":{"line":19,"column":0},"end":{"line":19,"column":1}}},"s":{"0":1,"1":1,"2":1,"3":1,"4":1,"5":1,"6":1,"7":1,"8":1,"9":1,"10":1,"11":1,"12":1,"13":1,"14":1,"15":1,"16":1,"17":1,"18":1},"branchMap":{},"b":{},"fnMap":{},"f":{}}
|
|
3
|
+
,"/Volumes/workspaces/tsed/ts-express-decorators/packages/third-parties/bullmq/src/decorators/Job.ts": {"path":"/Volumes/workspaces/tsed/ts-express-decorators/packages/third-parties/bullmq/src/decorators/Job.ts","all":false,"statementMap":{"0":{"start":{"line":1,"column":0},"end":{"line":1,"column":53}},"1":{"start":{"line":2,"column":0},"end":{"line":2,"column":36}},"2":{"start":{"line":3,"column":0},"end":{"line":3,"column":35}},"3":{"start":{"line":4,"column":0},"end":{"line":4,"column":0}},"4":{"start":{"line":5,"column":0},"end":{"line":5,"column":86}},"5":{"start":{"line":6,"column":0},"end":{"line":6,"column":23}},"6":{"start":{"line":7,"column":0},"end":{"line":7,"column":26}},"7":{"start":{"line":8,"column":0},"end":{"line":8,"column":11}},"8":{"start":{"line":9,"column":0},"end":{"line":9,"column":12}},"9":{"start":{"line":10,"column":0},"end":{"line":10,"column":10}},"10":{"start":{"line":11,"column":0},"end":{"line":11,"column":7}},"11":{"start":{"line":12,"column":0},"end":{"line":12,"column":16}},"12":{"start":{"line":13,"column":0},"end":{"line":13,"column":45}},"13":{"start":{"line":14,"column":0},"end":{"line":14,"column":54}},"14":{"start":{"line":15,"column":0},"end":{"line":15,"column":6}},"15":{"start":{"line":16,"column":0},"end":{"line":16,"column":4}},"16":{"start":{"line":17,"column":0},"end":{"line":17,"column":1}}},"s":{"0":1,"1":1,"2":1,"3":1,"4":1,"5":8,"6":8,"7":8,"8":8,"9":8,"10":8,"11":8,"12":8,"13":8,"14":8,"15":8,"16":8},"branchMap":{"0":{"type":"branch","line":5,"loc":{"start":{"line":5,"column":16},"end":{"line":5,"column":20}},"locations":[{"start":{"line":5,"column":16},"end":{"line":5,"column":20}}]},"1":{"type":"branch","line":5,"loc":{"start":{"line":5,"column":7},"end":{"line":17,"column":1}},"locations":[{"start":{"line":5,"column":7},"end":{"line":17,"column":1}}]},"2":{"type":"branch","line":14,"loc":{"start":{"line":14,"column":23},"end":{"line":14,"column":42}},"locations":[{"start":{"line":14,"column":23},"end":{"line":14,"column":42}}]},"3":{"type":"branch","line":14,"loc":{"start":{"line":14,"column":26},"end":{"line":14,"column":54}},"locations":[{"start":{"line":14,"column":26},"end":{"line":14,"column":54}}]}},"b":{"0":[8],"1":[8],"2":[2],"3":[6]},"fnMap":{"0":{"name":"get","decl":{"start":{"line":5,"column":16},"end":{"line":5,"column":20}},"loc":{"start":{"line":5,"column":16},"end":{"line":5,"column":20}},"line":5},"1":{"name":"Job","decl":{"start":{"line":5,"column":7},"end":{"line":17,"column":1}},"loc":{"start":{"line":5,"column":7},"end":{"line":17,"column":1}},"line":5}},"f":{"0":8,"1":8}}
|
|
4
|
+
,"/Volumes/workspaces/tsed/ts-express-decorators/packages/third-parties/bullmq/src/dispatchers/JobDispatcher.ts": {"path":"/Volumes/workspaces/tsed/ts-express-decorators/packages/third-parties/bullmq/src/dispatchers/JobDispatcher.ts","all":false,"statementMap":{"0":{"start":{"line":1,"column":0},"end":{"line":1,"column":50}},"1":{"start":{"line":2,"column":0},"end":{"line":2,"column":55}},"2":{"start":{"line":3,"column":0},"end":{"line":3,"column":39}},"3":{"start":{"line":4,"column":0},"end":{"line":4,"column":47}},"4":{"start":{"line":5,"column":0},"end":{"line":5,"column":0}},"5":{"start":{"line":6,"column":0},"end":{"line":6,"column":10}},"6":{"start":{"line":7,"column":0},"end":{"line":7,"column":28}},"7":{"start":{"line":8,"column":0},"end":{"line":8,"column":60}},"8":{"start":{"line":9,"column":0},"end":{"line":9,"column":0}},"9":{"start":{"line":10,"column":0},"end":{"line":10,"column":43}},"10":{"start":{"line":11,"column":0},"end":{"line":11,"column":132}},"11":{"start":{"line":12,"column":0},"end":{"line":12,"column":58}},"12":{"start":{"line":13,"column":0},"end":{"line":13,"column":0}},"13":{"start":{"line":14,"column":0},"end":{"line":14,"column":74}},"14":{"start":{"line":15,"column":0},"end":{"line":15,"column":0}},"15":{"start":{"line":16,"column":0},"end":{"line":16,"column":17}},"16":{"start":{"line":17,"column":0},"end":{"line":17,"column":59}},"17":{"start":{"line":18,"column":0},"end":{"line":18,"column":5}},"18":{"start":{"line":19,"column":0},"end":{"line":19,"column":0}},"19":{"start":{"line":20,"column":0},"end":{"line":20,"column":54}},"20":{"start":{"line":21,"column":0},"end":{"line":21,"column":3}},"21":{"start":{"line":22,"column":0},"end":{"line":22,"column":1}}},"s":{"0":1,"1":1,"2":1,"3":1,"4":1,"5":1,"6":1,"7":1,"8":1,"9":1,"10":1,"11":2,"12":2,"13":2,"14":2,"15":2,"16":1,"17":1,"18":1,"19":1,"20":1,"21":1},"branchMap":{"0":{"type":"branch","line":8,"loc":{"start":{"line":8,"column":56},"end":{"line":8,"column":58}},"locations":[{"start":{"line":8,"column":56},"end":{"line":8,"column":58}}]},"1":{"type":"branch","line":7,"loc":{"start":{"line":7,"column":13},"end":{"line":7,"column":28}},"locations":[{"start":{"line":7,"column":13},"end":{"line":7,"column":28}}]},"2":{"type":"branch","line":11,"loc":{"start":{"line":11,"column":2},"end":{"line":21,"column":3}},"locations":[{"start":{"line":11,"column":2},"end":{"line":21,"column":3}}]},"3":{"type":"branch","line":16,"loc":{"start":{"line":16,"column":16},"end":{"line":21,"column":3}},"locations":[{"start":{"line":16,"column":16},"end":{"line":21,"column":3}}]},"4":{"type":"branch","line":8,"loc":{"start":{"line":8,"column":2},"end":{"line":8,"column":60}},"locations":[{"start":{"line":8,"column":2},"end":{"line":8,"column":60}}]}},"b":{"0":[0],"1":[32],"2":[2],"3":[1],"4":[2]},"fnMap":{"0":{"name":"get","decl":{"start":{"line":7,"column":13},"end":{"line":7,"column":28}},"loc":{"start":{"line":7,"column":13},"end":{"line":7,"column":28}},"line":7},"1":{"name":"dispatch","decl":{"start":{"line":11,"column":2},"end":{"line":21,"column":3}},"loc":{"start":{"line":11,"column":2},"end":{"line":21,"column":3}},"line":11},"2":{"name":"JobDispatcher","decl":{"start":{"line":8,"column":2},"end":{"line":8,"column":60}},"loc":{"start":{"line":8,"column":2},"end":{"line":8,"column":60}},"line":8}},"f":{"0":32,"1":2,"2":2}}
|
|
5
|
+
}
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
{"total": {"lines":{"total":150,"covered":150,"skipped":0,"pct":100},"statements":{"total":150,"covered":150,"skipped":0,"pct":100},"functions":{"total":14,"covered":14,"skipped":0,"pct":100},"branches":{"total":31,"covered":25,"skipped":0,"pct":80.64},"branchesTrue":{"total":0,"covered":0,"skipped":0,"pct":100}}
|
|
2
|
+
,"/Volumes/workspaces/tsed/ts-express-decorators/packages/third-parties/bullmq/src/BullMQModule.ts": {"lines":{"total":92,"covered":92,"skipped":0,"pct":100},"functions":{"total":9,"covered":9,"skipped":0,"pct":100},"statements":{"total":92,"covered":92,"skipped":0,"pct":100},"branches":{"total":22,"covered":17,"skipped":0,"pct":77.27}}
|
|
3
|
+
,"/Volumes/workspaces/tsed/ts-express-decorators/packages/third-parties/bullmq/src/config/config.ts": {"lines":{"total":19,"covered":19,"skipped":0,"pct":100},"functions":{"total":0,"covered":0,"skipped":0,"pct":100},"statements":{"total":19,"covered":19,"skipped":0,"pct":100},"branches":{"total":0,"covered":0,"skipped":0,"pct":100}}
|
|
4
|
+
,"/Volumes/workspaces/tsed/ts-express-decorators/packages/third-parties/bullmq/src/decorators/Job.ts": {"lines":{"total":17,"covered":17,"skipped":0,"pct":100},"functions":{"total":2,"covered":2,"skipped":0,"pct":100},"statements":{"total":17,"covered":17,"skipped":0,"pct":100},"branches":{"total":4,"covered":4,"skipped":0,"pct":100}}
|
|
5
|
+
,"/Volumes/workspaces/tsed/ts-express-decorators/packages/third-parties/bullmq/src/dispatchers/JobDispatcher.ts": {"lines":{"total":22,"covered":22,"skipped":0,"pct":100},"functions":{"total":3,"covered":3,"skipped":0,"pct":100},"statements":{"total":22,"covered":22,"skipped":0,"pct":100},"branches":{"total":5,"covered":4,"skipped":0,"pct":80}}
|
|
6
|
+
}
|
|
@@ -0,0 +1,136 @@
|
|
|
1
|
+
|
|
2
|
+
<!doctype html>
|
|
3
|
+
<html lang="en">
|
|
4
|
+
|
|
5
|
+
<head>
|
|
6
|
+
<title>Code coverage report for Job.ts</title>
|
|
7
|
+
<meta charset="utf-8" />
|
|
8
|
+
<link rel="stylesheet" href="prettify.css" />
|
|
9
|
+
<link rel="stylesheet" href="base.css" />
|
|
10
|
+
<link rel="shortcut icon" type="image/x-icon" href="favicon.png" />
|
|
11
|
+
<meta name="viewport" content="width=device-width, initial-scale=1" />
|
|
12
|
+
<style type='text/css'>
|
|
13
|
+
.coverage-summary .sorter {
|
|
14
|
+
background-image: url(sort-arrow-sprite.png);
|
|
15
|
+
}
|
|
16
|
+
</style>
|
|
17
|
+
</head>
|
|
18
|
+
|
|
19
|
+
<body>
|
|
20
|
+
<div class='wrapper'>
|
|
21
|
+
<div class='pad1'>
|
|
22
|
+
<h1><a href="index.html">All files</a> Job.ts</h1>
|
|
23
|
+
<div class='clearfix'>
|
|
24
|
+
|
|
25
|
+
<div class='fl pad1y space-right2'>
|
|
26
|
+
<span class="strong">100% </span>
|
|
27
|
+
<span class="quiet">Statements</span>
|
|
28
|
+
<span class='fraction'>17/17</span>
|
|
29
|
+
</div>
|
|
30
|
+
|
|
31
|
+
|
|
32
|
+
<div class='fl pad1y space-right2'>
|
|
33
|
+
<span class="strong">100% </span>
|
|
34
|
+
<span class="quiet">Branches</span>
|
|
35
|
+
<span class='fraction'>4/4</span>
|
|
36
|
+
</div>
|
|
37
|
+
|
|
38
|
+
|
|
39
|
+
<div class='fl pad1y space-right2'>
|
|
40
|
+
<span class="strong">100% </span>
|
|
41
|
+
<span class="quiet">Functions</span>
|
|
42
|
+
<span class='fraction'>2/2</span>
|
|
43
|
+
</div>
|
|
44
|
+
|
|
45
|
+
|
|
46
|
+
<div class='fl pad1y space-right2'>
|
|
47
|
+
<span class="strong">100% </span>
|
|
48
|
+
<span class="quiet">Lines</span>
|
|
49
|
+
<span class='fraction'>17/17</span>
|
|
50
|
+
</div>
|
|
51
|
+
|
|
52
|
+
|
|
53
|
+
</div>
|
|
54
|
+
<p class="quiet">
|
|
55
|
+
Press <em>n</em> or <em>j</em> to go to the next uncovered block, <em>b</em>, <em>p</em> or <em>k</em> for the previous block.
|
|
56
|
+
</p>
|
|
57
|
+
<template id="filterTemplate">
|
|
58
|
+
<div class="quiet">
|
|
59
|
+
Filter:
|
|
60
|
+
<input oninput="onInput()" type="search" id="fileSearch">
|
|
61
|
+
</div>
|
|
62
|
+
</template>
|
|
63
|
+
</div>
|
|
64
|
+
<div class='status-line high'></div>
|
|
65
|
+
<pre><table class="coverage">
|
|
66
|
+
<tr><td class="line-count quiet"><a name='L1'></a><a href='#L1'>1</a>
|
|
67
|
+
<a name='L2'></a><a href='#L2'>2</a>
|
|
68
|
+
<a name='L3'></a><a href='#L3'>3</a>
|
|
69
|
+
<a name='L4'></a><a href='#L4'>4</a>
|
|
70
|
+
<a name='L5'></a><a href='#L5'>5</a>
|
|
71
|
+
<a name='L6'></a><a href='#L6'>6</a>
|
|
72
|
+
<a name='L7'></a><a href='#L7'>7</a>
|
|
73
|
+
<a name='L8'></a><a href='#L8'>8</a>
|
|
74
|
+
<a name='L9'></a><a href='#L9'>9</a>
|
|
75
|
+
<a name='L10'></a><a href='#L10'>10</a>
|
|
76
|
+
<a name='L11'></a><a href='#L11'>11</a>
|
|
77
|
+
<a name='L12'></a><a href='#L12'>12</a>
|
|
78
|
+
<a name='L13'></a><a href='#L13'>13</a>
|
|
79
|
+
<a name='L14'></a><a href='#L14'>14</a>
|
|
80
|
+
<a name='L15'></a><a href='#L15'>15</a>
|
|
81
|
+
<a name='L16'></a><a href='#L16'>16</a>
|
|
82
|
+
<a name='L17'></a><a href='#L17'>17</a>
|
|
83
|
+
<a name='L18'></a><a href='#L18'>18</a></td><td class="line-coverage quiet"><span class="cline-any cline-yes">1x</span>
|
|
84
|
+
<span class="cline-any cline-yes">1x</span>
|
|
85
|
+
<span class="cline-any cline-yes">1x</span>
|
|
86
|
+
<span class="cline-any cline-yes">1x</span>
|
|
87
|
+
<span class="cline-any cline-yes">1x</span>
|
|
88
|
+
<span class="cline-any cline-yes">4x</span>
|
|
89
|
+
<span class="cline-any cline-yes">4x</span>
|
|
90
|
+
<span class="cline-any cline-yes">4x</span>
|
|
91
|
+
<span class="cline-any cline-yes">4x</span>
|
|
92
|
+
<span class="cline-any cline-yes">4x</span>
|
|
93
|
+
<span class="cline-any cline-yes">4x</span>
|
|
94
|
+
<span class="cline-any cline-yes">4x</span>
|
|
95
|
+
<span class="cline-any cline-yes">4x</span>
|
|
96
|
+
<span class="cline-any cline-yes">4x</span>
|
|
97
|
+
<span class="cline-any cline-yes">4x</span>
|
|
98
|
+
<span class="cline-any cline-yes">4x</span>
|
|
99
|
+
<span class="cline-any cline-yes">4x</span>
|
|
100
|
+
<span class="cline-any cline-neutral"> </span></td><td class="text"><pre class="prettyprint lang-js">import {StoreMerge, useDecorators} from "@tsed/core";
|
|
101
|
+
import {Injectable} from "@tsed/di";
|
|
102
|
+
import {JobsOptions} from "bullmq";
|
|
103
|
+
|
|
104
|
+
export function Job(name: string, queue: string = "default", opts: JobsOptions = {}) {
|
|
105
|
+
return useDecorators(
|
|
106
|
+
StoreMerge("bullmq", {
|
|
107
|
+
name,
|
|
108
|
+
queue,
|
|
109
|
+
opts
|
|
110
|
+
}),
|
|
111
|
+
Injectable({
|
|
112
|
+
provide: `bullmq.job.${queue}.${name}`,
|
|
113
|
+
type: opts.repeat ? "bullmq:cron" : "bullmq:job"
|
|
114
|
+
})
|
|
115
|
+
);
|
|
116
|
+
}
|
|
117
|
+
</pre></td></tr></table></pre>
|
|
118
|
+
|
|
119
|
+
<div class='push'></div><!-- for sticky footer -->
|
|
120
|
+
</div><!-- /wrapper -->
|
|
121
|
+
<div class='footer quiet pad2 space-top1 center small'>
|
|
122
|
+
Code coverage generated by
|
|
123
|
+
<a href="https://istanbul.js.org/" target="_blank" rel="noopener noreferrer">istanbul</a>
|
|
124
|
+
at Mon Oct 16 2023 08:33:03 GMT+0200 (Central European Summer Time)
|
|
125
|
+
</div>
|
|
126
|
+
<script src="prettify.js"></script>
|
|
127
|
+
<script>
|
|
128
|
+
window.onload = function () {
|
|
129
|
+
prettyPrint();
|
|
130
|
+
};
|
|
131
|
+
</script>
|
|
132
|
+
<script src="sorter.js"></script>
|
|
133
|
+
<script src="block-navigation.js"></script>
|
|
134
|
+
</body>
|
|
135
|
+
</html>
|
|
136
|
+
|