@trigger.dev/core 3.0.0-beta.45 → 3.0.0-beta.47
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/dist/{catalog-mlNxCacM.d.ts → catalog-N-X0Te3W.d.mts} +5 -23
- package/dist/{catalog-QcLmPVsr.d.mts → catalog-NxVZnWZh.d.ts} +5 -23
- package/dist/{common-55Mqj8JP.d.mts → common-fIyU5pmz.d.mts} +13 -0
- package/dist/{common-55Mqj8JP.d.ts → common-fIyU5pmz.d.ts} +13 -0
- package/dist/{manager-6NRInm7C.d.ts → manager-2ZQ3_twq.d.ts} +1 -1
- package/dist/{manager-2AqSY67c.d.mts → manager-X_HrWQ7_.d.mts} +1 -1
- package/dist/{messages-EJX0bMsF.d.mts → messages-Sggr4tid.d.mts} +233 -70
- package/dist/{messages-EJX0bMsF.d.ts → messages-Sggr4tid.d.ts} +233 -70
- package/dist/{schemas-Sb0sJcEt.d.mts → schemas-Zy7mGFgD.d.mts} +22 -0
- package/dist/{schemas-Sb0sJcEt.d.ts → schemas-Zy7mGFgD.d.ts} +22 -0
- package/dist/tracer-N0p2Fuuv.d.mts +23 -0
- package/dist/tracer-N0p2Fuuv.d.ts +23 -0
- package/dist/v3/dev/index.d.mts +2 -2
- package/dist/v3/dev/index.d.ts +2 -2
- package/dist/v3/dev/index.js.map +1 -1
- package/dist/v3/dev/index.mjs.map +1 -1
- package/dist/v3/index.d.mts +50 -38
- package/dist/v3/index.d.ts +50 -38
- package/dist/v3/index.js +503 -343
- package/dist/v3/index.js.map +1 -1
- package/dist/v3/index.mjs +499 -344
- package/dist/v3/index.mjs.map +1 -1
- package/dist/v3/otel/index.js +15 -5
- package/dist/v3/otel/index.js.map +1 -1
- package/dist/v3/otel/index.mjs +15 -5
- package/dist/v3/otel/index.mjs.map +1 -1
- package/dist/v3/prod/index.d.mts +4 -4
- package/dist/v3/prod/index.d.ts +4 -4
- package/dist/v3/prod/index.js +7 -131
- package/dist/v3/prod/index.js.map +1 -1
- package/dist/v3/prod/index.mjs +7 -131
- package/dist/v3/prod/index.mjs.map +1 -1
- package/dist/v3/schemas/index.d.mts +16 -4
- package/dist/v3/schemas/index.d.ts +16 -4
- package/dist/v3/schemas/index.js +35 -40
- package/dist/v3/schemas/index.js.map +1 -1
- package/dist/v3/schemas/index.mjs +35 -41
- package/dist/v3/schemas/index.mjs.map +1 -1
- package/dist/v3/utils/timers.d.mts +6 -0
- package/dist/v3/utils/timers.d.ts +6 -0
- package/dist/v3/utils/timers.js +31 -0
- package/dist/v3/utils/timers.js.map +1 -0
- package/dist/v3/utils/timers.mjs +28 -0
- package/dist/v3/utils/timers.mjs.map +1 -0
- package/dist/v3/workers/index.d.mts +7 -6
- package/dist/v3/workers/index.d.ts +7 -6
- package/dist/v3/workers/index.js +251 -96
- package/dist/v3/workers/index.js.map +1 -1
- package/dist/v3/workers/index.mjs +251 -96
- package/dist/v3/workers/index.mjs.map +1 -1
- package/dist/v3/zodNamespace.js +41 -18
- package/dist/v3/zodNamespace.js.map +1 -1
- package/dist/v3/zodNamespace.mjs +42 -19
- package/dist/v3/zodNamespace.mjs.map +1 -1
- package/dist/v3/zodSocket.d.mts +8 -3
- package/dist/v3/zodSocket.d.ts +8 -3
- package/dist/v3/zodSocket.js +56 -25
- package/dist/v3/zodSocket.js.map +1 -1
- package/dist/v3/zodSocket.mjs +57 -26
- package/dist/v3/zodSocket.mjs.map +1 -1
- package/dist/v3/zodfetch.d.mts +15 -2
- package/dist/v3/zodfetch.d.ts +15 -2
- package/dist/v3/zodfetch.js +248 -28
- package/dist/v3/zodfetch.js.map +1 -1
- package/dist/v3/zodfetch.mjs +246 -29
- package/dist/v3/zodfetch.mjs.map +1 -1
- package/package.json +10 -2
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { z } from 'zod';
|
|
2
|
-
export { B as BatchTaskRunExecutionResult, f as MachineConfig, d as MachineCpu, e as MachineMemory, g as MachinePreset, M as MachinePresetName, m as TaskRun, h as TaskRunBuiltInError, a as TaskRunContext, i as TaskRunCustomErrorObject, c as TaskRunError, k as TaskRunErrorCodes, b as TaskRunExecution, o as TaskRunExecutionAttempt, t as TaskRunExecutionBatch, p as TaskRunExecutionEnvironment, q as TaskRunExecutionOrganization, r as TaskRunExecutionProject, s as TaskRunExecutionQueue, T as TaskRunExecutionResult, u as TaskRunExecutionRetry, n as TaskRunExecutionTask, v as TaskRunExecutionUsage, w as TaskRunFailedExecutionResult, l as TaskRunInternalError, j as TaskRunStringError, x as TaskRunSuccessfulExecutionResult } from '../../common-
|
|
3
|
-
export { c as BackgroundWorkerClientMessages, B as BackgroundWorkerProperties, b as BackgroundWorkerServerMessages, i as ClientToSharedQueueMessages, C as CoordinatorToPlatformMessages, k as CoordinatorToProdWorkerMessages, h as PlatformToCoordinatorMessages, g as PlatformToProviderMessages, a as ProdChildToWorkerMessages, l as ProdWorkerSocketData, P as ProdWorkerToChildMessages, j as ProdWorkerToCoordinatorMessages, f as ProviderToPlatformMessages, S as SharedQueueToClientMessages, T as TaskMetadataFailedToParseData, U as UncaughtExceptionMessage, e as childToWorkerMessages, d as clientWebsocketMessages, s as serverWebsocketMessages, w as workerToChildMessages } from '../../messages-
|
|
4
|
-
import { P as Prettify } from '../../schemas-
|
|
5
|
-
export { C as Config, E as EnvironmentType, F as FixedWindowRateLimit, g as PostStartCauses, h as PreStopCauses, d as ProdTaskRunExecution, e as ProdTaskRunExecutionPayload, Q as QueueOptions, f as RateLimitOptions, i as ResolvedConfig, R as RetryOptions, S as SlidingWindowRateLimit, T as TaskFileMetadata, b as TaskMetadata, a as TaskMetadataWithFilePath, j as TaskRunExecutionLazyAttemptPayload, c as TaskRunExecutionPayload, W as WaitReason } from '../../schemas-
|
|
2
|
+
export { B as BatchTaskRunExecutionResult, f as MachineConfig, d as MachineCpu, e as MachineMemory, g as MachinePreset, M as MachinePresetName, m as TaskRun, h as TaskRunBuiltInError, a as TaskRunContext, i as TaskRunCustomErrorObject, c as TaskRunError, k as TaskRunErrorCodes, b as TaskRunExecution, o as TaskRunExecutionAttempt, t as TaskRunExecutionBatch, p as TaskRunExecutionEnvironment, q as TaskRunExecutionOrganization, r as TaskRunExecutionProject, s as TaskRunExecutionQueue, T as TaskRunExecutionResult, u as TaskRunExecutionRetry, n as TaskRunExecutionTask, v as TaskRunExecutionUsage, w as TaskRunFailedExecutionResult, l as TaskRunInternalError, j as TaskRunStringError, x as TaskRunSuccessfulExecutionResult } from '../../common-fIyU5pmz.mjs';
|
|
3
|
+
export { c as BackgroundWorkerClientMessages, B as BackgroundWorkerProperties, b as BackgroundWorkerServerMessages, i as ClientToSharedQueueMessages, m as CoordinatorSocketData, C as CoordinatorToPlatformMessages, k as CoordinatorToProdWorkerMessages, h as PlatformToCoordinatorMessages, g as PlatformToProviderMessages, a as ProdChildToWorkerMessages, l as ProdWorkerSocketData, P as ProdWorkerToChildMessages, j as ProdWorkerToCoordinatorMessages, f as ProviderToPlatformMessages, S as SharedQueueToClientMessages, T as TaskMetadataFailedToParseData, U as UncaughtExceptionMessage, e as childToWorkerMessages, d as clientWebsocketMessages, s as serverWebsocketMessages, w as workerToChildMessages } from '../../messages-Sggr4tid.mjs';
|
|
4
|
+
import { P as Prettify } from '../../schemas-Zy7mGFgD.mjs';
|
|
5
|
+
export { C as Config, E as EnvironmentType, F as FixedWindowRateLimit, g as PostStartCauses, h as PreStopCauses, d as ProdTaskRunExecution, e as ProdTaskRunExecutionPayload, Q as QueueOptions, f as RateLimitOptions, i as ResolvedConfig, R as RetryOptions, S as SlidingWindowRateLimit, T as TaskFileMetadata, b as TaskMetadata, a as TaskMetadataWithFilePath, j as TaskRunExecutionLazyAttemptPayload, c as TaskRunExecutionPayload, W as WaitReason } from '../../schemas-Zy7mGFgD.mjs';
|
|
6
6
|
|
|
7
7
|
declare const CreateAuthorizationCodeResponseSchema: z.ZodObject<{
|
|
8
8
|
url: z.ZodString;
|
|
@@ -968,6 +968,7 @@ declare const TriggerTaskRequestBody: z.ZodObject<{
|
|
|
968
968
|
payloadType: z.ZodOptional<z.ZodString>;
|
|
969
969
|
delay: z.ZodOptional<z.ZodUnion<[z.ZodString, z.ZodDate]>>;
|
|
970
970
|
ttl: z.ZodOptional<z.ZodUnion<[z.ZodString, z.ZodNumber]>>;
|
|
971
|
+
maxAttempts: z.ZodOptional<z.ZodNumber>;
|
|
971
972
|
}, "strip", z.ZodTypeAny, {
|
|
972
973
|
dependentAttempt?: string | undefined;
|
|
973
974
|
dependentBatch?: string | undefined;
|
|
@@ -1015,6 +1016,7 @@ declare const TriggerTaskRequestBody: z.ZodObject<{
|
|
|
1015
1016
|
payloadType?: string | undefined;
|
|
1016
1017
|
delay?: string | Date | undefined;
|
|
1017
1018
|
ttl?: string | number | undefined;
|
|
1019
|
+
maxAttempts?: number | undefined;
|
|
1018
1020
|
}, {
|
|
1019
1021
|
dependentAttempt?: string | undefined;
|
|
1020
1022
|
dependentBatch?: string | undefined;
|
|
@@ -1062,6 +1064,7 @@ declare const TriggerTaskRequestBody: z.ZodObject<{
|
|
|
1062
1064
|
payloadType?: string | undefined;
|
|
1063
1065
|
delay?: string | Date | undefined;
|
|
1064
1066
|
ttl?: string | number | undefined;
|
|
1067
|
+
maxAttempts?: number | undefined;
|
|
1065
1068
|
}>>;
|
|
1066
1069
|
}, "strip", z.ZodTypeAny, {
|
|
1067
1070
|
payload?: any;
|
|
@@ -1113,6 +1116,7 @@ declare const TriggerTaskRequestBody: z.ZodObject<{
|
|
|
1113
1116
|
payloadType?: string | undefined;
|
|
1114
1117
|
delay?: string | Date | undefined;
|
|
1115
1118
|
ttl?: string | number | undefined;
|
|
1119
|
+
maxAttempts?: number | undefined;
|
|
1116
1120
|
} | undefined;
|
|
1117
1121
|
}, {
|
|
1118
1122
|
payload?: any;
|
|
@@ -1164,6 +1168,7 @@ declare const TriggerTaskRequestBody: z.ZodObject<{
|
|
|
1164
1168
|
payloadType?: string | undefined;
|
|
1165
1169
|
delay?: string | Date | undefined;
|
|
1166
1170
|
ttl?: string | number | undefined;
|
|
1171
|
+
maxAttempts?: number | undefined;
|
|
1167
1172
|
} | undefined;
|
|
1168
1173
|
}>;
|
|
1169
1174
|
type TriggerTaskRequestBody = z.infer<typeof TriggerTaskRequestBody>;
|
|
@@ -1374,6 +1379,7 @@ declare const BatchTriggerTaskRequestBody: z.ZodObject<{
|
|
|
1374
1379
|
payloadType: z.ZodOptional<z.ZodString>;
|
|
1375
1380
|
delay: z.ZodOptional<z.ZodUnion<[z.ZodString, z.ZodDate]>>;
|
|
1376
1381
|
ttl: z.ZodOptional<z.ZodUnion<[z.ZodString, z.ZodNumber]>>;
|
|
1382
|
+
maxAttempts: z.ZodOptional<z.ZodNumber>;
|
|
1377
1383
|
}, "strip", z.ZodTypeAny, {
|
|
1378
1384
|
dependentAttempt?: string | undefined;
|
|
1379
1385
|
dependentBatch?: string | undefined;
|
|
@@ -1421,6 +1427,7 @@ declare const BatchTriggerTaskRequestBody: z.ZodObject<{
|
|
|
1421
1427
|
payloadType?: string | undefined;
|
|
1422
1428
|
delay?: string | Date | undefined;
|
|
1423
1429
|
ttl?: string | number | undefined;
|
|
1430
|
+
maxAttempts?: number | undefined;
|
|
1424
1431
|
}, {
|
|
1425
1432
|
dependentAttempt?: string | undefined;
|
|
1426
1433
|
dependentBatch?: string | undefined;
|
|
@@ -1468,6 +1475,7 @@ declare const BatchTriggerTaskRequestBody: z.ZodObject<{
|
|
|
1468
1475
|
payloadType?: string | undefined;
|
|
1469
1476
|
delay?: string | Date | undefined;
|
|
1470
1477
|
ttl?: string | number | undefined;
|
|
1478
|
+
maxAttempts?: number | undefined;
|
|
1471
1479
|
}>>;
|
|
1472
1480
|
}, "strip", z.ZodTypeAny, {
|
|
1473
1481
|
payload?: any;
|
|
@@ -1519,6 +1527,7 @@ declare const BatchTriggerTaskRequestBody: z.ZodObject<{
|
|
|
1519
1527
|
payloadType?: string | undefined;
|
|
1520
1528
|
delay?: string | Date | undefined;
|
|
1521
1529
|
ttl?: string | number | undefined;
|
|
1530
|
+
maxAttempts?: number | undefined;
|
|
1522
1531
|
} | undefined;
|
|
1523
1532
|
}, {
|
|
1524
1533
|
payload?: any;
|
|
@@ -1570,6 +1579,7 @@ declare const BatchTriggerTaskRequestBody: z.ZodObject<{
|
|
|
1570
1579
|
payloadType?: string | undefined;
|
|
1571
1580
|
delay?: string | Date | undefined;
|
|
1572
1581
|
ttl?: string | number | undefined;
|
|
1582
|
+
maxAttempts?: number | undefined;
|
|
1573
1583
|
} | undefined;
|
|
1574
1584
|
}>, "many">;
|
|
1575
1585
|
dependentAttempt: z.ZodOptional<z.ZodString>;
|
|
@@ -1624,6 +1634,7 @@ declare const BatchTriggerTaskRequestBody: z.ZodObject<{
|
|
|
1624
1634
|
payloadType?: string | undefined;
|
|
1625
1635
|
delay?: string | Date | undefined;
|
|
1626
1636
|
ttl?: string | number | undefined;
|
|
1637
|
+
maxAttempts?: number | undefined;
|
|
1627
1638
|
} | undefined;
|
|
1628
1639
|
}[];
|
|
1629
1640
|
dependentAttempt?: string | undefined;
|
|
@@ -1678,6 +1689,7 @@ declare const BatchTriggerTaskRequestBody: z.ZodObject<{
|
|
|
1678
1689
|
payloadType?: string | undefined;
|
|
1679
1690
|
delay?: string | Date | undefined;
|
|
1680
1691
|
ttl?: string | number | undefined;
|
|
1692
|
+
maxAttempts?: number | undefined;
|
|
1681
1693
|
} | undefined;
|
|
1682
1694
|
}[];
|
|
1683
1695
|
dependentAttempt?: string | undefined;
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { z } from 'zod';
|
|
2
|
-
export { B as BatchTaskRunExecutionResult, f as MachineConfig, d as MachineCpu, e as MachineMemory, g as MachinePreset, M as MachinePresetName, m as TaskRun, h as TaskRunBuiltInError, a as TaskRunContext, i as TaskRunCustomErrorObject, c as TaskRunError, k as TaskRunErrorCodes, b as TaskRunExecution, o as TaskRunExecutionAttempt, t as TaskRunExecutionBatch, p as TaskRunExecutionEnvironment, q as TaskRunExecutionOrganization, r as TaskRunExecutionProject, s as TaskRunExecutionQueue, T as TaskRunExecutionResult, u as TaskRunExecutionRetry, n as TaskRunExecutionTask, v as TaskRunExecutionUsage, w as TaskRunFailedExecutionResult, l as TaskRunInternalError, j as TaskRunStringError, x as TaskRunSuccessfulExecutionResult } from '../../common-
|
|
3
|
-
export { c as BackgroundWorkerClientMessages, B as BackgroundWorkerProperties, b as BackgroundWorkerServerMessages, i as ClientToSharedQueueMessages, C as CoordinatorToPlatformMessages, k as CoordinatorToProdWorkerMessages, h as PlatformToCoordinatorMessages, g as PlatformToProviderMessages, a as ProdChildToWorkerMessages, l as ProdWorkerSocketData, P as ProdWorkerToChildMessages, j as ProdWorkerToCoordinatorMessages, f as ProviderToPlatformMessages, S as SharedQueueToClientMessages, T as TaskMetadataFailedToParseData, U as UncaughtExceptionMessage, e as childToWorkerMessages, d as clientWebsocketMessages, s as serverWebsocketMessages, w as workerToChildMessages } from '../../messages-
|
|
4
|
-
import { P as Prettify } from '../../schemas-
|
|
5
|
-
export { C as Config, E as EnvironmentType, F as FixedWindowRateLimit, g as PostStartCauses, h as PreStopCauses, d as ProdTaskRunExecution, e as ProdTaskRunExecutionPayload, Q as QueueOptions, f as RateLimitOptions, i as ResolvedConfig, R as RetryOptions, S as SlidingWindowRateLimit, T as TaskFileMetadata, b as TaskMetadata, a as TaskMetadataWithFilePath, j as TaskRunExecutionLazyAttemptPayload, c as TaskRunExecutionPayload, W as WaitReason } from '../../schemas-
|
|
2
|
+
export { B as BatchTaskRunExecutionResult, f as MachineConfig, d as MachineCpu, e as MachineMemory, g as MachinePreset, M as MachinePresetName, m as TaskRun, h as TaskRunBuiltInError, a as TaskRunContext, i as TaskRunCustomErrorObject, c as TaskRunError, k as TaskRunErrorCodes, b as TaskRunExecution, o as TaskRunExecutionAttempt, t as TaskRunExecutionBatch, p as TaskRunExecutionEnvironment, q as TaskRunExecutionOrganization, r as TaskRunExecutionProject, s as TaskRunExecutionQueue, T as TaskRunExecutionResult, u as TaskRunExecutionRetry, n as TaskRunExecutionTask, v as TaskRunExecutionUsage, w as TaskRunFailedExecutionResult, l as TaskRunInternalError, j as TaskRunStringError, x as TaskRunSuccessfulExecutionResult } from '../../common-fIyU5pmz.js';
|
|
3
|
+
export { c as BackgroundWorkerClientMessages, B as BackgroundWorkerProperties, b as BackgroundWorkerServerMessages, i as ClientToSharedQueueMessages, m as CoordinatorSocketData, C as CoordinatorToPlatformMessages, k as CoordinatorToProdWorkerMessages, h as PlatformToCoordinatorMessages, g as PlatformToProviderMessages, a as ProdChildToWorkerMessages, l as ProdWorkerSocketData, P as ProdWorkerToChildMessages, j as ProdWorkerToCoordinatorMessages, f as ProviderToPlatformMessages, S as SharedQueueToClientMessages, T as TaskMetadataFailedToParseData, U as UncaughtExceptionMessage, e as childToWorkerMessages, d as clientWebsocketMessages, s as serverWebsocketMessages, w as workerToChildMessages } from '../../messages-Sggr4tid.js';
|
|
4
|
+
import { P as Prettify } from '../../schemas-Zy7mGFgD.js';
|
|
5
|
+
export { C as Config, E as EnvironmentType, F as FixedWindowRateLimit, g as PostStartCauses, h as PreStopCauses, d as ProdTaskRunExecution, e as ProdTaskRunExecutionPayload, Q as QueueOptions, f as RateLimitOptions, i as ResolvedConfig, R as RetryOptions, S as SlidingWindowRateLimit, T as TaskFileMetadata, b as TaskMetadata, a as TaskMetadataWithFilePath, j as TaskRunExecutionLazyAttemptPayload, c as TaskRunExecutionPayload, W as WaitReason } from '../../schemas-Zy7mGFgD.js';
|
|
6
6
|
|
|
7
7
|
declare const CreateAuthorizationCodeResponseSchema: z.ZodObject<{
|
|
8
8
|
url: z.ZodString;
|
|
@@ -968,6 +968,7 @@ declare const TriggerTaskRequestBody: z.ZodObject<{
|
|
|
968
968
|
payloadType: z.ZodOptional<z.ZodString>;
|
|
969
969
|
delay: z.ZodOptional<z.ZodUnion<[z.ZodString, z.ZodDate]>>;
|
|
970
970
|
ttl: z.ZodOptional<z.ZodUnion<[z.ZodString, z.ZodNumber]>>;
|
|
971
|
+
maxAttempts: z.ZodOptional<z.ZodNumber>;
|
|
971
972
|
}, "strip", z.ZodTypeAny, {
|
|
972
973
|
dependentAttempt?: string | undefined;
|
|
973
974
|
dependentBatch?: string | undefined;
|
|
@@ -1015,6 +1016,7 @@ declare const TriggerTaskRequestBody: z.ZodObject<{
|
|
|
1015
1016
|
payloadType?: string | undefined;
|
|
1016
1017
|
delay?: string | Date | undefined;
|
|
1017
1018
|
ttl?: string | number | undefined;
|
|
1019
|
+
maxAttempts?: number | undefined;
|
|
1018
1020
|
}, {
|
|
1019
1021
|
dependentAttempt?: string | undefined;
|
|
1020
1022
|
dependentBatch?: string | undefined;
|
|
@@ -1062,6 +1064,7 @@ declare const TriggerTaskRequestBody: z.ZodObject<{
|
|
|
1062
1064
|
payloadType?: string | undefined;
|
|
1063
1065
|
delay?: string | Date | undefined;
|
|
1064
1066
|
ttl?: string | number | undefined;
|
|
1067
|
+
maxAttempts?: number | undefined;
|
|
1065
1068
|
}>>;
|
|
1066
1069
|
}, "strip", z.ZodTypeAny, {
|
|
1067
1070
|
payload?: any;
|
|
@@ -1113,6 +1116,7 @@ declare const TriggerTaskRequestBody: z.ZodObject<{
|
|
|
1113
1116
|
payloadType?: string | undefined;
|
|
1114
1117
|
delay?: string | Date | undefined;
|
|
1115
1118
|
ttl?: string | number | undefined;
|
|
1119
|
+
maxAttempts?: number | undefined;
|
|
1116
1120
|
} | undefined;
|
|
1117
1121
|
}, {
|
|
1118
1122
|
payload?: any;
|
|
@@ -1164,6 +1168,7 @@ declare const TriggerTaskRequestBody: z.ZodObject<{
|
|
|
1164
1168
|
payloadType?: string | undefined;
|
|
1165
1169
|
delay?: string | Date | undefined;
|
|
1166
1170
|
ttl?: string | number | undefined;
|
|
1171
|
+
maxAttempts?: number | undefined;
|
|
1167
1172
|
} | undefined;
|
|
1168
1173
|
}>;
|
|
1169
1174
|
type TriggerTaskRequestBody = z.infer<typeof TriggerTaskRequestBody>;
|
|
@@ -1374,6 +1379,7 @@ declare const BatchTriggerTaskRequestBody: z.ZodObject<{
|
|
|
1374
1379
|
payloadType: z.ZodOptional<z.ZodString>;
|
|
1375
1380
|
delay: z.ZodOptional<z.ZodUnion<[z.ZodString, z.ZodDate]>>;
|
|
1376
1381
|
ttl: z.ZodOptional<z.ZodUnion<[z.ZodString, z.ZodNumber]>>;
|
|
1382
|
+
maxAttempts: z.ZodOptional<z.ZodNumber>;
|
|
1377
1383
|
}, "strip", z.ZodTypeAny, {
|
|
1378
1384
|
dependentAttempt?: string | undefined;
|
|
1379
1385
|
dependentBatch?: string | undefined;
|
|
@@ -1421,6 +1427,7 @@ declare const BatchTriggerTaskRequestBody: z.ZodObject<{
|
|
|
1421
1427
|
payloadType?: string | undefined;
|
|
1422
1428
|
delay?: string | Date | undefined;
|
|
1423
1429
|
ttl?: string | number | undefined;
|
|
1430
|
+
maxAttempts?: number | undefined;
|
|
1424
1431
|
}, {
|
|
1425
1432
|
dependentAttempt?: string | undefined;
|
|
1426
1433
|
dependentBatch?: string | undefined;
|
|
@@ -1468,6 +1475,7 @@ declare const BatchTriggerTaskRequestBody: z.ZodObject<{
|
|
|
1468
1475
|
payloadType?: string | undefined;
|
|
1469
1476
|
delay?: string | Date | undefined;
|
|
1470
1477
|
ttl?: string | number | undefined;
|
|
1478
|
+
maxAttempts?: number | undefined;
|
|
1471
1479
|
}>>;
|
|
1472
1480
|
}, "strip", z.ZodTypeAny, {
|
|
1473
1481
|
payload?: any;
|
|
@@ -1519,6 +1527,7 @@ declare const BatchTriggerTaskRequestBody: z.ZodObject<{
|
|
|
1519
1527
|
payloadType?: string | undefined;
|
|
1520
1528
|
delay?: string | Date | undefined;
|
|
1521
1529
|
ttl?: string | number | undefined;
|
|
1530
|
+
maxAttempts?: number | undefined;
|
|
1522
1531
|
} | undefined;
|
|
1523
1532
|
}, {
|
|
1524
1533
|
payload?: any;
|
|
@@ -1570,6 +1579,7 @@ declare const BatchTriggerTaskRequestBody: z.ZodObject<{
|
|
|
1570
1579
|
payloadType?: string | undefined;
|
|
1571
1580
|
delay?: string | Date | undefined;
|
|
1572
1581
|
ttl?: string | number | undefined;
|
|
1582
|
+
maxAttempts?: number | undefined;
|
|
1573
1583
|
} | undefined;
|
|
1574
1584
|
}>, "many">;
|
|
1575
1585
|
dependentAttempt: z.ZodOptional<z.ZodString>;
|
|
@@ -1624,6 +1634,7 @@ declare const BatchTriggerTaskRequestBody: z.ZodObject<{
|
|
|
1624
1634
|
payloadType?: string | undefined;
|
|
1625
1635
|
delay?: string | Date | undefined;
|
|
1626
1636
|
ttl?: string | number | undefined;
|
|
1637
|
+
maxAttempts?: number | undefined;
|
|
1627
1638
|
} | undefined;
|
|
1628
1639
|
}[];
|
|
1629
1640
|
dependentAttempt?: string | undefined;
|
|
@@ -1678,6 +1689,7 @@ declare const BatchTriggerTaskRequestBody: z.ZodObject<{
|
|
|
1678
1689
|
payloadType?: string | undefined;
|
|
1679
1690
|
delay?: string | Date | undefined;
|
|
1680
1691
|
ttl?: string | number | undefined;
|
|
1692
|
+
maxAttempts?: number | undefined;
|
|
1681
1693
|
} | undefined;
|
|
1682
1694
|
}[];
|
|
1683
1695
|
dependentAttempt?: string | undefined;
|
package/dist/v3/schemas/index.js
CHANGED
|
@@ -116,6 +116,7 @@ var TaskRun = zod.z.object({
|
|
|
116
116
|
createdAt: zod.z.coerce.date(),
|
|
117
117
|
startedAt: zod.z.coerce.date().default(() => /* @__PURE__ */ new Date()),
|
|
118
118
|
idempotencyKey: zod.z.string().optional(),
|
|
119
|
+
maxAttempts: zod.z.number().optional(),
|
|
119
120
|
durationMs: zod.z.number().default(0),
|
|
120
121
|
costInCents: zod.z.number().default(0),
|
|
121
122
|
baseCostInCents: zod.z.number().default(0)
|
|
@@ -407,6 +408,7 @@ var WaitReason = zod.z.enum([
|
|
|
407
408
|
]);
|
|
408
409
|
var TaskRunExecutionLazyAttemptPayload = zod.z.object({
|
|
409
410
|
runId: zod.z.string(),
|
|
411
|
+
attemptCount: zod.z.number().optional(),
|
|
410
412
|
messageId: zod.z.string(),
|
|
411
413
|
isTest: zod.z.boolean(),
|
|
412
414
|
traceContext: zod.z.record(zod.z.unknown()),
|
|
@@ -487,7 +489,8 @@ var TriggerTaskRequestBody = zod.z.object({
|
|
|
487
489
|
test: zod.z.boolean().optional(),
|
|
488
490
|
payloadType: zod.z.string().optional(),
|
|
489
491
|
delay: zod.z.string().or(zod.z.coerce.date()).optional(),
|
|
490
|
-
ttl: zod.z.string().or(zod.z.number().nonnegative().int()).optional()
|
|
492
|
+
ttl: zod.z.string().or(zod.z.number().nonnegative().int()).optional(),
|
|
493
|
+
maxAttempts: zod.z.number().int().optional()
|
|
491
494
|
}).optional()
|
|
492
495
|
});
|
|
493
496
|
var TriggerTaskResponse = zod.z.object({
|
|
@@ -1000,47 +1003,15 @@ var ProdChildToWorkerMessages = {
|
|
|
1000
1003
|
id: zod.z.string()
|
|
1001
1004
|
})
|
|
1002
1005
|
},
|
|
1003
|
-
TASK_RUN_HEARTBEAT: {
|
|
1004
|
-
message: zod.z.object({
|
|
1005
|
-
version: zod.z.literal("v1").default("v1"),
|
|
1006
|
-
id: zod.z.string()
|
|
1007
|
-
})
|
|
1008
|
-
},
|
|
1009
1006
|
READY_TO_DISPOSE: {
|
|
1010
1007
|
message: zod.z.undefined()
|
|
1011
1008
|
},
|
|
1012
|
-
READY_FOR_CHECKPOINT: {
|
|
1013
|
-
message: zod.z.object({
|
|
1014
|
-
version: zod.z.literal("v1").default("v1")
|
|
1015
|
-
})
|
|
1016
|
-
},
|
|
1017
|
-
CANCEL_CHECKPOINT: {
|
|
1018
|
-
message: zod.z.discriminatedUnion("version", [
|
|
1019
|
-
zod.z.object({
|
|
1020
|
-
version: zod.z.literal("v1")
|
|
1021
|
-
}),
|
|
1022
|
-
zod.z.object({
|
|
1023
|
-
version: zod.z.literal("v2"),
|
|
1024
|
-
reason: WaitReason.optional()
|
|
1025
|
-
})
|
|
1026
|
-
]).default({
|
|
1027
|
-
version: "v1"
|
|
1028
|
-
}),
|
|
1029
|
-
callback: zod.z.object({
|
|
1030
|
-
// TODO: Figure out how best to handle callback schema parsing in zod IPC
|
|
1031
|
-
version: zod.z.literal("v2"),
|
|
1032
|
-
checkpointCanceled: zod.z.boolean(),
|
|
1033
|
-
reason: WaitReason.optional()
|
|
1034
|
-
})
|
|
1035
|
-
},
|
|
1036
1009
|
WAIT_FOR_DURATION: {
|
|
1037
1010
|
message: zod.z.object({
|
|
1038
1011
|
version: zod.z.literal("v1").default("v1"),
|
|
1039
1012
|
ms: zod.z.number(),
|
|
1040
|
-
now: zod.z.number()
|
|
1041
|
-
|
|
1042
|
-
callback: zod.z.object({
|
|
1043
|
-
willCheckpointAndRestore: zod.z.boolean()
|
|
1013
|
+
now: zod.z.number(),
|
|
1014
|
+
waitThresholdInMs: zod.z.number()
|
|
1044
1015
|
})
|
|
1045
1016
|
},
|
|
1046
1017
|
WAIT_FOR_TASK: {
|
|
@@ -1243,6 +1214,7 @@ var CoordinatorToPlatformMessages = {
|
|
|
1243
1214
|
})
|
|
1244
1215
|
])
|
|
1245
1216
|
},
|
|
1217
|
+
// Deprecated: Only workers without lazy attempt support will use this
|
|
1246
1218
|
READY_FOR_EXECUTION: {
|
|
1247
1219
|
message: zod.z.object({
|
|
1248
1220
|
version: zod.z.literal("v1").default("v1"),
|
|
@@ -1406,6 +1378,12 @@ var PlatformToCoordinatorMessages = {
|
|
|
1406
1378
|
version: zod.z.literal("v1").default("v1"),
|
|
1407
1379
|
runId: zod.z.string()
|
|
1408
1380
|
})
|
|
1381
|
+
},
|
|
1382
|
+
DYNAMIC_CONFIG: {
|
|
1383
|
+
message: zod.z.object({
|
|
1384
|
+
version: zod.z.literal("v1").default("v1"),
|
|
1385
|
+
checkpointThresholdInMs: zod.z.number()
|
|
1386
|
+
})
|
|
1409
1387
|
}
|
|
1410
1388
|
};
|
|
1411
1389
|
var ClientToSharedQueueMessages = {
|
|
@@ -1451,10 +1429,9 @@ var IndexTasksMessage = zod.z.object({
|
|
|
1451
1429
|
packageVersion: zod.z.string()
|
|
1452
1430
|
});
|
|
1453
1431
|
var ProdWorkerToCoordinatorMessages = {
|
|
1454
|
-
|
|
1432
|
+
TEST: {
|
|
1455
1433
|
message: zod.z.object({
|
|
1456
|
-
version: zod.z.literal("v1").default("v1")
|
|
1457
|
-
text: zod.z.string()
|
|
1434
|
+
version: zod.z.literal("v1").default("v1")
|
|
1458
1435
|
}),
|
|
1459
1436
|
callback: zod.z.void()
|
|
1460
1437
|
},
|
|
@@ -1477,6 +1454,7 @@ var ProdWorkerToCoordinatorMessages = {
|
|
|
1477
1454
|
})
|
|
1478
1455
|
])
|
|
1479
1456
|
},
|
|
1457
|
+
// Deprecated: Only workers without lazy attempt support will use this
|
|
1480
1458
|
READY_FOR_EXECUTION: {
|
|
1481
1459
|
message: zod.z.object({
|
|
1482
1460
|
version: zod.z.literal("v1").default("v1"),
|
|
@@ -1563,7 +1541,10 @@ var ProdWorkerToCoordinatorMessages = {
|
|
|
1563
1541
|
},
|
|
1564
1542
|
WAIT_FOR_TASK: {
|
|
1565
1543
|
message: zod.z.object({
|
|
1566
|
-
version: zod.z.
|
|
1544
|
+
version: zod.z.enum([
|
|
1545
|
+
"v1",
|
|
1546
|
+
"v2"
|
|
1547
|
+
]).default("v1"),
|
|
1567
1548
|
friendlyId: zod.z.string(),
|
|
1568
1549
|
// This is the attempt that is waiting
|
|
1569
1550
|
attemptFriendlyId: zod.z.string()
|
|
@@ -1574,7 +1555,10 @@ var ProdWorkerToCoordinatorMessages = {
|
|
|
1574
1555
|
},
|
|
1575
1556
|
WAIT_FOR_BATCH: {
|
|
1576
1557
|
message: zod.z.object({
|
|
1577
|
-
version: zod.z.
|
|
1558
|
+
version: zod.z.enum([
|
|
1559
|
+
"v1",
|
|
1560
|
+
"v2"
|
|
1561
|
+
]).default("v1"),
|
|
1578
1562
|
batchFriendlyId: zod.z.string(),
|
|
1579
1563
|
runFriendlyIds: zod.z.string().array(),
|
|
1580
1564
|
// This is the attempt that is waiting
|
|
@@ -1621,6 +1605,12 @@ var ProdWorkerToCoordinatorMessages = {
|
|
|
1621
1605
|
stack: zod.z.string().optional()
|
|
1622
1606
|
})
|
|
1623
1607
|
})
|
|
1608
|
+
},
|
|
1609
|
+
SET_STATE: {
|
|
1610
|
+
message: zod.z.object({
|
|
1611
|
+
version: zod.z.literal("v1").default("v1"),
|
|
1612
|
+
attemptFriendlyId: zod.z.string().optional()
|
|
1613
|
+
})
|
|
1624
1614
|
}
|
|
1625
1615
|
};
|
|
1626
1616
|
var CoordinatorToProdWorkerMessages = {
|
|
@@ -1638,6 +1628,7 @@ var CoordinatorToProdWorkerMessages = {
|
|
|
1638
1628
|
attemptId: zod.z.string()
|
|
1639
1629
|
})
|
|
1640
1630
|
},
|
|
1631
|
+
// Deprecated: Only workers without lazy attempt support will use this
|
|
1641
1632
|
EXECUTE_TASK_RUN: {
|
|
1642
1633
|
message: zod.z.object({
|
|
1643
1634
|
version: zod.z.literal("v1").default("v1"),
|
|
@@ -1684,6 +1675,9 @@ var ProdWorkerSocketData = zod.z.object({
|
|
|
1684
1675
|
deploymentId: zod.z.string(),
|
|
1685
1676
|
deploymentVersion: zod.z.string()
|
|
1686
1677
|
});
|
|
1678
|
+
var CoordinatorSocketData = zod.z.object({
|
|
1679
|
+
supportsDynamicConfig: zod.z.string().optional()
|
|
1680
|
+
});
|
|
1687
1681
|
var PRIMARY_VARIANT = "primary";
|
|
1688
1682
|
var Variant = zod.z.enum([
|
|
1689
1683
|
PRIMARY_VARIANT
|
|
@@ -1895,6 +1889,7 @@ exports.CanceledRunResponse = CanceledRunResponse;
|
|
|
1895
1889
|
exports.CancellationSpanEvent = CancellationSpanEvent;
|
|
1896
1890
|
exports.ClientToSharedQueueMessages = ClientToSharedQueueMessages;
|
|
1897
1891
|
exports.Config = Config;
|
|
1892
|
+
exports.CoordinatorSocketData = CoordinatorSocketData;
|
|
1898
1893
|
exports.CoordinatorToPlatformMessages = CoordinatorToPlatformMessages;
|
|
1899
1894
|
exports.CoordinatorToProdWorkerMessages = CoordinatorToProdWorkerMessages;
|
|
1900
1895
|
exports.CreateAuthorizationCodeResponseSchema = CreateAuthorizationCodeResponseSchema;
|