@hotmeshio/hotmesh 0.0.52 → 0.0.53
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/README.md +22 -18
- package/build/index.d.ts +1 -2
- package/build/index.js +1 -3
- package/build/modules/enums.d.ts +8 -3
- package/build/modules/enums.js +16 -8
- package/build/modules/errors.d.ts +98 -18
- package/build/modules/errors.js +90 -33
- package/build/package.json +7 -2
- package/build/services/activities/activity.d.ts +8 -0
- package/build/services/activities/activity.js +63 -14
- package/build/services/activities/await.js +6 -6
- package/build/services/activities/cycle.d.ts +2 -2
- package/build/services/activities/cycle.js +5 -5
- package/build/services/activities/hook.js +4 -4
- package/build/services/activities/interrupt.d.ts +3 -3
- package/build/services/activities/interrupt.js +15 -6
- package/build/services/activities/signal.d.ts +2 -2
- package/build/services/activities/signal.js +4 -4
- package/build/services/activities/trigger.js +12 -3
- package/build/services/activities/worker.js +6 -6
- package/build/services/compiler/deployer.js +33 -5
- package/build/services/compiler/validator.d.ts +2 -0
- package/build/services/compiler/validator.js +5 -1
- package/build/services/durable/client.d.ts +7 -1
- package/build/services/durable/client.js +56 -30
- package/build/services/durable/exporter.d.ts +7 -72
- package/build/services/durable/exporter.js +105 -295
- package/build/services/durable/handle.d.ts +11 -6
- package/build/services/durable/handle.js +59 -46
- package/build/services/durable/index.d.ts +0 -2
- package/build/services/durable/index.js +0 -2
- package/build/services/durable/schemas/factory.d.ts +33 -0
- package/build/services/durable/schemas/factory.js +2356 -0
- package/build/services/durable/search.js +8 -8
- package/build/services/durable/worker.js +117 -25
- package/build/services/durable/workflow.d.ts +46 -43
- package/build/services/durable/workflow.js +273 -277
- package/build/services/engine/index.js +3 -0
- package/build/services/exporter/index.d.ts +2 -4
- package/build/services/exporter/index.js +4 -5
- package/build/services/mapper/index.d.ts +6 -2
- package/build/services/mapper/index.js +6 -2
- package/build/services/pipe/functions/array.d.ts +2 -10
- package/build/services/pipe/functions/array.js +30 -28
- package/build/services/pipe/functions/conditional.d.ts +1 -0
- package/build/services/pipe/functions/conditional.js +3 -0
- package/build/services/pipe/functions/date.d.ts +1 -0
- package/build/services/pipe/functions/date.js +4 -0
- package/build/services/pipe/functions/index.d.ts +2 -0
- package/build/services/pipe/functions/index.js +2 -0
- package/build/services/pipe/functions/logical.d.ts +5 -0
- package/build/services/pipe/functions/logical.js +12 -0
- package/build/services/pipe/functions/object.d.ts +3 -0
- package/build/services/pipe/functions/object.js +25 -7
- package/build/services/pipe/index.d.ts +20 -3
- package/build/services/pipe/index.js +82 -16
- package/build/services/router/index.js +14 -3
- package/build/services/serializer/index.d.ts +3 -2
- package/build/services/serializer/index.js +11 -4
- package/build/services/store/clients/ioredis.js +6 -6
- package/build/services/store/clients/redis.js +7 -7
- package/build/services/store/index.d.ts +2 -0
- package/build/services/store/index.js +4 -1
- package/build/services/stream/clients/ioredis.js +8 -8
- package/build/services/stream/clients/redis.js +1 -1
- package/build/types/activity.d.ts +60 -5
- package/build/types/durable.d.ts +168 -33
- package/build/types/exporter.d.ts +26 -4
- package/build/types/index.d.ts +2 -2
- package/build/types/job.d.ts +69 -5
- package/build/types/pipe.d.ts +81 -3
- package/build/types/stream.d.ts +61 -1
- package/build/types/stream.js +4 -0
- package/index.ts +1 -2
- package/modules/enums.ts +16 -8
- package/modules/errors.ts +174 -32
- package/package.json +7 -2
- package/services/activities/activity.ts +63 -14
- package/services/activities/await.ts +6 -6
- package/services/activities/cycle.ts +7 -6
- package/services/activities/hook.ts +4 -4
- package/services/activities/interrupt.ts +19 -9
- package/services/activities/signal.ts +6 -5
- package/services/activities/trigger.ts +16 -4
- package/services/activities/worker.ts +7 -7
- package/services/compiler/deployer.ts +33 -6
- package/services/compiler/validator.ts +7 -3
- package/services/durable/client.ts +47 -14
- package/services/durable/exporter.ts +110 -318
- package/services/durable/handle.ts +63 -50
- package/services/durable/index.ts +0 -2
- package/services/durable/schemas/factory.ts +2358 -0
- package/services/durable/search.ts +8 -8
- package/services/durable/worker.ts +128 -29
- package/services/durable/workflow.ts +304 -288
- package/services/engine/index.ts +4 -0
- package/services/exporter/index.ts +10 -12
- package/services/mapper/index.ts +6 -2
- package/services/pipe/functions/array.ts +24 -37
- package/services/pipe/functions/conditional.ts +4 -0
- package/services/pipe/functions/date.ts +6 -0
- package/services/pipe/functions/index.ts +7 -5
- package/services/pipe/functions/logical.ts +11 -0
- package/services/pipe/functions/object.ts +26 -7
- package/services/pipe/index.ts +99 -21
- package/services/quorum/index.ts +1 -3
- package/services/router/index.ts +14 -3
- package/services/serializer/index.ts +12 -5
- package/services/store/clients/ioredis.ts +6 -6
- package/services/store/clients/redis.ts +7 -7
- package/services/store/index.ts +4 -1
- package/services/stream/clients/ioredis.ts +8 -8
- package/services/stream/clients/redis.ts +1 -1
- package/types/activity.ts +87 -15
- package/types/durable.ts +246 -73
- package/types/exporter.ts +31 -5
- package/types/index.ts +6 -7
- package/types/job.ts +130 -36
- package/types/pipe.ts +84 -3
- package/types/stream.ts +82 -23
- package/build/services/durable/factory.d.ts +0 -17
- package/build/services/durable/factory.js +0 -817
- package/build/services/durable/meshos.d.ts +0 -127
- package/build/services/durable/meshos.js +0 -380
- package/services/durable/factory.ts +0 -818
- package/services/durable/meshos.ts +0 -441
package/types/durable.ts
CHANGED
|
@@ -1,16 +1,53 @@
|
|
|
1
1
|
import { LogLevel } from './logger';
|
|
2
2
|
import { RedisClass, RedisOptions } from './redis';
|
|
3
3
|
import { StringStringType } from './serializer';
|
|
4
|
+
import { StreamData, StreamError } from './stream';
|
|
4
5
|
|
|
6
|
+
/**
|
|
7
|
+
* Type definition for workflow configuration.
|
|
8
|
+
*/
|
|
5
9
|
type WorkflowConfig = {
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
+
/**
|
|
11
|
+
* Backoff coefficient for retry mechanism.
|
|
12
|
+
* @default 10 (HMSH_DURABLE_EXP_BACKOFF)
|
|
13
|
+
*/
|
|
14
|
+
backoffCoefficient?: number;
|
|
15
|
+
|
|
16
|
+
/**
|
|
17
|
+
* Maximum number of attempts for retries.
|
|
18
|
+
* @default 5 (HMSH_DURABLE_MAX_ATTEMPTS)
|
|
19
|
+
*/
|
|
20
|
+
maximumAttempts?: number;
|
|
21
|
+
|
|
22
|
+
/**
|
|
23
|
+
* Maximum interval between retries.
|
|
24
|
+
* @default 120s (HMSH_DURABLE_MAX_INTERVAL)
|
|
25
|
+
*/
|
|
26
|
+
maximumInterval?: string;
|
|
27
|
+
|
|
28
|
+
/**
|
|
29
|
+
* Whether to throw an error on final failure after retries are exhausted
|
|
30
|
+
* or return the error object as a standard response containing error-related
|
|
31
|
+
* fields like `stack`, `code`, `message`.
|
|
32
|
+
* @default true
|
|
33
|
+
*/
|
|
34
|
+
throwOnError?: boolean;
|
|
10
35
|
}
|
|
11
36
|
|
|
12
37
|
type WorkflowContext = {
|
|
13
38
|
|
|
39
|
+
/**
|
|
40
|
+
* can the workflow be retried if an error occurs
|
|
41
|
+
*/
|
|
42
|
+
canRetry: boolean;
|
|
43
|
+
|
|
44
|
+
COUNTER: {
|
|
45
|
+
/**
|
|
46
|
+
* the reentrant semaphore parent counter object for object reference during increment
|
|
47
|
+
*/
|
|
48
|
+
counter: number;
|
|
49
|
+
}
|
|
50
|
+
|
|
14
51
|
/**
|
|
15
52
|
* the reentrant semaphore, incremented in real-time as idempotent statements are re-traversed upon reentry. Indicates the current semaphore count.
|
|
16
53
|
*/
|
|
@@ -55,47 +92,160 @@ type WorkflowContext = {
|
|
|
55
92
|
* the open telemetry span context for the workflow, used for logging and tracing. If a sink is enabled, this will be sent to the sink.
|
|
56
93
|
*/
|
|
57
94
|
workflowSpan: string;
|
|
95
|
+
|
|
96
|
+
/**
|
|
97
|
+
* the native HotMesh message that encapsulates the arguments, metadata, and raw data for the workflow
|
|
98
|
+
*/
|
|
99
|
+
raw: StreamData;
|
|
58
100
|
}
|
|
59
101
|
|
|
60
102
|
type WorkflowSearchOptions = {
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
103
|
+
/** FT index name (myapp:myindex) */
|
|
104
|
+
index?: string;
|
|
105
|
+
|
|
106
|
+
/** FT prefixes (['myapp:myindex:prefix1', 'myapp:myindex:prefix2']) */
|
|
107
|
+
prefix?: string[];
|
|
108
|
+
|
|
109
|
+
/**
|
|
110
|
+
* Schema mapping each field to a type with an optional sortable flag
|
|
111
|
+
*/
|
|
112
|
+
schema?: Record<string, { type: 'TEXT' | 'NUMERIC' | 'TAG', sortable?: boolean }>;
|
|
113
|
+
|
|
114
|
+
/** Additional data as a key-value record */
|
|
64
115
|
data?: Record<string, string>;
|
|
65
116
|
}
|
|
66
117
|
|
|
118
|
+
|
|
67
119
|
type WorkflowOptions = {
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
120
|
+
|
|
121
|
+
/**
|
|
122
|
+
* the namespace for the workflow; `durable` is the default namespace if not provided
|
|
123
|
+
*/
|
|
124
|
+
namespace?: string;
|
|
125
|
+
|
|
126
|
+
/**
|
|
127
|
+
* the task queue for the workflow; optional if entity is provided
|
|
128
|
+
*/
|
|
129
|
+
taskQueue?: string;
|
|
130
|
+
|
|
131
|
+
/**
|
|
132
|
+
* input arguments to pass in
|
|
133
|
+
*/
|
|
134
|
+
args: any[];
|
|
135
|
+
|
|
136
|
+
/**
|
|
137
|
+
* the job id
|
|
138
|
+
*/
|
|
139
|
+
workflowId?: string;
|
|
140
|
+
|
|
141
|
+
/**
|
|
142
|
+
* if invoking a workflow, passing 'entity' will apply the value as the workflowName, taskQueue, and prefix, ensuring the FT.SEARCH index is properly scoped. This is a convenience method but limits options.
|
|
143
|
+
*/
|
|
144
|
+
entity?: string;
|
|
145
|
+
|
|
146
|
+
/**
|
|
147
|
+
* the name of the user's workflow function; optional if 'entity' is provided
|
|
148
|
+
*/
|
|
149
|
+
workflowName?: string;
|
|
150
|
+
|
|
151
|
+
/**
|
|
152
|
+
* the parent workflow id; adjacent ancestor ID
|
|
153
|
+
*/
|
|
154
|
+
parentWorkflowId?: string;
|
|
155
|
+
|
|
156
|
+
/**
|
|
157
|
+
* the entry point workflow id
|
|
158
|
+
*/
|
|
159
|
+
originJobId?: string;
|
|
160
|
+
|
|
161
|
+
/**
|
|
162
|
+
* OpenTelemetry trace context for the workflow
|
|
163
|
+
*/
|
|
76
164
|
workflowTrace?: string;
|
|
165
|
+
|
|
166
|
+
/**
|
|
167
|
+
* OpenTelemetry span context for the workflow
|
|
168
|
+
*/
|
|
77
169
|
workflowSpan?: string;
|
|
170
|
+
|
|
171
|
+
/**
|
|
172
|
+
* the full-text-search (RediSearch) options for the workflow
|
|
173
|
+
*/
|
|
78
174
|
search?: WorkflowSearchOptions
|
|
175
|
+
|
|
176
|
+
/**
|
|
177
|
+
* the workflow configuration object
|
|
178
|
+
*/
|
|
79
179
|
config?: WorkflowConfig;
|
|
80
|
-
|
|
180
|
+
|
|
181
|
+
/**
|
|
182
|
+
* sets the number of seconds a workflow may exist after completion. As the process engine is an in-memory cache, the default policy is to expire and scrub the job hash as soon as it completes.
|
|
183
|
+
*/
|
|
184
|
+
expire?: number;
|
|
185
|
+
|
|
186
|
+
/**
|
|
187
|
+
* default is true; if false, will not await the execution
|
|
188
|
+
*/
|
|
189
|
+
await?: boolean;
|
|
81
190
|
}
|
|
82
191
|
|
|
192
|
+
/**
|
|
193
|
+
* Options for setting up a hook.
|
|
194
|
+
* 'durable' is the default namespace if not provided; similar to setting `appid` in the YAML
|
|
195
|
+
*/
|
|
83
196
|
type HookOptions = {
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
197
|
+
/** Optional namespace under which the hook function will be grouped */
|
|
198
|
+
namespace?: string;
|
|
199
|
+
|
|
200
|
+
/** Optional task queue, needed unless 'entity' is provided */
|
|
201
|
+
taskQueue?: string;
|
|
202
|
+
|
|
203
|
+
/** Input arguments to pass into the hook */
|
|
204
|
+
args: any[];
|
|
205
|
+
|
|
206
|
+
/**
|
|
207
|
+
* Optional entity name. If provided, applies as the workflowName,
|
|
208
|
+
* taskQueue, and prefix. This scopes the FT.SEARCH index appropriately.
|
|
209
|
+
* This is a convenience method but limits options.
|
|
210
|
+
*/
|
|
211
|
+
entity?: string;
|
|
212
|
+
|
|
213
|
+
/** Execution ID, also known as the job ID to hook into */
|
|
214
|
+
workflowId?: string;
|
|
215
|
+
|
|
216
|
+
/** The name of the user's hook function */
|
|
217
|
+
workflowName?: string;
|
|
218
|
+
|
|
219
|
+
/** Bind additional search terms immediately before hook reentry */
|
|
220
|
+
search?: WorkflowSearchOptions
|
|
221
|
+
|
|
222
|
+
/** Hook function constraints (backoffCoefficient, maximumAttempts, maximumInterval) */
|
|
223
|
+
config?: WorkflowConfig;
|
|
92
224
|
}
|
|
93
225
|
|
|
226
|
+
/**
|
|
227
|
+
* Options for sending signals in a workflow.
|
|
228
|
+
*/
|
|
94
229
|
type SignalOptions = {
|
|
230
|
+
/**
|
|
231
|
+
* Task queue associated with the workflow
|
|
232
|
+
*/
|
|
95
233
|
taskQueue: string;
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
234
|
+
|
|
235
|
+
/**
|
|
236
|
+
* Input data for the signal (any serializable object)
|
|
237
|
+
*/
|
|
238
|
+
data: Record<string, any>;
|
|
239
|
+
|
|
240
|
+
/**
|
|
241
|
+
* Execution ID, also known as the job ID
|
|
242
|
+
*/
|
|
243
|
+
workflowId: string;
|
|
244
|
+
|
|
245
|
+
/**
|
|
246
|
+
* Optional name of the user's workflow function
|
|
247
|
+
*/
|
|
248
|
+
workflowName?: string;
|
|
99
249
|
}
|
|
100
250
|
|
|
101
251
|
type ActivityWorkflowDataType = {
|
|
@@ -111,19 +261,7 @@ type WorkflowDataType = {
|
|
|
111
261
|
workflowTopic: string;
|
|
112
262
|
workflowDimension?: string; //is present if hook (not main workflow)
|
|
113
263
|
originJobId?: string; //is present if there is an originating ancestor job (should rename to originJobId)
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
type MeshOSClassConfig = {
|
|
117
|
-
namespace: string;
|
|
118
|
-
taskQueue: string;
|
|
119
|
-
redisOptions: RedisOptions;
|
|
120
|
-
redisClass: RedisClass;
|
|
121
|
-
}
|
|
122
|
-
|
|
123
|
-
type MeshOSConfig = {
|
|
124
|
-
id?: string; //guid for the workflow when instancing
|
|
125
|
-
await?: boolean; //default is false; must explicitly send true to await the final result
|
|
126
|
-
taskQueue?: string; //optional target queue isolate for the function
|
|
264
|
+
canRetry?: boolean;
|
|
127
265
|
}
|
|
128
266
|
|
|
129
267
|
type ConnectionConfig = {
|
|
@@ -139,16 +277,30 @@ type ClientConfig = {
|
|
|
139
277
|
type Registry = {
|
|
140
278
|
[key: string]: Function
|
|
141
279
|
};
|
|
142
|
-
|
|
143
280
|
type WorkerConfig = {
|
|
281
|
+
/** Connection configuration for the worker */
|
|
144
282
|
connection: Connection;
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
283
|
+
|
|
284
|
+
/**
|
|
285
|
+
* Namespace used in the app configuration, denoted as `appid` in the YAML (e.g., 'durable')
|
|
286
|
+
* @default durable
|
|
287
|
+
*/
|
|
288
|
+
namespace?: string;
|
|
289
|
+
|
|
290
|
+
/** Task queue name, denoted as `subscribes` in the YAML (e.g., 'hello-world') */
|
|
291
|
+
taskQueue: string;
|
|
292
|
+
|
|
293
|
+
/** Target function or a record type with a name (string) and reference function */
|
|
294
|
+
workflow: Function | Record<string | symbol, Function>;
|
|
295
|
+
|
|
296
|
+
/** Additional options for configuring the worker */
|
|
148
297
|
options?: WorkerOptions;
|
|
298
|
+
|
|
299
|
+
/** Search options for workflow execution details */
|
|
149
300
|
search?: WorkflowSearchOptions;
|
|
150
301
|
}
|
|
151
302
|
|
|
303
|
+
|
|
152
304
|
type FindWhereQuery = {
|
|
153
305
|
field: string;
|
|
154
306
|
is: '=' | '==' | '>=' | '<=' | '[]';
|
|
@@ -160,7 +312,7 @@ type FindOptions = {
|
|
|
160
312
|
workflowName?: string; //also the function name
|
|
161
313
|
taskQueue?: string;
|
|
162
314
|
namespace?: string;
|
|
163
|
-
index?: string;
|
|
315
|
+
index?: string;
|
|
164
316
|
}
|
|
165
317
|
|
|
166
318
|
type FindWhereOptions = {
|
|
@@ -174,28 +326,18 @@ type FindWhereOptions = {
|
|
|
174
326
|
}
|
|
175
327
|
}
|
|
176
328
|
|
|
177
|
-
type
|
|
178
|
-
|
|
179
|
-
|
|
180
|
-
}
|
|
329
|
+
type WorkerOptions = {
|
|
330
|
+
/** Log level: debug, info, warn, error */
|
|
331
|
+
logLevel?: LogLevel;
|
|
181
332
|
|
|
182
|
-
|
|
183
|
-
|
|
184
|
-
options: ActivityConfig;
|
|
185
|
-
}
|
|
333
|
+
/** Maximum number of attempts, default 5 (HMSH_DURABLE_MAX_ATTEMPTS) */
|
|
334
|
+
maximumAttempts?: number;
|
|
186
335
|
|
|
187
|
-
|
|
188
|
-
|
|
189
|
-
allowList?: Array<MeshOSOptions | string>; //limit which `hook` and `workflow` workers start
|
|
190
|
-
logLevel?: LogLevel; //debug, info, warn, error
|
|
191
|
-
maxSystemRetries?: number; //1-3 (10ms, 100ms, 1_000ms)
|
|
192
|
-
backoffCoefficient?: number; //2-10ish
|
|
193
|
-
}
|
|
336
|
+
/** Backoff coefficient for retry logic, default 10 (HMSH_DURABLE_EXP_BACKOFF) */
|
|
337
|
+
backoffCoefficient?: number;
|
|
194
338
|
|
|
195
|
-
|
|
196
|
-
|
|
197
|
-
maxSystemRetries?: number; //1-3 (10ms, 100ms, 1_000ms)
|
|
198
|
-
backoffCoefficient?: number; //2-10ish
|
|
339
|
+
/** Maximum interval between retries, default 120s (HMSH_DURABLE_MAX_INTERVAL) */
|
|
340
|
+
maximumInterval?: string;
|
|
199
341
|
}
|
|
200
342
|
|
|
201
343
|
type ContextType = {
|
|
@@ -208,24 +350,60 @@ type ProxyType<ACT> = {
|
|
|
208
350
|
[K in keyof ACT]: FunctionSignature<ACT[K]>;
|
|
209
351
|
};
|
|
210
352
|
|
|
353
|
+
/**
|
|
354
|
+
* Configuration settings for activities within a workflow.
|
|
355
|
+
*/
|
|
211
356
|
type ActivityConfig = {
|
|
357
|
+
/** Start to close timeout for the activity; not yet implemented */
|
|
212
358
|
startToCloseTimeout?: string;
|
|
359
|
+
|
|
360
|
+
/** Configuration for specific activities, type not yet specified */
|
|
213
361
|
activities?: any;
|
|
362
|
+
|
|
363
|
+
/** Retry policy configuration for activities */
|
|
214
364
|
retryPolicy?: {
|
|
215
|
-
|
|
216
|
-
maximumAttempts
|
|
217
|
-
|
|
218
|
-
|
|
365
|
+
/** Maximum number of retry attempts, default is 5 (HMSH_DURABLE_MAX_ATTEMPTS) */
|
|
366
|
+
maximumAttempts?: number;
|
|
367
|
+
/** Factor by which the retry timeout increases, default is 10 (HMSH_DURABLE_MAX_INTERVAL) */
|
|
368
|
+
backoffCoefficient?: number;
|
|
369
|
+
/** Maximum interval between retries, default is '120s' (HMSH_DURABLE_EXP_BACKOFF) */
|
|
370
|
+
maximumInterval?: string;
|
|
371
|
+
/** Whether to throw an error on failure, default is true */
|
|
372
|
+
throwOnError?: boolean;
|
|
219
373
|
};
|
|
220
374
|
};
|
|
221
375
|
|
|
376
|
+
/**
|
|
377
|
+
* The proxy response object returned from the activity proxy flow
|
|
378
|
+
*/
|
|
379
|
+
type ProxyResponseType<T> = {
|
|
380
|
+
data?: T, //expected data
|
|
381
|
+
$error?: StreamError,
|
|
382
|
+
done?: boolean, //non-existent if error was thrown in transition (not during execution)
|
|
383
|
+
jc: string,
|
|
384
|
+
ju: string
|
|
385
|
+
};
|
|
386
|
+
|
|
387
|
+
/**
|
|
388
|
+
* The child flow response object returned from the main flow during recursion
|
|
389
|
+
*/
|
|
390
|
+
type ChildResponseType<T> = {
|
|
391
|
+
data?: T, //expected data
|
|
392
|
+
$error?: StreamError,
|
|
393
|
+
done?: boolean, //non-existent if error was thrown in transition (not during execution)
|
|
394
|
+
jc: string,
|
|
395
|
+
ju: string
|
|
396
|
+
};
|
|
397
|
+
|
|
222
398
|
export {
|
|
223
399
|
ActivityConfig,
|
|
224
400
|
ActivityWorkflowDataType,
|
|
401
|
+
ChildResponseType,
|
|
225
402
|
ClientConfig,
|
|
226
403
|
ContextType,
|
|
227
404
|
ConnectionConfig,
|
|
228
405
|
Connection,
|
|
406
|
+
ProxyResponseType,
|
|
229
407
|
ProxyType,
|
|
230
408
|
Registry,
|
|
231
409
|
SignalOptions,
|
|
@@ -233,11 +411,6 @@ export {
|
|
|
233
411
|
FindWhereOptions,
|
|
234
412
|
FindWhereQuery,
|
|
235
413
|
HookOptions,
|
|
236
|
-
MeshOSActivityOptions,
|
|
237
|
-
MeshOSWorkerOptions,
|
|
238
|
-
MeshOSClassConfig,
|
|
239
|
-
MeshOSConfig,
|
|
240
|
-
MeshOSOptions,
|
|
241
414
|
WorkerConfig,
|
|
242
415
|
WorkflowConfig,
|
|
243
416
|
WorkerOptions,
|
package/types/exporter.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { StringAnyType
|
|
1
|
+
import { StringAnyType } from "./serializer";
|
|
2
2
|
|
|
3
3
|
export type ExportItem = [(string | null), string, any];
|
|
4
4
|
|
|
@@ -46,14 +46,40 @@ export interface ExportCycles {
|
|
|
46
46
|
[key: string]: string[];
|
|
47
47
|
};
|
|
48
48
|
|
|
49
|
+
export type IdemParts = {
|
|
50
|
+
index: number;
|
|
51
|
+
secondary?: number;
|
|
52
|
+
dimension?: string;
|
|
53
|
+
};
|
|
54
|
+
|
|
55
|
+
export type IdemType = {
|
|
56
|
+
key: string;
|
|
57
|
+
value: string;
|
|
58
|
+
parts: IdemParts;
|
|
59
|
+
};
|
|
60
|
+
|
|
61
|
+
export interface TimelineEntry {
|
|
62
|
+
activity: string;
|
|
63
|
+
dimensions: string;
|
|
64
|
+
created: string;
|
|
65
|
+
updated: string;
|
|
66
|
+
}
|
|
67
|
+
|
|
68
|
+
export interface TimestampParts {
|
|
69
|
+
activity: string;
|
|
70
|
+
dimensions: string;
|
|
71
|
+
created: string;
|
|
72
|
+
updated: string;
|
|
73
|
+
}
|
|
74
|
+
|
|
49
75
|
export interface DurableJobExport {
|
|
50
76
|
data: StringAnyType;
|
|
51
|
-
dependencies
|
|
77
|
+
dependencies?: Record<string, any>[];
|
|
52
78
|
state: StringAnyType;
|
|
53
79
|
status: string;
|
|
54
|
-
timeline
|
|
55
|
-
|
|
56
|
-
|
|
80
|
+
timeline?: JobTimeline[];
|
|
81
|
+
idempotents: IdemType[];
|
|
82
|
+
replay: TimestampParts[];
|
|
57
83
|
};
|
|
58
84
|
|
|
59
85
|
export interface JobExport {
|
package/types/index.ts
CHANGED
|
@@ -30,10 +30,12 @@ export {
|
|
|
30
30
|
export {
|
|
31
31
|
ActivityConfig,
|
|
32
32
|
ActivityWorkflowDataType,
|
|
33
|
+
ChildResponseType,
|
|
33
34
|
ClientConfig,
|
|
34
35
|
ContextType,
|
|
35
36
|
ConnectionConfig,
|
|
36
37
|
Connection,
|
|
38
|
+
ProxyResponseType,
|
|
37
39
|
ProxyType,
|
|
38
40
|
Registry,
|
|
39
41
|
SignalOptions,
|
|
@@ -41,11 +43,6 @@ export {
|
|
|
41
43
|
FindWhereOptions,
|
|
42
44
|
FindWhereQuery,
|
|
43
45
|
HookOptions,
|
|
44
|
-
MeshOSActivityOptions,
|
|
45
|
-
MeshOSWorkerOptions,
|
|
46
|
-
MeshOSClassConfig,
|
|
47
|
-
MeshOSConfig,
|
|
48
|
-
MeshOSOptions,
|
|
49
46
|
WorkflowConfig,
|
|
50
47
|
WorkerConfig,
|
|
51
48
|
WorkerOptions,
|
|
@@ -90,8 +87,11 @@ export {
|
|
|
90
87
|
export { MappingStatements } from './map';
|
|
91
88
|
export {
|
|
92
89
|
Pipe,
|
|
90
|
+
PipeContext,
|
|
93
91
|
PipeItem,
|
|
94
|
-
PipeItems
|
|
92
|
+
PipeItems,
|
|
93
|
+
PipeObject,
|
|
94
|
+
ReduceObject } from './pipe';
|
|
95
95
|
export {
|
|
96
96
|
HotMesh,
|
|
97
97
|
HotMeshApp,
|
|
@@ -187,4 +187,3 @@ export {
|
|
|
187
187
|
TransitionMatch,
|
|
188
188
|
TransitionRule,
|
|
189
189
|
Transitions } from './transition';
|
|
190
|
-
|