@kubun/plugin-workflow 0.16.0 → 0.17.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/lib/engine.js +3 -1
- package/package.json +13 -13
package/lib/engine.js
CHANGED
|
@@ -27,7 +27,9 @@ const INTERVAL_UNITS = {
|
|
|
27
27
|
export function parseEvery(spec) {
|
|
28
28
|
const match = /^(\d+)(ms|s|m|h)?$/.exec(spec.trim());
|
|
29
29
|
if (match == null) throw new Error(`Invalid interval "${spec}"`);
|
|
30
|
-
|
|
30
|
+
const unit = match[2];
|
|
31
|
+
const multiplier = unit != null ? INTERVAL_UNITS[unit] ?? 1 : 1;
|
|
32
|
+
return Number(match[1]) * multiplier;
|
|
31
33
|
}
|
|
32
34
|
const TERMINAL = new Set([
|
|
33
35
|
'completed',
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@kubun/plugin-workflow",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.17.0",
|
|
4
4
|
"keywords": [],
|
|
5
5
|
"license": "see LICENSE.md",
|
|
6
6
|
"sideEffects": false,
|
|
@@ -15,22 +15,22 @@
|
|
|
15
15
|
"LICENSE.md"
|
|
16
16
|
],
|
|
17
17
|
"dependencies": {
|
|
18
|
-
"@kubun/db": "^0.
|
|
19
|
-
"@kubun/engine": "^0.
|
|
20
|
-
"@kubun/graphql": "^0.
|
|
21
|
-
"@kubun/id": "^0.
|
|
22
|
-
"@kubun/logger": "^0.
|
|
23
|
-
"@kubun/plugin-p2p-api": "^0.
|
|
24
|
-
"@kubun/plugin-workflow-api": "^0.
|
|
25
|
-
"@kubun/store-workflow": "^0.
|
|
18
|
+
"@kubun/db": "^0.17.0",
|
|
19
|
+
"@kubun/engine": "^0.17.0",
|
|
20
|
+
"@kubun/graphql": "^0.17.0",
|
|
21
|
+
"@kubun/id": "^0.17.0",
|
|
22
|
+
"@kubun/logger": "^0.17.0",
|
|
23
|
+
"@kubun/plugin-p2p-api": "^0.17.0",
|
|
24
|
+
"@kubun/plugin-workflow-api": "^0.17.0",
|
|
25
|
+
"@kubun/store-workflow": "^0.17.0",
|
|
26
26
|
"@sozai/event": "^0.1.3",
|
|
27
27
|
"@sozai/flow": "^0.3.1",
|
|
28
28
|
"@sozai/runtime": "^0.1.0",
|
|
29
29
|
"@sozai/schema": "^0.1.2"
|
|
30
30
|
},
|
|
31
31
|
"devDependencies": {
|
|
32
|
-
"@kubun/db-better-sqlite": "^0.
|
|
33
|
-
"@kubun/db-postgres": "^0.
|
|
32
|
+
"@kubun/db-better-sqlite": "^0.17.0",
|
|
33
|
+
"@kubun/db-postgres": "^0.17.0",
|
|
34
34
|
"@testcontainers/postgresql": "^12.1.0"
|
|
35
35
|
},
|
|
36
36
|
"publishConfig": {
|
|
@@ -39,8 +39,8 @@
|
|
|
39
39
|
"scripts": {
|
|
40
40
|
"build": "pnpm run build:clean && pnpm run build:js && pnpm run build:types",
|
|
41
41
|
"build:clean": "del lib",
|
|
42
|
-
"build:js": "swc src -d ./lib --config-file ../../node_modules/@kigu/dev/swc.json --strip-leading-paths",
|
|
43
|
-
"build:types": "tsc --emitDeclarationOnly --skipLibCheck",
|
|
42
|
+
"build:js": "del 'lib/**/*.js' && swc src -d ./lib --config-file ../../node_modules/@kigu/dev/swc.json --strip-leading-paths",
|
|
43
|
+
"build:types": "del 'lib/**/*.d.ts' 'lib/**/*.d.ts.map' && tsc --emitDeclarationOnly --skipLibCheck",
|
|
44
44
|
"build:types:ci": "tsc --emitDeclarationOnly --declarationMap false",
|
|
45
45
|
"test": "pnpm run test:types && pnpm run test:unit",
|
|
46
46
|
"test:types": "tsc --noEmit -p tsconfig.test.json",
|