@toa.io/extensions.cadence 1.0.0-alpha.291 → 1.0.0-alpha.293
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/package.json +15 -6
- package/transpiled/Dispatcher.js +5 -2
- package/transpiled/Dispatcher.js.map +1 -1
- package/transpiled/Factory.js +1 -1
- package/transpiled/Factory.js.map +1 -1
- package/transpiled/index.d.ts +2 -5
- package/transpiled/index.js +2 -4
- package/transpiled/index.js.map +1 -1
- package/CHANGELOG.md +0 -37
- package/schemas/annotation.cos.yaml +0 -9
- package/schemas/declaration.cos.yaml +0 -20
- package/source/Aspect.ts +0 -73
- package/source/Composition.ts +0 -47
- package/source/Dispatcher.test.ts +0 -479
- package/source/Dispatcher.ts +0 -334
- package/source/Factory.ts +0 -76
- package/source/Local.ts +0 -40
- package/source/Pulse.test.ts +0 -303
- package/source/Pulse.ts +0 -211
- package/source/const.ts +0 -31
- package/source/context.ts +0 -10
- package/source/deployment.ts +0 -38
- package/source/index.ts +0 -8
- package/source/manifest.test.ts +0 -61
- package/source/manifest.ts +0 -64
- package/source/schemas.ts +0 -10
- package/source/types.ts +0 -41
- package/transpiled/const.d.ts +0 -21
- package/transpiled/const.js +0 -26
- package/transpiled/const.js.map +0 -1
- package/transpiled/context.d.ts +0 -3
- package/transpiled/context.js +0 -9
- package/transpiled/context.js.map +0 -1
- package/transpiled/deployment.d.ts +0 -9
- package/transpiled/deployment.js +0 -29
- package/transpiled/deployment.js.map +0 -1
- package/transpiled/manifest.d.ts +0 -11
- package/transpiled/manifest.js +0 -42
- package/transpiled/manifest.js.map +0 -1
- package/transpiled/schemas.d.ts +0 -4
- package/transpiled/schemas.js +0 -7
- package/transpiled/schemas.js.map +0 -1
- package/transpiled/types.d.ts +0 -34
- package/transpiled/types.js +0 -2
- package/transpiled/types.js.map +0 -1
- package/tsconfig.json +0 -13
- package/tsconfig.tsbuildinfo +0 -1
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@toa.io/extensions.cadence",
|
|
3
|
-
"version": "1.0.0-alpha.
|
|
3
|
+
"version": "1.0.0-alpha.293",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"description": "Toa Schedule",
|
|
6
6
|
"author": "temich <tema.gurtovoy@gmail.com>",
|
|
@@ -17,14 +17,23 @@
|
|
|
17
17
|
"publishConfig": {
|
|
18
18
|
"access": "public"
|
|
19
19
|
},
|
|
20
|
+
"files": [
|
|
21
|
+
"transpiled",
|
|
22
|
+
"components",
|
|
23
|
+
"readme.md",
|
|
24
|
+
"!**/tsconfig.tsbuildinfo",
|
|
25
|
+
"!**/*.test.*",
|
|
26
|
+
"!**/.env*"
|
|
27
|
+
],
|
|
20
28
|
"dependencies": {
|
|
21
|
-
"@toa.io/core": "1.0.0-alpha.
|
|
22
|
-
"@toa.io/
|
|
23
|
-
"@toa.io/
|
|
24
|
-
"
|
|
29
|
+
"@toa.io/core": "1.0.0-alpha.293",
|
|
30
|
+
"@toa.io/definitions": "1.0.0-alpha.293",
|
|
31
|
+
"@toa.io/generic": "1.0.0-alpha.292",
|
|
32
|
+
"@toa.io/schemas": "1.0.0-alpha.293",
|
|
33
|
+
"openspan": "1.0.0-alpha.293"
|
|
25
34
|
},
|
|
26
35
|
"scripts": {
|
|
27
36
|
"transpile": "tsc"
|
|
28
37
|
},
|
|
29
|
-
"gitHead": "
|
|
38
|
+
"gitHead": "1e05b3ab64758324c58c425f1f8e52e9f35f1da8"
|
|
30
39
|
}
|
package/transpiled/Dispatcher.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { console } from 'openspan';
|
|
2
2
|
import { Connector, Locator } from '@toa.io/core';
|
|
3
|
-
import { BATCH, DISCRETENESS, LANES, number } from '
|
|
3
|
+
import { BATCH, DISCRETENESS, LANES, number } from '@toa.io/definitions/extensions.cadence';
|
|
4
4
|
/**
|
|
5
5
|
* Makes the calls that were put off.
|
|
6
6
|
*
|
|
@@ -142,7 +142,10 @@ export class Dispatcher extends Connector {
|
|
|
142
142
|
// on a later pass already overdue. Where this is logged, the batch is too small for the rate
|
|
143
143
|
const truncated = rows.length === BATCH;
|
|
144
144
|
if (truncated)
|
|
145
|
-
console.warn('Delayed calls scan filled its batch', {
|
|
145
|
+
console.warn('Delayed calls scan filled its batch', {
|
|
146
|
+
limit: BATCH,
|
|
147
|
+
lanes: lanes.length
|
|
148
|
+
});
|
|
146
149
|
for (const row of rows)
|
|
147
150
|
this.arm(row);
|
|
148
151
|
if (!truncated)
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Dispatcher.js","sourceRoot":"","sources":["../source/Dispatcher.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,EAAE,MAAM,UAAU,CAAA;AAClC,OAAO,EAAE,SAAS,EAAE,OAAO,EAAE,MAAM,cAAc,CAAA;AACjD,OAAO,
|
|
1
|
+
{"version":3,"file":"Dispatcher.js","sourceRoot":"","sources":["../source/Dispatcher.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,EAAE,MAAM,UAAU,CAAA;AAClC,OAAO,EAAE,SAAS,EAAE,OAAO,EAAE,MAAM,cAAc,CAAA;AACjD,OAAO,EACL,KAAK,EACL,YAAY,EACZ,KAAK,EACL,MAAM,EACP,MAAM,wCAAwC,CAAA;AAI/C;;;;;;;;;;;GAWG;AACH,MAAM,OAAO,UAAW,SAAQ,SAAS;IACtB,SAAS,CAAO;IAChB,OAAO,CAA6B;IACpC,IAAI,CAAgB;IAErC,0FAA0F;IACzE,KAAK,GAAG,IAAI,GAAG,EAAiB,CAAA;IAEjD,qEAAqE;IAC7D,MAAM,GAAG,IAAI,GAAG,EAAU,CAAA;IAElC,oEAAoE;IACnD,OAAO,GAAG,IAAI,GAAG,EAAS,CAAA;IAE3C,sEAAsE;IACrD,YAAY,CAAQ;IAE7B,KAAK,CAAiB;IACtB,GAAG,CAAa;IAChB,QAAQ,GAAG,KAAK,CA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M,KAAK,GAAG,IAAI,CAAC,OAAO,CAAC,OAAO,CAAC,CAAA;QAEnC,IAAI,CAAC,IAAI,CAAC,OAAO,CAAC,GAAG,CAAC,KAAK,CAAC,EAAE,CAAC;YAC7B,IAAI,CAAC,OAAO,CAAC,GAAG,CAAC,KAAK,CAAC,CAAA;YACvB,IAAI,CAAC,OAAO,CAAC,KAAK,CAAC,CAAA;QACrB,CAAC;QAED,OAAO,KAAK,CAAA;IACd,CAAC;IAED,6FAA6F;IACrF,KAAK,CAAC,MAAM;QAClB,IAAI,IAAI,CAAC,MAAM,CAAC,IAAI,KAAK,CAAC;YAAE,OAAM;QAElC,MAAM,GAAG,GAAG,CAAC,GAAG,IAAI,CAAC,MAAM,CAAC,CAAA;QAE5B,MAAM,IAAI,CAAC,SAAS,CAAC,MAAM,CAAC,QAAQ,EAAE,EAAE,KAAK,EAAE,EAAE,GAAG,EAAE,EAAE,KAAK,EAAE,IAAI,EAAE,CAAC,CAAA;QAEtE,0FAA0F;QAC1F,KAAK,MAAM,EAAE,IAAI,GAAG;YAAE,IAAI,CAAC,MAAM,CAAC,MAAM,CAAC,EAAE,CAAC,CAAA;IAC9C,CAAC;CACF;AAmBD,oFAAoF;AACpF,MAAM,OAAO,GAAG,CAAC,CAAA"}
|
package/transpiled/Factory.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { Connector, Locator } from '@toa.io/core';
|
|
2
2
|
import { Composition } from './Composition.js';
|
|
3
|
-
import { COMPONENT, NAMESPACE } from '
|
|
3
|
+
import { COMPONENT, NAMESPACE } from '@toa.io/definitions/extensions.cadence';
|
|
4
4
|
import { Aspect } from './Aspect.js';
|
|
5
5
|
import { Dispatcher } from './Dispatcher.js';
|
|
6
6
|
import { Local } from './Local.js';
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Factory.js","sourceRoot":"","sources":["../source/Factory.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,OAAO,EAAE,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AO,CAAC,CAAA;QACjC,MAAM,IAAI,GAAG,IAAI,CAAC,IAAI,CAAC,IAAI,CAAC,OAAO,CAAC,EAAE,CAAC,CAAA;QAEvC,KAAK,MAAM,CAAC,QAAQ,EAAE,EAAE,KAAK,EAAE,SAAS,EAAE,CAAC,IAAI,MAAM,CAAC,OAAO,CAAC,MAAM,CAAC;YACnE,MAAM,CAAC,OAAO,CAAC,IAAI,KAAK,CAAC,EAAE,OAAO,EAAE,QAAQ,EAAE,KAAK,EAAE,SAAS,EAAE,EAAE,KAAK,EAAE,IAAI,CAAC,CAAC,CAAA;QAEjF,OAAO,MAAM,CAAA;IACf,CAAC;IAED,8EAA8E;IACvE,MAAM,CAAC,OAAgB;QAC5B,IAAI,IAAI,CAAC,OAAO,CAAC;YAAE,OAAO,EAAE,CAAA;QAE5B,OAAO,IAAI,MAAM,CAAC,IAAI,CAAC,SAAS,EAAE,CAAC,CAAA;IACrC,CAAC;IAEM,OAAO;QACZ,OAAO,IAAI,WAAW,CAAC,IAAI,CAAC,IAAI,CAAC,CAAA;IACnC,CAAC;IAEO,SAAS;QACf,OAAO,IAAI,CAAC,KAAK,CAAC,IAAI,OAAO,CAAC,SAAS,EAAE,SAAS,CAAC,CAAC,CAAA;IACtD,CAAC;IAEO,KAAK,CAAC,OAAgB;QAC5B,OAAO,CAAC,IAAI,CAAC,MAAM,CAAC,OAAO,CAAC,EAAE,CAAC,KAAK,IAAI,KAAK,CAAC,IAAI,CAAC,IAAI,EAAE,OAAO,CAAC,CAAC,CAAA;IACpE,CAAC;CACF;AAED,4FAA4F;AAC5F,SAAS,IAAI,CAAC,OAAgB;IAC5B,OAAO,OAAO,CAAC,SAAS,KAAK,SAAS,CAAA;AACxC,CAAC"}
|
package/transpiled/index.d.ts
CHANGED
|
@@ -1,7 +1,4 @@
|
|
|
1
1
|
export { Factory } from './Factory.js';
|
|
2
|
-
export { manifest } from './manifest.js';
|
|
3
2
|
export { components } from './Composition.js';
|
|
4
|
-
export {
|
|
5
|
-
export {
|
|
6
|
-
export { LANES } from './const.js';
|
|
7
|
-
export type { Declaration, Delay, Pulse } from './types.js';
|
|
3
|
+
export { LANES } from '@toa.io/definitions/extensions.cadence';
|
|
4
|
+
export type { Declaration, Delay, Pulse } from '@toa.io/definitions/extensions.cadence';
|
package/transpiled/index.js
CHANGED
|
@@ -1,7 +1,5 @@
|
|
|
1
1
|
export { Factory } from './Factory.js';
|
|
2
|
-
export { manifest } from './manifest.js';
|
|
3
2
|
export { components } from './Composition.js';
|
|
4
|
-
|
|
5
|
-
export {
|
|
6
|
-
export { LANES } from './const.js';
|
|
3
|
+
// what the metronome component is written against
|
|
4
|
+
export { LANES } from '@toa.io/definitions/extensions.cadence';
|
|
7
5
|
//# sourceMappingURL=index.js.map
|
package/transpiled/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../source/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,EAAE,MAAM,cAAc,CAAA;AACtC,OAAO,EAAE,
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../source/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,EAAE,MAAM,cAAc,CAAA;AACtC,OAAO,EAAE,UAAU,EAAE,MAAM,kBAAkB,CAAA;AAE7C,kDAAkD;AAClD,OAAO,EAAE,KAAK,EAAE,MAAM,wCAAwC,CAAA"}
|
package/CHANGELOG.md
DELETED
|
@@ -1,37 +0,0 @@
|
|
|
1
|
-
# Change Log
|
|
2
|
-
|
|
3
|
-
All notable changes to this project will be documented in this file.
|
|
4
|
-
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
|
|
5
|
-
|
|
6
|
-
# [1.0.0-alpha.291](https://github.com/toa-io/toa/compare/v1.0.0-alpha.290...v1.0.0-alpha.291) (2026-09-07)
|
|
7
|
-
|
|
8
|
-
**Note:** Version bump only for package @toa.io/extensions.cadence
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
# [1.0.0-alpha.289](https://github.com/toa-io/toa/compare/v1.0.0-alpha.288...v1.0.0-alpha.289) (2026-09-07)
|
|
15
|
-
|
|
16
|
-
* A deploy moves only what changed, and a component sees none of the runtime's environment (#1073) ([f38e3db](https://github.com/toa-io/toa/commit/f38e3db533f24db866c57bfa1ef294eff1eaf499)), closes [#1073](https://github.com/toa-io/toa/issues/1073) [#1064](https://github.com/toa-io/toa/issues/1064) [#1066](https://github.com/toa-io/toa/issues/1066) [#1067](https://github.com/toa-io/toa/issues/1067) [#1068](https://github.com/toa-io/toa/issues/1068) [#1069](https://github.com/toa-io/toa/issues/1069) [#1071](https://github.com/toa-io/toa/issues/1071) [#1070](https://github.com/toa-io/toa/issues/1070) [#1072](https://github.com/toa-io/toa/issues/1072)
|
|
17
|
-
|
|
18
|
-
### BREAKING CHANGES
|
|
19
|
-
|
|
20
|
-
* a component that read `process.env.TOA_*` reads `context` instead;
|
|
21
|
-
`echo(input)` no longer substitutes from the environment; a bash operation sees no
|
|
22
|
-
`TOA_*`; images no longer set `USER node` — see migrations/289.md.
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
# [1.0.0-alpha.288](https://github.com/toa-io/toa/compare/v1.0.0-alpha.287...v1.0.0-alpha.288) (2026-09-06)
|
|
26
|
-
|
|
27
|
-
**Note:** Version bump only for package @toa.io/extensions.cadence
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
# [1.0.0-alpha.287](https://github.com/toa-io/toa/compare/v1.0.0-alpha.286...v1.0.0-alpha.287) (2026-09-06)
|
|
34
|
-
|
|
35
|
-
### Bug Fixes
|
|
36
|
-
|
|
37
|
-
* **cadence:** the scan reads what is owed, and nothing that is done ([581610e](https://github.com/toa-io/toa/commit/581610e87ac54c42491c882d5749ff3307700d35))
|
|
@@ -1,20 +0,0 @@
|
|
|
1
|
-
# manifest.toa.yaml cadence declaration: the operations called on a cadence
|
|
2
|
-
type: object
|
|
3
|
-
propertyNames:
|
|
4
|
-
pattern: ^[a-zA-Z]+([_a-zA-Z0-9]*[a-zA-Z0-9]+)?$
|
|
5
|
-
patternProperties:
|
|
6
|
-
".*":
|
|
7
|
-
type: object
|
|
8
|
-
properties:
|
|
9
|
-
cycle:
|
|
10
|
-
description: Seconds one whole cycle takes
|
|
11
|
-
type: integer
|
|
12
|
-
minimum: 1
|
|
13
|
-
intervals:
|
|
14
|
-
description: >
|
|
15
|
-
Intervals the cycle is split into. The gap between calls is `cycle / intervals`,
|
|
16
|
-
and the operation is told which interval it is running for.
|
|
17
|
-
type: integer
|
|
18
|
-
minimum: 1
|
|
19
|
-
required: [cycle]
|
|
20
|
-
additionalProperties: false
|
package/source/Aspect.ts
DELETED
|
@@ -1,73 +0,0 @@
|
|
|
1
|
-
import { Connector } from '@toa.io/core'
|
|
2
|
-
import type { Local } from './Local.js'
|
|
3
|
-
import type { Options } from './types.js'
|
|
4
|
-
|
|
5
|
-
interface Input {
|
|
6
|
-
endpoint: string
|
|
7
|
-
interval: number
|
|
8
|
-
overdue: number | null
|
|
9
|
-
request?: object
|
|
10
|
-
}
|
|
11
|
-
|
|
12
|
-
/**
|
|
13
|
-
* `context.delay(endpoint, request, delay)` — a call to be made later, handed to the component
|
|
14
|
-
* that keeps them.
|
|
15
|
-
*
|
|
16
|
-
* It is not transactional with the caller's state. A crash between committing a change and
|
|
17
|
-
* handing over the call it should have scheduled loses the call, and there is no way for this
|
|
18
|
-
* to know. Where the semantics allow it, hand the call over first.
|
|
19
|
-
*
|
|
20
|
-
*/
|
|
21
|
-
export class Aspect extends Connector {
|
|
22
|
-
public readonly name = 'delay'
|
|
23
|
-
|
|
24
|
-
private readonly metronome: Local
|
|
25
|
-
|
|
26
|
-
public constructor(metronome: Local) {
|
|
27
|
-
super()
|
|
28
|
-
|
|
29
|
-
this.metronome = metronome
|
|
30
|
-
|
|
31
|
-
this.depends(metronome)
|
|
32
|
-
}
|
|
33
|
-
|
|
34
|
-
// named rather than forwarded, so that the connector's lifecycle is not reachable from an
|
|
35
|
-
// algorithm — the same reason the atom aspect names its own
|
|
36
|
-
public async invoke(method: string, ...args: any[]): Promise<unknown> {
|
|
37
|
-
switch (method) {
|
|
38
|
-
case 'delay':
|
|
39
|
-
return await this.delay(args[0], args[1], args[2])
|
|
40
|
-
case 'cancel':
|
|
41
|
-
return await this.cancel(args[0])
|
|
42
|
-
default:
|
|
43
|
-
throw new Error(`Delay aspect has no '${method}' method`)
|
|
44
|
-
}
|
|
45
|
-
}
|
|
46
|
-
|
|
47
|
-
/** Answers the id the call was given, which is what cancels it. */
|
|
48
|
-
private async delay(
|
|
49
|
-
endpoint: string,
|
|
50
|
-
request: object | null,
|
|
51
|
-
options: Options
|
|
52
|
-
): Promise<unknown> {
|
|
53
|
-
const input: Input = {
|
|
54
|
-
endpoint,
|
|
55
|
-
interval: options.interval,
|
|
56
|
-
overdue: options.overdue
|
|
57
|
-
}
|
|
58
|
-
|
|
59
|
-
// a call that takes no request carries none, rather than a null one
|
|
60
|
-
if (request !== null && request !== undefined) input.request = request
|
|
61
|
-
|
|
62
|
-
return await this.metronome.invoke('delay', { input })
|
|
63
|
-
}
|
|
64
|
-
|
|
65
|
-
/**
|
|
66
|
-
* Tombstones the row, which is the prototype's `terminate`. An id that was never issued has
|
|
67
|
-
* nothing to terminate and raises; one whose call has already been made has a row still, and
|
|
68
|
-
* terminating it again is not an error.
|
|
69
|
-
*/
|
|
70
|
-
private async cancel(id: string): Promise<unknown> {
|
|
71
|
-
return await this.metronome.invoke('terminate', { query: { id }, input: null })
|
|
72
|
-
}
|
|
73
|
-
}
|
package/source/Composition.ts
DELETED
|
@@ -1,47 +0,0 @@
|
|
|
1
|
-
import { readdirSync } from 'node:fs'
|
|
2
|
-
import { resolve } from 'node:path'
|
|
3
|
-
import { Connector } from '@toa.io/core'
|
|
4
|
-
import type { Dirent } from 'node:fs'
|
|
5
|
-
import type { Host } from './Factory.js'
|
|
6
|
-
|
|
7
|
-
/** The components this extension ships, which run inside its own service. */
|
|
8
|
-
export function components(): Components {
|
|
9
|
-
const labels: string[] = []
|
|
10
|
-
const paths: string[] = []
|
|
11
|
-
|
|
12
|
-
for (const entry of entries()) {
|
|
13
|
-
labels.push(entry.name.replace('.', '-'))
|
|
14
|
-
paths.push(resolve(ROOT, entry.name))
|
|
15
|
-
}
|
|
16
|
-
|
|
17
|
-
return { labels, paths }
|
|
18
|
-
}
|
|
19
|
-
|
|
20
|
-
export class Composition extends Connector {
|
|
21
|
-
private readonly host: Host
|
|
22
|
-
|
|
23
|
-
public constructor(host: Host) {
|
|
24
|
-
super()
|
|
25
|
-
|
|
26
|
-
this.host = host
|
|
27
|
-
}
|
|
28
|
-
|
|
29
|
-
protected override async open(): Promise<void> {
|
|
30
|
-
const composition = await this.host.composition(components().paths)
|
|
31
|
-
|
|
32
|
-
await composition.connect()
|
|
33
|
-
|
|
34
|
-
this.depends(composition)
|
|
35
|
-
}
|
|
36
|
-
}
|
|
37
|
-
|
|
38
|
-
function entries(): Dirent[] {
|
|
39
|
-
return readdirSync(ROOT, { withFileTypes: true }).filter((entry) => entry.isDirectory())
|
|
40
|
-
}
|
|
41
|
-
|
|
42
|
-
interface Components {
|
|
43
|
-
labels: string[]
|
|
44
|
-
paths: string[]
|
|
45
|
-
}
|
|
46
|
-
|
|
47
|
-
const ROOT = resolve(import.meta.dirname, '../components/')
|