@lotiai/composer 0.4.0 → 0.5.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/README.md +189 -0
- package/dist/index.d.ts +5 -2
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +6 -1
- package/dist/index.js.map +1 -1
- package/dist/internal/async/build/workflow-factory.d.ts +7 -3
- package/dist/internal/async/build/workflow-factory.d.ts.map +1 -1
- package/dist/internal/async/build/workflow-factory.js +68 -28
- package/dist/internal/async/build/workflow-factory.js.map +1 -1
- package/dist/internal/async/execute/temporal-client.d.ts +10 -1
- package/dist/internal/async/execute/temporal-client.d.ts.map +1 -1
- package/dist/internal/async/execute/temporal-client.js +26 -1
- package/dist/internal/async/execute/temporal-client.js.map +1 -1
- package/dist/internal/async/execute/workflow-execution.d.ts +2 -4
- package/dist/internal/async/execute/workflow-execution.d.ts.map +1 -1
- package/dist/internal/async/execute/workflow-execution.js +5 -1
- package/dist/internal/async/execute/workflow-execution.js.map +1 -1
- package/dist/internal/async/metrics/task-queue-metrics.d.ts.map +1 -1
- package/dist/internal/async/metrics/task-queue-metrics.js +4 -8
- package/dist/internal/async/metrics/task-queue-metrics.js.map +1 -1
- package/dist/internal/async/register/activity-worker.d.ts +14 -1
- package/dist/internal/async/register/activity-worker.d.ts.map +1 -1
- package/dist/internal/async/register/activity-worker.js +79 -20
- package/dist/internal/async/register/activity-worker.js.map +1 -1
- package/dist/internal/async/register/workflow-worker.d.ts +11 -0
- package/dist/internal/async/register/workflow-worker.d.ts.map +1 -1
- package/dist/internal/async/register/workflow-worker.js +7 -3
- package/dist/internal/async/register/workflow-worker.js.map +1 -1
- package/dist/internal/async/register-scripts/start-activity-worker.d.ts.map +1 -1
- package/dist/internal/async/register-scripts/start-activity-worker.js +2 -3
- package/dist/internal/async/register-scripts/start-activity-worker.js.map +1 -1
- package/dist/internal/async/register-scripts/start-workflow-worker.d.ts.map +1 -1
- package/dist/internal/async/register-scripts/start-workflow-worker.js +2 -3
- package/dist/internal/async/register-scripts/start-workflow-worker.js.map +1 -1
- package/dist/internal/async/register-scripts/sync-schedules-via-lambda.d.ts.map +1 -1
- package/dist/internal/async/register-scripts/sync-schedules-via-lambda.js +22 -13
- package/dist/internal/async/register-scripts/sync-schedules-via-lambda.js.map +1 -1
- package/dist/internal/async/register-scripts/sync-schedules.d.ts.map +1 -1
- package/dist/internal/async/register-scripts/sync-schedules.js +6 -3
- package/dist/internal/async/register-scripts/sync-schedules.js.map +1 -1
- package/dist/internal/async/schedule/sync-schedules.d.ts +6 -0
- package/dist/internal/async/schedule/sync-schedules.d.ts.map +1 -1
- package/dist/internal/async/schedule/sync-schedules.js +16 -7
- package/dist/internal/async/schedule/sync-schedules.js.map +1 -1
- package/dist/internal/context-provider.d.ts +43 -1
- package/dist/internal/context-provider.d.ts.map +1 -1
- package/dist/internal/create-composer.js +11 -2
- package/dist/internal/create-composer.js.map +1 -1
- package/dist/internal/dag-sync-workflow.d.ts +3 -3
- package/dist/internal/dag-sync-workflow.d.ts.map +1 -1
- package/dist/internal/dag-sync-workflow.js +14 -11
- package/dist/internal/dag-sync-workflow.js.map +1 -1
- package/dist/internal/error-for-log.d.ts +16 -0
- package/dist/internal/error-for-log.d.ts.map +1 -0
- package/dist/internal/error-for-log.js +55 -0
- package/dist/internal/error-for-log.js.map +1 -0
- package/dist/internal/errors.d.ts +5 -7
- package/dist/internal/errors.d.ts.map +1 -1
- package/dist/internal/errors.js +18 -25
- package/dist/internal/errors.js.map +1 -1
- package/dist/internal/index.d.ts +1 -1
- package/dist/internal/index.d.ts.map +1 -1
- package/dist/internal/index.js.map +1 -1
- package/dist/internal/observability.d.ts +5 -2
- package/dist/internal/observability.d.ts.map +1 -1
- package/dist/internal/observability.js +48 -39
- package/dist/internal/observability.js.map +1 -1
- package/dist/internal/types.d.ts +28 -0
- package/dist/internal/types.d.ts.map +1 -1
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -267,6 +267,33 @@ Error handler return values:
|
|
|
267
267
|
- `Error` -- propagate or transform the error into the result's `error`
|
|
268
268
|
- Throwing -- `error` will be a `WorkflowErrorHandlerFailure` wrapping both the original error and the handler error
|
|
269
269
|
|
|
270
|
+
#### A Wrapper's Message Is Its Own
|
|
271
|
+
|
|
272
|
+
`WorkflowStepError`, `WorkflowBatchError` and `WorkflowErrorHandlerFailure` carry only
|
|
273
|
+
Composer's context in their `message` -- which workflow, which step, which batch -- and never
|
|
274
|
+
repeat the message of the error they wrap:
|
|
275
|
+
|
|
276
|
+
```typescript
|
|
277
|
+
stepError.message; // 'Workflow "abc" failed at step "insertUser" (batch 2)'
|
|
278
|
+
stepError.originalError.message; // the driver's message, verbatim
|
|
279
|
+
stepError.cause; // the same error, via standard error chaining
|
|
280
|
+
```
|
|
281
|
+
|
|
282
|
+
A wrapper goes everywhere: log lines, span attributes, Temporal event history, a parent
|
|
283
|
+
workflow's failure. Inlining the original's message put that text in all of them at once, and
|
|
284
|
+
for MikroORM/knex that message is the parameter-inlined SQL, quoting real row values.
|
|
285
|
+
|
|
286
|
+
This matters for classifying, not just printing. A wrapper copies the original's `code` so
|
|
287
|
+
`matchesError()` keeps working -- which means a classifier keying on `code` sees what looks
|
|
288
|
+
like the original error. When the message was inlined too, a scrubber that rebuilds a database
|
|
289
|
+
error's message from its structured fields would pass the wrapper through untouched, because
|
|
290
|
+
the wrapper carries `code` but not `severity`, `table` or `constraint`. Read `.cause` or
|
|
291
|
+
`.originalError` to get at the underlying error; do not read a wrapper's `message` expecting
|
|
292
|
+
to find it.
|
|
293
|
+
|
|
294
|
+
`toLogContext()` follows the same rule: it hands the logger the original `Error` object rather
|
|
295
|
+
than a `{ name, message, stack }` projection, so your serializer decides what it looks like.
|
|
296
|
+
|
|
270
297
|
### Context Provider
|
|
271
298
|
|
|
272
299
|
The context provider manages per-step resources (e.g. database connections, loggers). It is configured once via `createComposer` and used automatically for every step execution.
|
|
@@ -307,6 +334,162 @@ const composer = createComposer({
|
|
|
307
334
|
});
|
|
308
335
|
```
|
|
309
336
|
|
|
337
|
+
When Composer logs a failure it puts the **`Error` object itself** on the metadata's `error`
|
|
338
|
+
key, rather than a flattened `{ name, message, stack }`. Deciding what an error looks like in a
|
|
339
|
+
log line is the logger's job, and a projection throws away what that decision needs: a database
|
|
340
|
+
driver error's `code`, `severity`, `table` and `constraint` are gone before the logger sees
|
|
341
|
+
them, leaving it only the message -- which for MikroORM/knex is the parameter-inlined SQL,
|
|
342
|
+
quoting real row values.
|
|
343
|
+
|
|
344
|
+
Give your logger an error serializer. `pino`'s `err` serializer, or your own -- but note that
|
|
345
|
+
Composer's own error classes carry `bagState` (the whole workflow bag) and `originalError` as
|
|
346
|
+
enumerable properties. A serializer that walks enumerable own properties will emit both. Pick
|
|
347
|
+
the fields you want rather than dumping the object:
|
|
348
|
+
|
|
349
|
+
```typescript
|
|
350
|
+
const composer = createComposer({
|
|
351
|
+
contextProvider,
|
|
352
|
+
logger: {
|
|
353
|
+
// ...
|
|
354
|
+
error: (msg, meta) => pino().error({ ...meta, error: serializeError(meta?.error) }, msg),
|
|
355
|
+
},
|
|
356
|
+
});
|
|
357
|
+
```
|
|
358
|
+
|
|
359
|
+
A logger that `JSON.stringify`s its metadata will render an `Error` as `{}` -- that is the
|
|
360
|
+
serializer's absence showing, not Composer withholding anything.
|
|
361
|
+
|
|
362
|
+
This covers the logger Composer was given. It does **not** cover the async path's
|
|
363
|
+
workflow-side logging: `workflow-factory.ts` logs through `@temporalio/workflow`'s `wf.log`,
|
|
364
|
+
which Temporal routes to the logger on its own `Runtime`, not to this one.
|
|
365
|
+
|
|
366
|
+
Composer does not wire the injected logger into that Runtime, and will not. `Runtime.install`
|
|
367
|
+
is process-global and single-shot -- it throws once any worker has started or another
|
|
368
|
+
`install` has run -- so a library that calls it seizes a decision belonging to the host
|
|
369
|
+
process. The supported per-worker alternative does not exist either: `wf.log` is delivered by
|
|
370
|
+
a sink named `__temporal_logger`, and Temporal rejects any sink whose name carries its
|
|
371
|
+
reserved `__temporal_` prefix.
|
|
372
|
+
|
|
373
|
+
It would not restore fidelity in any case. Sink arguments cross the workflow sandbox boundary
|
|
374
|
+
by `postMessage`, which constrains them to primitives -- an `Error` cannot arrive on the other
|
|
375
|
+
side for a serializer to classify. So instead of routing those lines, Composer stops putting
|
|
376
|
+
raw error text in them: the workflow side logs an error's **name and code**, never its
|
|
377
|
+
message, and the same holds for every structure it hands to Temporal (see below).
|
|
378
|
+
|
|
379
|
+
To route the lines themselves, install your own logger before starting any worker. `Runtime`
|
|
380
|
+
is re-exported so this needs no direct dependency on `@temporalio/worker`:
|
|
381
|
+
|
|
382
|
+
```typescript
|
|
383
|
+
import { Runtime } from "@lotiai/composer";
|
|
384
|
+
|
|
385
|
+
Runtime.install({ logger: myLogger });
|
|
386
|
+
```
|
|
387
|
+
|
|
388
|
+
### Error Messages on Trace Spans
|
|
389
|
+
|
|
390
|
+
Span attributes go straight to the trace backend without passing through the logger, so
|
|
391
|
+
whatever redaction the logger applies does not reach them. Composer cannot vouch for a step
|
|
392
|
+
error's message, so by default it attaches **no message to any span** -- only
|
|
393
|
+
`workflow.error.type` / `step.error.type`, a built-in or Composer error name (otherwise `Error`)
|
|
394
|
+
-- and `recordException` is called with a name-only exception rather than the `Error`, whose
|
|
395
|
+
`stack` header line repeats the message.
|
|
396
|
+
|
|
397
|
+
Spans still carry `*.error.type` and `*.error.code` where the error supplies a Composer code or
|
|
398
|
+
a cataloged PostgreSQL SQLSTATE, so a failure is still identifiable in a trace. The span status
|
|
399
|
+
description is empty unless a message is rendered.
|
|
400
|
+
|
|
401
|
+
Supply `traceErrorMessage` to put text back on the span, on your terms:
|
|
402
|
+
|
|
403
|
+
```typescript
|
|
404
|
+
const composer = createComposer({
|
|
405
|
+
contextProvider,
|
|
406
|
+
// Return undefined for an error whose message should stay off the span.
|
|
407
|
+
traceErrorMessage: (error) => {
|
|
408
|
+
const cause = error instanceof WorkflowStepError ? error.originalError : error;
|
|
409
|
+
return isDriverError(cause) ? `${cause.name} ${cause.code}` : cause.message;
|
|
410
|
+
},
|
|
411
|
+
});
|
|
412
|
+
```
|
|
413
|
+
|
|
414
|
+
The error handed to the renderer is Composer's own wrapper, whose message is Composer's own
|
|
415
|
+
context -- `Workflow "..." failed at step "..." (batch 2)` -- and never the wrapped error's.
|
|
416
|
+
Reading `.message` is safe, but it says nothing about why the step failed; the original is on
|
|
417
|
+
`.originalError` / `.cause`, and it is that message the renderer has to decide about. If the
|
|
418
|
+
renderer throws, Composer falls back to attaching no message rather than letting it replace
|
|
419
|
+
the workflow's own error.
|
|
420
|
+
|
|
421
|
+
The full `Error` still reaches the logger either way; this controls the trace sink only. It
|
|
422
|
+
applies to sync workflow runs -- async runs use Temporal's own observability.
|
|
423
|
+
|
|
424
|
+
### Scrubbing Temporal Failures
|
|
425
|
+
|
|
426
|
+
Temporal persists an `ApplicationFailure`'s message and stack in event history and renders
|
|
427
|
+
them in the Temporal UI. Neither passes through any logging redaction, so an activity that
|
|
428
|
+
fails on a driver error puts the inlined SQL, row values and all, at rest outside every
|
|
429
|
+
redaction path.
|
|
430
|
+
|
|
431
|
+
`dataConverter` and `interceptors` are the seams for rewriting a failure before Temporal ever
|
|
432
|
+
sees it. Both are configured once on `temporal`, so every worker Composer starts and every
|
|
433
|
+
client it opens gets them:
|
|
434
|
+
|
|
435
|
+
```typescript
|
|
436
|
+
const composer = createComposer({
|
|
437
|
+
contextProvider,
|
|
438
|
+
temporal: {
|
|
439
|
+
serverAddress: "localhost:7233",
|
|
440
|
+
namespace: "my-namespace",
|
|
441
|
+
serviceName: "my-service",
|
|
442
|
+
// A module with a `failureConverter` named export.
|
|
443
|
+
dataConverter: { failureConverterPath: require.resolve("./scrubbing-failure-converter") },
|
|
444
|
+
interceptors: {
|
|
445
|
+
activity: [() => ({ inbound: { execute: scrubbingExecute } } )],
|
|
446
|
+
},
|
|
447
|
+
},
|
|
448
|
+
});
|
|
449
|
+
```
|
|
450
|
+
|
|
451
|
+
`dataConverter` reaches both worker types **and** the client -- a converter installed only on
|
|
452
|
+
the workers leaves the client unable to decode what they wrote. Of `interceptors`, `activity`
|
|
453
|
+
goes to activity workers and `workflowModules` to workflow workers; neither is forwarded to
|
|
454
|
+
the worker that cannot run it. The `syncSchedules` client gets the converter too -- a
|
|
455
|
+
schedule's `initialData` is encoded there and decoded by the workers.
|
|
456
|
+
|
|
457
|
+
The types you need to write either seam (`DataConverter`, `FailureConverter`, `PayloadCodec`,
|
|
458
|
+
`ActivityInterceptorsFactory`) are re-exported from `@lotiai/composer`, so you do not need a
|
|
459
|
+
direct dependency on the Temporal packages.
|
|
460
|
+
|
|
461
|
+
### What Composer Itself Puts in Event History
|
|
462
|
+
|
|
463
|
+
A failure converter has more to reach than `message` and `stackTrace`, so Composer does not
|
|
464
|
+
rely on one being written. What it hands Temporal carries **no error message of its own**:
|
|
465
|
+
|
|
466
|
+
- A step failure travels as `{ stepName, code, parentCodes, type, cause }` -- no `message`, at
|
|
467
|
+
any depth of the cause chain. It is both an activity argument and an `ApplicationFailure`
|
|
468
|
+
detail, so it lands at rest twice; codes and types classify a failure without quoting the
|
|
469
|
+
row. `matchesError()` is unaffected: it matches on codes, which all survive.
|
|
470
|
+
- `details[0].stack` carries stack **frames** only. V8 opens a stack with its `name: message`
|
|
471
|
+
header, so copying `error.stack` whole put a second copy of the message where a converter
|
|
472
|
+
scrubbing `message` and `stackTrace` would not look.
|
|
473
|
+
- An unhandled workflow error throws with `details: [{ error }, { bag }]`. The bag -- every
|
|
474
|
+
value the workflow touched -- is its own entry, so a converter can drop `details[1]` whole
|
|
475
|
+
without rebuilding the error beside it. Read partial workflow state from `details[1].bag`.
|
|
476
|
+
- A code recovered from a `CODE: message` prefix must be identifier-shaped
|
|
477
|
+
(`[A-Z0-9_]{2,50}`). A bare length cutoff laundered arbitrary message text into `code` --
|
|
478
|
+
`constraint "u_email": Key (email)=(jane@x.com)` yielded a 20-character prefix quoting the
|
|
479
|
+
row -- and `code` is emitted exactly where the message is withheld.
|
|
480
|
+
|
|
481
|
+
Two things still carry text Composer cannot vouch for, both of them yours:
|
|
482
|
+
|
|
483
|
+
- `ApplicationFailure.message` is the failing error's own message, which is what a
|
|
484
|
+
`failureConverter` exists to rewrite. This is the seam's primary job.
|
|
485
|
+
- The error-handler activity returns `{ error: { message, code } }` -- the message of the
|
|
486
|
+
`Error` **your** handler returned. It is an activity **result**, encoded by the payload
|
|
487
|
+
converter rather than the failure converter, so reaching it needs a `payloadCodec`.
|
|
488
|
+
|
|
489
|
+
Connections are cached per converter. Converter paths are compared as strings, but
|
|
490
|
+
`payloadCodecs` entries are compared by object identity -- hold codec instances at module
|
|
491
|
+
scope, or a new connection is opened per call.
|
|
492
|
+
|
|
310
493
|
## CLI
|
|
311
494
|
|
|
312
495
|
The package includes a CLI for building and managing Temporal workflow/activity bundles. It reads configuration from a `composer.build-config.ts` file in your package root.
|
|
@@ -458,6 +641,11 @@ Defaults can be overridden per-deployment via `workerProfiles` in `composer.buil
|
|
|
458
641
|
| Export | Description |
|
|
459
642
|
|--------|-------------|
|
|
460
643
|
| `createComposer` | Create a configured Composer instance |
|
|
644
|
+
| `ComposerConfig` | Type: options accepted by `createComposer` |
|
|
645
|
+
| `ComposerWorkerInterceptors` | Type: worker interceptors forwarded to Temporal |
|
|
646
|
+
| `TraceErrorMessage` | Type: renders an error into span text |
|
|
647
|
+
| `DataConverter`, `FailureConverter`, `PayloadCodec` | Types re-exported from `@temporalio/common` |
|
|
648
|
+
| `ActivityInterceptorsFactory` and friends | Types re-exported from `@temporalio/worker` |
|
|
461
649
|
| `createWorkflow` | Create a workflow with compile-time dependency validation |
|
|
462
650
|
| `step` | Factory for creating type-safe steps |
|
|
463
651
|
| `use` | Compose a child workflow into a parent |
|
|
@@ -467,6 +655,7 @@ Defaults can be overridden per-deployment via `workerProfiles` in `composer.buil
|
|
|
467
655
|
| `startActivityWorker` | Start a Temporal activity worker |
|
|
468
656
|
| `getAllTaskQueues` | Get all configured task queue names |
|
|
469
657
|
| `getTaskQueueForProfile` | Get the task queue for a worker profile |
|
|
658
|
+
| `Runtime` | Temporal's `Runtime`, re-exported so a consumer can install their own workflow logger |
|
|
470
659
|
| `WorkflowStepError` | Error class for step failures |
|
|
471
660
|
| `WorkflowBatchError` | Error class for batch failures |
|
|
472
661
|
| `WorkflowErrorHandlerFailure` | Error class for error handler failures |
|
package/dist/index.d.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
export { clearBuildConfigCache, defineBuildConfig, getBuildConfigFilePath, hasBuildConfigFile, type LoadBuildConfigOptions, type LoadedBuildConfig, loadBuildConfig, } from "./build-config/index";
|
|
2
2
|
export type { ComposerBuildConfig, ComposerBuildConfigInput, EnvExclusiveOptIn, } from "./build-config/schema";
|
|
3
|
-
export { type AsyncStepRuntime, type AsyncWorkflowOptions, type Composer, createComposer, createWorkflow, type DurationString, defineSchedule, type ErrorHandler, type FanOut, fanOut, type InferWorkflowResultFromWorkflow, isFanOutStep, type ScheduleDefinition, type ScheduleDefinitionOptions, ScheduleOverlapPolicy, type ScheduleSpec, type Step, type StepContextProvider, type StepRetryPolicy, type SyncComposer, type SyncSchedulesResult, scheduleDefinitionSchema, scheduleOverlapPolicySchema, step, syncSchedules, type TemporalConfig, use, type Workflow, type WorkflowBuilder, type WorkflowResult, } from "./internal";
|
|
3
|
+
export { type AsyncStepRuntime, type AsyncWorkflowOptions, type Composer, type ComposerConfig, type ComposerWorkerInterceptors, createComposer, createWorkflow, type DurationString, defineSchedule, type ErrorHandler, type FanOut, fanOut, type InferWorkflowResultFromWorkflow, isFanOutStep, type ScheduleDefinition, type ScheduleDefinitionOptions, ScheduleOverlapPolicy, type ScheduleSpec, type Step, type StepContextProvider, type StepRetryPolicy, type SyncComposer, type SyncSchedulesResult, scheduleDefinitionSchema, scheduleOverlapPolicySchema, step, syncSchedules, type TemporalConfig, use, type Workflow, type WorkflowBuilder, type WorkflowResult, } from "./internal";
|
|
4
4
|
export { isScheduleDefinition, isWorkflow, } from "./internal/async/build-scripts/utils/type-guards";
|
|
5
5
|
export { type ActivityWorkerRuntimeConfig, type CombinedWorkerConfig, type CombinedWorkerConfigOptions, DEFAULT_WORKER_PROFILE, getAllTaskQueues, getEffectiveProfileConfig, getEffectiveResources, getTaskQueueForProfile, isValidWorkerProfile, type LoadAndResolveActivityWorkerRuntimeConfigOptions, loadAndResolveActivityWorkerRuntimeConfig, loadAndResolveCombinedWorkerConfigForLocalDev, type ResolveActivityWorkerRuntimeConfigOptions, type ResolvedProfilesForEnvironment, resolveActivityWorkerRuntimeConfig, resolveProfilesForEnvironment, WORKER_PROFILES, type WorkerProfile, type WorkerProfileConfig, } from "./internal/async/config/worker-profiles";
|
|
6
6
|
export { type StartActivityWorkerOptions, startActivityWorker, } from "./internal/async/register-scripts/start-activity-worker";
|
|
@@ -11,6 +11,9 @@ export { type RunSyncSchedulesCliOptions, runSyncSchedulesCli, } from "./interna
|
|
|
11
11
|
export { type SyncSchedulesViaLambdaOptions, syncSchedulesViaLambda, } from "./internal/async/register-scripts/sync-schedules-via-lambda";
|
|
12
12
|
export { findPackageRoot } from "./internal/async/utils/find-package-root";
|
|
13
13
|
export { type ErrorMatchTarget, matchesError, WorkflowBatchError, WorkflowErrorHandlerFailure, WorkflowStepError, } from "./internal/errors";
|
|
14
|
-
export type { ComposerLogger } from "./internal/types";
|
|
14
|
+
export type { ComposerLogger, TraceErrorMessage } from "./internal/types";
|
|
15
15
|
export type { WorkflowExecutionStatusName } from "@temporalio/client";
|
|
16
|
+
export type { DataConverter, FailureConverter, PayloadCodec } from "@temporalio/common";
|
|
17
|
+
export type { ActivityExecuteInput, ActivityInboundCallsInterceptor, ActivityInterceptors, ActivityInterceptorsFactory, } from "@temporalio/worker";
|
|
18
|
+
export { Runtime, type RuntimeOptions } from "@temporalio/worker";
|
|
16
19
|
//# sourceMappingURL=index.d.ts.map
|
package/dist/index.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/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AClB,2BAA2B,EAC3B,iBAAiB,GAClB,MAAM,mBAAmB,CAAC;AAC3B,YAAY,EAAE,cAAc,EAAE,iBAAiB,EAAE,MAAM,kBAAkB,CAAC;AAC1E,YAAY,EAAE,2BAA2B,EAAE,MAAM,oBAAoB,CAAC;AAGtE,YAAY,EAAE,aAAa,EAAE,gBAAgB,EAAE,YAAY,EAAE,MAAM,oBAAoB,CAAC;AACxF,YAAY,EACV,oBAAoB,EACpB,+BAA+B,EAC/B,oBAAoB,EACpB,2BAA2B,GAC5B,MAAM,oBAAoB,CAAC;AAI5B,OAAO,EAAE,OAAO,EAAE,KAAK,cAAc,EAAE,MAAM,oBAAoB,CAAC"}
|
package/dist/index.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
// Composer factory and types
|
|
3
3
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
4
|
-
exports.WorkflowStepError = exports.WorkflowErrorHandlerFailure = exports.WorkflowBatchError = exports.matchesError = exports.findPackageRoot = exports.syncSchedulesViaLambda = exports.runSyncSchedulesCli = exports.runScheduleSync = exports.startWorkflowWorker = exports.startAllWorkers = exports.startActivityWorker = exports.WORKER_PROFILES = exports.resolveProfilesForEnvironment = exports.resolveActivityWorkerRuntimeConfig = exports.loadAndResolveCombinedWorkerConfigForLocalDev = exports.loadAndResolveActivityWorkerRuntimeConfig = exports.isValidWorkerProfile = exports.getTaskQueueForProfile = exports.getEffectiveResources = exports.getEffectiveProfileConfig = exports.getAllTaskQueues = exports.DEFAULT_WORKER_PROFILE = exports.isWorkflow = exports.isScheduleDefinition = exports.use = exports.syncSchedules = exports.step = exports.scheduleOverlapPolicySchema = exports.scheduleDefinitionSchema = exports.ScheduleOverlapPolicy = exports.isFanOutStep = exports.fanOut = exports.defineSchedule = exports.createWorkflow = exports.createComposer = exports.loadBuildConfig = exports.hasBuildConfigFile = exports.getBuildConfigFilePath = exports.defineBuildConfig = exports.clearBuildConfigCache = void 0;
|
|
4
|
+
exports.Runtime = exports.WorkflowStepError = exports.WorkflowErrorHandlerFailure = exports.WorkflowBatchError = exports.matchesError = exports.findPackageRoot = exports.syncSchedulesViaLambda = exports.runSyncSchedulesCli = exports.runScheduleSync = exports.startWorkflowWorker = exports.startAllWorkers = exports.startActivityWorker = exports.WORKER_PROFILES = exports.resolveProfilesForEnvironment = exports.resolveActivityWorkerRuntimeConfig = exports.loadAndResolveCombinedWorkerConfigForLocalDev = exports.loadAndResolveActivityWorkerRuntimeConfig = exports.isValidWorkerProfile = exports.getTaskQueueForProfile = exports.getEffectiveResources = exports.getEffectiveProfileConfig = exports.getAllTaskQueues = exports.DEFAULT_WORKER_PROFILE = exports.isWorkflow = exports.isScheduleDefinition = exports.use = exports.syncSchedules = exports.step = exports.scheduleOverlapPolicySchema = exports.scheduleDefinitionSchema = exports.ScheduleOverlapPolicy = exports.isFanOutStep = exports.fanOut = exports.defineSchedule = exports.createWorkflow = exports.createComposer = exports.loadBuildConfig = exports.hasBuildConfigFile = exports.getBuildConfigFilePath = exports.defineBuildConfig = exports.clearBuildConfigCache = void 0;
|
|
5
5
|
var index_1 = require("./build-config/index");
|
|
6
6
|
Object.defineProperty(exports, "clearBuildConfigCache", { enumerable: true, get: function () { return index_1.clearBuildConfigCache; } });
|
|
7
7
|
Object.defineProperty(exports, "defineBuildConfig", { enumerable: true, get: function () { return index_1.defineBuildConfig; } });
|
|
@@ -54,4 +54,9 @@ Object.defineProperty(exports, "matchesError", { enumerable: true, get: function
|
|
|
54
54
|
Object.defineProperty(exports, "WorkflowBatchError", { enumerable: true, get: function () { return errors_1.WorkflowBatchError; } });
|
|
55
55
|
Object.defineProperty(exports, "WorkflowErrorHandlerFailure", { enumerable: true, get: function () { return errors_1.WorkflowErrorHandlerFailure; } });
|
|
56
56
|
Object.defineProperty(exports, "WorkflowStepError", { enumerable: true, get: function () { return errors_1.WorkflowStepError; } });
|
|
57
|
+
// Workflow-side `wf.log` lines are routed by Temporal, not by the injected ComposerLogger.
|
|
58
|
+
// Re-exported so a consumer can install their own logger on the Runtime without a direct
|
|
59
|
+
// dependency on @temporalio/worker; Composer never installs one itself. See the README.
|
|
60
|
+
var worker_1 = require("@temporalio/worker");
|
|
61
|
+
Object.defineProperty(exports, "Runtime", { enumerable: true, get: function () { return worker_1.Runtime; } });
|
|
57
62
|
//# sourceMappingURL=index.js.map
|
package/dist/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":";AAAA,6BAA6B;;;AAE7B,8CAQ8B;AAP5B,8GAAA,qBAAqB,OAAA;AACrB,0GAAA,iBAAiB,OAAA;AACjB,+GAAA,sBAAsB,OAAA;AACtB,2GAAA,kBAAkB,OAAA;AAGlB,wGAAA,eAAe,OAAA;AAOjB,
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":";AAAA,6BAA6B;;;AAE7B,8CAQ8B;AAP5B,8GAAA,qBAAqB,OAAA;AACrB,0GAAA,iBAAiB,OAAA;AACjB,+GAAA,sBAAsB,OAAA;AACtB,2GAAA,kBAAkB,OAAA;AAGlB,wGAAA,eAAe,OAAA;AAOjB,uCAiCoB;AA3BlB,0GAAA,cAAc,OAAA;AACd,0GAAA,cAAc,OAAA;AAEd,0GAAA,cAAc,OAAA;AAGd,kGAAA,MAAM,OAAA;AAEN,wGAAA,YAAY,OAAA;AAGZ,iHAAA,qBAAqB,OAAA;AAOrB,oHAAA,wBAAwB,OAAA;AACxB,uHAAA,2BAA2B,OAAA;AAC3B,gGAAA,IAAI,OAAA;AACJ,yGAAA,aAAa,OAAA;AAEb,+FAAA,GAAG,OAAA;AAKL,gFAG0D;AAFxD,mHAAA,oBAAoB,OAAA;AACpB,yGAAA,UAAU,OAAA;AAEZ,2EAoBiD;AAhB/C,yHAAA,sBAAsB,OAAA;AACtB,mHAAA,gBAAgB,OAAA;AAChB,4HAAA,yBAAyB,OAAA;AACzB,wHAAA,qBAAqB,OAAA;AACrB,yHAAA,sBAAsB,OAAA;AACtB,uHAAA,oBAAoB,OAAA;AAEpB,4IAAA,yCAAyC,OAAA;AACzC,gJAAA,6CAA6C,OAAA;AAG7C,qIAAA,kCAAkC,OAAA;AAClC,gIAAA,6BAA6B,OAAA;AAC7B,kHAAA,eAAe,OAAA;AAIjB,iGAGiE;AAD/D,4HAAA,mBAAmB,OAAA;AAErB,yFAG6D;AAD3D,oHAAA,eAAe,OAAA;AAEjB,iGAGiE;AAD/D,4HAAA,mBAAmB,OAAA;AAErB,mFAG0D;AAFxD,iHAAA,eAAe,OAAA;AAGjB,2FAG8D;AAD5D,yHAAA,mBAAmB,OAAA;AAErB,yGAGqE;AADnE,mIAAA,sBAAsB,OAAA;AAExB,8EAA2E;AAAlE,oHAAA,eAAe,OAAA;AACxB,4CAM2B;AAJzB,sGAAA,YAAY,OAAA;AACZ,4GAAA,kBAAkB,OAAA;AAClB,qHAAA,2BAA2B,OAAA;AAC3B,2GAAA,iBAAiB,OAAA;AAanB,2FAA2F;AAC3F,yFAAyF;AACzF,wFAAwF;AACxF,6CAAkE;AAAzD,iGAAA,OAAO,OAAA"}
|
|
@@ -33,7 +33,6 @@ export interface WorkflowInput {
|
|
|
33
33
|
* Includes parentCodes to support LotiError subclass matching via extractIfPresent.
|
|
34
34
|
*/
|
|
35
35
|
export interface SerializedErrorInfo {
|
|
36
|
-
message: string;
|
|
37
36
|
code?: string;
|
|
38
37
|
/** Parent error codes for subclass matching (e.g., NOT_FOUND -> DB_NOT_FOUND) */
|
|
39
38
|
parentCodes?: readonly string[];
|
|
@@ -42,12 +41,15 @@ export interface SerializedErrorInfo {
|
|
|
42
41
|
}
|
|
43
42
|
/**
|
|
44
43
|
* Information about a step failure, passed to error handler activities.
|
|
44
|
+
*
|
|
45
|
+
* Carries no error message. This value is an activity argument and a member of the
|
|
46
|
+
* `ApplicationFailure` details, so both copies land in Temporal event history at rest,
|
|
47
|
+
* where only a `payloadCodec` could reach them. Codes and types classify a failure
|
|
48
|
+
* without quoting whatever the driver put in the message.
|
|
45
49
|
*/
|
|
46
50
|
export interface StepFailureInfo {
|
|
47
51
|
/** Step name that failed */
|
|
48
52
|
stepName: string;
|
|
49
|
-
/** Error message (from outermost error wrapper) */
|
|
50
|
-
message: string;
|
|
51
53
|
/** Error code if available */
|
|
52
54
|
code?: string;
|
|
53
55
|
/** Parent error codes for subclass matching */
|
|
@@ -68,6 +70,8 @@ export interface BatchErrorInfo {
|
|
|
68
70
|
/** All step failures in the batch */
|
|
69
71
|
errors: StepFailureInfo[];
|
|
70
72
|
}
|
|
73
|
+
/** Code carried by the error a FanOut throws when any of its children fail. */
|
|
74
|
+
export declare const FANOUT_CHILD_FAILURE_CODE = "FANOUT_CHILD_FAILURE";
|
|
71
75
|
/**
|
|
72
76
|
* A FanOut entry in a batch. Orchestrates dynamic child workflow parallelism:
|
|
73
77
|
* mapInput activity -> lane-based child workflow execution -> aggregateResults activity.
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"workflow-factory.d.ts","sourceRoot":"","sources":["../../../../src/internal/async/build/workflow-factory.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;GAiBG;AAGH,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,qBAAqB,CAAC;
|
|
1
|
+
{"version":3,"file":"workflow-factory.d.ts","sourceRoot":"","sources":["../../../../src/internal/async/build/workflow-factory.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;GAiBG;AAGH,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,qBAAqB,CAAC;AAG1D;;GAEG;AACH,MAAM,WAAW,aAAa;IAC5B,wCAAwC;IACxC,WAAW,EAAE,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,CAAC;IAEjC,0BAA0B;IAC1B,QAAQ,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC;IAElC,iFAAiF;IACjF,WAAW,CAAC,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C3D,UAAU,EAAE,MAAM,CAAC;QACnB,2DAA2D;QAC3D,OAAO,EAAE,MAAM,CAAC;KACjB,CAAC,CAAC;CACJ;AAED;;;GAGG;AACH,MAAM,WAAW,sBAAsB;IACrC,oEAAoE;IACpE,GAAG,EAAE,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,CAAC;IACzB,wDAAwD;IACxD,KAAK,CAAC,EAAE;QACN,oBAAoB;QACpB,OAAO,EAAE,MAAM,CAAC;QAChB,8BAA8B;QAC9B,IAAI,CAAC,EAAE,MAAM,CAAC;QACd,sBAAsB;QACtB,IAAI,EAAE,MAAM,CAAC;QACb,4CAA4C;QAC5C,WAAW,CAAC,EAAE,MAAM,CAAC;QACrB,0EAA0E;QAC1E,MAAM,CAAC,EAAE,eAAe,EAAE,CAAC;KAC5B,CAAC;CACH;AAED;;GAEG;AACH,MAAM,WAAW,mBAAmB;IAClC,yCAAyC;IACzC,cAAc,EAAE,MAAM,CAAC;CACxB;AAED;;;;;;;;GAQG;AACH,eAAO,MAAM,qBAAqB,uGAGd,CAAC;AAErB;;;;;;;;;;GAUG;AACH,wBAAgB,sBAAsB,CAAC,IAAI,EAAE,YAAY,IAChB,OAAO,aAAa,KAAG,OAAO,CAAC,sBAAsB,CAAC,CAgV9F"}
|
|
@@ -51,21 +51,58 @@ var __importStar = (this && this.__importStar) || (function () {
|
|
|
51
51
|
};
|
|
52
52
|
})();
|
|
53
53
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
54
|
-
exports.awaitCheckpointUpdate = void 0;
|
|
54
|
+
exports.awaitCheckpointUpdate = exports.FANOUT_CHILD_FAILURE_CODE = void 0;
|
|
55
55
|
exports.createWorkflowFunction = createWorkflowFunction;
|
|
56
56
|
const wf = __importStar(require("@temporalio/workflow"));
|
|
57
|
+
const error_for_log_1 = require("../../error-for-log");
|
|
57
58
|
/**
|
|
58
59
|
* LotiError formats messages as "CODE: message" - extract code from message if not available elsewhere.
|
|
60
|
+
*
|
|
61
|
+
* A code is a documented application classifier here, so it may be preserved when it has the
|
|
62
|
+
* identifier shape the error-matching contract guarantees. Unlike a name or message, arbitrary
|
|
63
|
+
* prose cannot become one through this path. Default trace attributes have a stricter policy.
|
|
59
64
|
*/
|
|
60
65
|
function extractCodeFromMessage(message) {
|
|
61
66
|
if (!message)
|
|
62
67
|
return undefined;
|
|
63
68
|
const colonIndex = message.indexOf(": ");
|
|
64
|
-
if (colonIndex
|
|
65
|
-
return
|
|
69
|
+
if (colonIndex <= 0)
|
|
70
|
+
return undefined;
|
|
71
|
+
const candidate = message.substring(0, colonIndex);
|
|
72
|
+
return workflowErrorCode(candidate);
|
|
73
|
+
}
|
|
74
|
+
/** Code carried by the error a FanOut throws when any of its children fail. */
|
|
75
|
+
exports.FANOUT_CHILD_FAILURE_CODE = "FANOUT_CHILD_FAILURE";
|
|
76
|
+
const WORKFLOW_ERROR_CODE = /^[A-Z0-9_]{2,50}$/;
|
|
77
|
+
function workflowErrorCode(value) {
|
|
78
|
+
return typeof value === "string" && WORKFLOW_ERROR_CODE.test(value) ? value : undefined;
|
|
79
|
+
}
|
|
80
|
+
/** A thrown value's classifier code, walking Temporal's wrapper chain when necessary. */
|
|
81
|
+
function codeOf(value, depth = 0) {
|
|
82
|
+
if (value === null || typeof value !== "object" || depth >= 5)
|
|
83
|
+
return undefined;
|
|
84
|
+
const error = value;
|
|
85
|
+
return (workflowErrorCode(error.code) ??
|
|
86
|
+
codeOf(error.cause, depth + 1) ??
|
|
87
|
+
workflowErrorCode(error.type));
|
|
88
|
+
}
|
|
89
|
+
function firstSafeCode(...values) {
|
|
90
|
+
for (const value of values) {
|
|
91
|
+
const code = workflowErrorCode(value);
|
|
92
|
+
if (code !== undefined)
|
|
93
|
+
return code;
|
|
66
94
|
}
|
|
67
95
|
return undefined;
|
|
68
96
|
}
|
|
97
|
+
function safeParentCodes(values) {
|
|
98
|
+
if (!Array.isArray(values))
|
|
99
|
+
return undefined;
|
|
100
|
+
const codes = values?.flatMap((value) => {
|
|
101
|
+
const code = workflowErrorCode(value);
|
|
102
|
+
return code === undefined ? [] : [code];
|
|
103
|
+
});
|
|
104
|
+
return codes && codes.length > 0 ? codes : undefined;
|
|
105
|
+
}
|
|
69
106
|
/**
|
|
70
107
|
* Extract LotiError metadata from ApplicationFailure.details[0].
|
|
71
108
|
* We store { code, parentCodes, data } there when converting LotiErrors.
|
|
@@ -88,14 +125,13 @@ function buildCauseChain(err, depth) {
|
|
|
88
125
|
if (!err?.cause || depth >= 5)
|
|
89
126
|
return undefined;
|
|
90
127
|
const cause = err.cause;
|
|
91
|
-
const message = cause.message ?? String(cause);
|
|
92
128
|
const lotiDetails = extractLotiDetails(cause);
|
|
93
|
-
|
|
129
|
+
// The message is read only to recover a `CODE: message` prefix; it is not carried forward.
|
|
130
|
+
const code = firstSafeCode(cause.code, cause.type, lotiDetails?.code, extractCodeFromMessage(cause.message));
|
|
94
131
|
return {
|
|
95
|
-
message,
|
|
96
132
|
code,
|
|
97
|
-
parentCodes: lotiDetails?.parentCodes,
|
|
98
|
-
type: cause.name,
|
|
133
|
+
parentCodes: safeParentCodes(lotiDetails?.parentCodes),
|
|
134
|
+
type: (0, error_for_log_1.safeErrorName)(cause.name),
|
|
99
135
|
cause: buildCauseChain(cause, depth + 1),
|
|
100
136
|
};
|
|
101
137
|
}
|
|
@@ -108,16 +144,12 @@ function buildStepFailureInfo(stepName, rawError) {
|
|
|
108
144
|
// ActivityFailure wraps our ApplicationFailure in cause
|
|
109
145
|
const causeError = error?.cause;
|
|
110
146
|
const lotiDetails = extractLotiDetails(causeError) ?? extractLotiDetails(error);
|
|
111
|
-
const code = error?.code ??
|
|
112
|
-
causeError?.type ??
|
|
113
|
-
lotiDetails?.code ??
|
|
114
|
-
extractCodeFromMessage(causeError?.message ?? error?.message);
|
|
147
|
+
const code = firstSafeCode(error?.code, causeError?.type, lotiDetails?.code, extractCodeFromMessage(causeError?.message ?? error?.message));
|
|
115
148
|
return {
|
|
116
149
|
stepName,
|
|
117
|
-
message: causeError?.message ?? error?.message ?? String(rawError),
|
|
118
150
|
code,
|
|
119
|
-
parentCodes: lotiDetails?.parentCodes,
|
|
120
|
-
type: error?.name
|
|
151
|
+
parentCodes: safeParentCodes(lotiDetails?.parentCodes),
|
|
152
|
+
type: (0, error_for_log_1.safeErrorName)(error?.name),
|
|
121
153
|
cause: buildCauseChain(error, 0),
|
|
122
154
|
};
|
|
123
155
|
}
|
|
@@ -368,7 +400,7 @@ function createWorkflowFunction(plan) {
|
|
|
368
400
|
// Error was transformed
|
|
369
401
|
resultError = {
|
|
370
402
|
message: handlerResult.error.message,
|
|
371
|
-
code: handlerResult.error.code,
|
|
403
|
+
code: workflowErrorCode(handlerResult.error.code),
|
|
372
404
|
type: "TransformedError",
|
|
373
405
|
batchNumber,
|
|
374
406
|
};
|
|
@@ -376,14 +408,18 @@ function createWorkflowFunction(plan) {
|
|
|
376
408
|
// If neither, keep the original batch error
|
|
377
409
|
}
|
|
378
410
|
catch (handlerError) {
|
|
411
|
+
// Name and code only: `wf.log` crosses the sandbox boundary by structured
|
|
412
|
+
// clone, so an Error cannot reach the logger's serializer from here, and a
|
|
413
|
+
// flattened message is the raw driver text with nothing left to redact it.
|
|
379
414
|
wf.log.error("Error handler activity failed", {
|
|
380
415
|
workflowId,
|
|
381
416
|
activityName: plan.errorHandlerActivityName,
|
|
382
|
-
|
|
417
|
+
errorName: handlerError instanceof Error ? (0, error_for_log_1.safeErrorName)(handlerError.name) : typeof handlerError,
|
|
418
|
+
errorCode: codeOf(handlerError),
|
|
383
419
|
});
|
|
384
420
|
// Handler crashed - wrap both errors
|
|
385
421
|
resultError = {
|
|
386
|
-
message: `Error handler failed
|
|
422
|
+
message: `Error handler failed while handling batch ${batchNumber} [${failedStepNames}]`,
|
|
387
423
|
code: "WORKFLOW_ERROR_HANDLER_FAILURE",
|
|
388
424
|
type: "WorkflowErrorHandlerFailure",
|
|
389
425
|
batchNumber,
|
|
@@ -394,12 +430,15 @@ function createWorkflowFunction(plan) {
|
|
|
394
430
|
}
|
|
395
431
|
if (resultError) {
|
|
396
432
|
// Unhandled error: throw ApplicationFailure to mark workflow as Failed.
|
|
397
|
-
//
|
|
433
|
+
// The bag is a details entry of its own, not a key on the error entry: it is every
|
|
434
|
+
// value the workflow touched, it goes to Temporal event history at rest, and a
|
|
435
|
+
// scrubbing failure converter has to be able to drop it without rebuilding the
|
|
436
|
+
// error alongside it. Callers extracting partial state read details[1].bag.
|
|
398
437
|
throw wf.ApplicationFailure.create({
|
|
399
438
|
message: resultError.message,
|
|
400
439
|
type: resultError.type ?? "WorkflowError",
|
|
401
440
|
nonRetryable: true,
|
|
402
|
-
details: [{
|
|
441
|
+
details: [{ error: resultError }, { bag }],
|
|
403
442
|
});
|
|
404
443
|
}
|
|
405
444
|
// Error was handled - continue processing remaining batches
|
|
@@ -505,15 +544,13 @@ async function executeFanOutInWorkflow(fanOut, bag, input, parentWorkflowId, act
|
|
|
505
544
|
}
|
|
506
545
|
}
|
|
507
546
|
if (failures.length > 0) {
|
|
547
|
+
// Identify each failed child by index and code, never by message. This string is both
|
|
548
|
+
// logged and inlined into the thrown Error, which becomes a step failure and so reaches
|
|
549
|
+
// Temporal event history -- a child's raw message would be at rest in two places.
|
|
508
550
|
const failureDetails = failures
|
|
509
551
|
.map((f) => {
|
|
510
|
-
const
|
|
511
|
-
|
|
512
|
-
? err.message
|
|
513
|
-
: typeof err === "object" && err !== null && typeof err.message === "string"
|
|
514
|
-
? err.message
|
|
515
|
-
: String(err);
|
|
516
|
-
return `child ${f.index}: ${msg}`;
|
|
552
|
+
const code = codeOf(f.error);
|
|
553
|
+
return code === undefined ? `child ${f.index}` : `child ${f.index}: ${code}`;
|
|
517
554
|
})
|
|
518
555
|
.join("; ");
|
|
519
556
|
wf.log.error("FanOut: child workflow failures", {
|
|
@@ -522,7 +559,10 @@ async function executeFanOutInWorkflow(fanOut, bag, input, parentWorkflowId, act
|
|
|
522
559
|
totalCount: childInputs.length,
|
|
523
560
|
failures: failureDetails,
|
|
524
561
|
});
|
|
525
|
-
throw new Error(`FanOut "${fanOut.name}": ${failures.length} of ${childInputs.length} child workflow(s) failed [${failureDetails}]`)
|
|
562
|
+
throw Object.assign(new Error(`FanOut "${fanOut.name}": ${failures.length} of ${childInputs.length} child workflow(s) failed [${failureDetails}]`),
|
|
563
|
+
// The message is dropped before this reaches event history, so the code is what is
|
|
564
|
+
// left to classify on. Without it, a code would be guessed from the message prefix.
|
|
565
|
+
{ code: exports.FANOUT_CHILD_FAILURE_CODE });
|
|
526
566
|
}
|
|
527
567
|
wf.log.info("FanOut: all children completed, calling aggregateResults", {
|
|
528
568
|
fanOutName: fanOut.name,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"workflow-factory.js","sourceRoot":"","sources":["../../../../src/internal/async/build/workflow-factory.ts"],"names":[],"mappings":";AAAA;;;;;;;;;;;;;;;;;GAiBG;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAyUH,wDA0UC;AAjpBD,yDAA2C;AA4E3C;;GAEG;AACH,SAAS,sBAAsB,CAAC,OAA2B;IACzD,IAAI,CAAC,OAAO;QAAE,OAAO,SAAS,CAAC;IAC/B,MAAM,UAAU,GAAG,OAAO,CAAC,OAAO,CAAC,IAAI,CAAC,CAAC;IACzC,IAAI,UAAU,GAAG,CAAC,IAAI,UAAU,GAAG,EAAE,EAAE,CAAC;QACtC,OAAO,OAAO,CAAC,SAAS,CAAC,CAAC,EAAE,UAAU,CAAC,CAAC;IAC1C,CAAC;IACD,OAAO,SAAS,CAAC;AACnB,CAAC;AAED;;;GAGG;AACH,SAAS,kBAAkB,CACzB,GAAuC;IAEvC,IAAI,CAAC,GAAG,EAAE,OAAO,IAAI,CAAC,KAAK,CAAC,OAAO,CAAC,GAAG,CAAC,OAAO,CAAC,IAAI,GAAG,CAAC,OAAO,CAAC,MAAM,KAAK,CAAC,EAAE,CAAC;QAC7E,OAAO,SAAS,CAAC;IACnB,CAAC;IACD,MAAM,MAAM,GAAG,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,CAAC,CAAC;IAC9D,IAAI,CAAC,KAAK,EAAE,CAAC;QACX,MAAM,IAAI,KAAK,CAAC,uBAAuB,MAAM,CAAC,4BAA4B,EAAE,CAAC,CAAC;IAChF,CAAC;IACD,OAAO,MAAM,KAAK,CAAC,KAAK,EAAE,WAAW,CAAC,CAAC;AACzC,CAAC"}
|
|
@@ -29,7 +29,7 @@
|
|
|
29
29
|
*/
|
|
30
30
|
import type { WorkflowExecutionStatusName, WorkflowHandle } from "@temporalio/client";
|
|
31
31
|
import { Client } from "@temporalio/client";
|
|
32
|
-
import type { VersioningOverride } from "@temporalio/common";
|
|
32
|
+
import type { DataConverter, VersioningOverride } from "@temporalio/common";
|
|
33
33
|
import type { UUIDV7 } from "../../types";
|
|
34
34
|
import type { WorkflowInput } from "../build/workflow-factory";
|
|
35
35
|
/**
|
|
@@ -44,6 +44,15 @@ export interface TemporalClientConfig {
|
|
|
44
44
|
* Temporal namespace
|
|
45
45
|
*/
|
|
46
46
|
namespace: string;
|
|
47
|
+
/**
|
|
48
|
+
* Custom payload and failure converters. Must match what the workers use, or the client
|
|
49
|
+
* cannot decode the payloads and failures they wrote.
|
|
50
|
+
*
|
|
51
|
+
* Connections are cached per converter. Converter *paths* are compared as strings, but
|
|
52
|
+
* `payloadCodecs` entries are compared by object identity -- rebuilding a codec on each
|
|
53
|
+
* call opens a new connection each time. Hold codec instances at module scope.
|
|
54
|
+
*/
|
|
55
|
+
dataConverter?: DataConverter;
|
|
47
56
|
}
|
|
48
57
|
/**
|
|
49
58
|
* Options for starting a workflow execution.
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"temporal-client.d.ts","sourceRoot":"","sources":["../../../../src/internal/async/execute/temporal-client.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA4BG;AAEH,OAAO,KAAK,EAAE,2BAA2B,EAAE,cAAc,EAAE,MAAM,oBAAoB,CAAC;AACtF,OAAO,EAAE,MAAM,EAAqC,MAAM,oBAAoB,CAAC;AAC/E,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,oBAAoB,CAAC;
|
|
1
|
+
{"version":3,"file":"temporal-client.d.ts","sourceRoot":"","sources":["../../../../src/internal/async/execute/temporal-client.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA4BG;AAEH,OAAO,KAAK,EAAE,2BAA2B,EAAE,cAAc,EAAE,MAAM,oBAAoB,CAAC;AACtF,OAAO,EAAE,MAAM,EAAqC,MAAM,oBAAoB,CAAC;AAC/E,OAAO,KAAK,EAAE,aAAa,EAAgB,kBAAkB,EAAE,MAAM,oBAAoB,CAAC;AAC1F,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,aAAa,CAAC;AAC1C,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,2BAA2B,CAAC;AAE/D;;GAEG;AACH,MAAM,WAAW,oBAAoB;IACnC;;OAEG;IACH,OAAO,EAAE,MAAM,CAAC;IAEhB;;OAEG;IACH,SAAS,EAAE,MAAM,CAAC;IAElB;;;;;;;OAOG;IACH,aAAa,CAAC,EAAE,aAAa,CAAC;CAC/B;AAED;;GAEG;AACH,MAAM,WAAW,sBAAsB;IACrC;;OAEG;IACH,YAAY,EAAE,MAAM,CAAC;IAErB;;;;OAIG;IACH,UAAU,EAAE,MAAM,CAAC;IAEnB;;OAEG;IACH,KAAK,EAAE,aAAa,CAAC;IAErB;;;OAGG;IACH,SAAS,CAAC,EAAE,MAAM,CAAC;IAEnB;;;OAGG;IACH,kBAAkB,CAAC,EAAE,kBAAkB,CAAC;IAExC;;OAEG;IACH,YAAY,EAAE,oBAAoB,CAAC;CACpC;AA6BD;;;;;;;;GAQG;AACH,wBAAgB,oBAAoB,CAAC,MAAM,EAAE,oBAAoB,GAAG,OAAO,CAAC,MAAM,CAAC,CAgClF;AAED;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA8BG;AACH,wBAAsB,eAAe,CACnC,OAAO,EAAE,sB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