@kici-dev/engine 0.0.0 → 0.1.1
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/LICENSE +661 -0
- package/README.md +1 -6
- package/dist/audit/access-log-policy.d.ts +97 -0
- package/dist/audit/access-log-policy.js +195 -0
- package/dist/audit/activity.d.ts +156 -0
- package/dist/audit/activity.js +175 -0
- package/dist/audit/retention-policy.d.ts +157 -0
- package/dist/audit/retention-policy.js +364 -0
- package/dist/bundler/index.d.ts +3 -0
- package/dist/bundler/index.js +3 -0
- package/dist/bundler/rolldown-config.d.ts +41 -0
- package/dist/bundler/rolldown-config.js +40 -0
- package/dist/chunk-gOLHoazu.js +4 -0
- package/dist/env/environment-allowlist.d.ts +45 -0
- package/dist/env/environment-allowlist.js +69 -0
- package/dist/environment/index.d.ts +3 -0
- package/dist/environment/index.js +3 -0
- package/dist/environment/scope-resolver.d.ts +35 -0
- package/dist/environment/scope-resolver.js +77 -0
- package/dist/environment/types.d.ts +98 -0
- package/dist/environment/types.js +2 -0
- package/dist/index.d.ts +54 -0
- package/dist/index.js +45 -0
- package/dist/labels.d.ts +106 -0
- package/dist/labels.js +162 -0
- package/dist/metrics/metric-catalog.generated.d.ts +400 -0
- package/dist/metrics/metric-catalog.generated.js +510 -0
- package/dist/protocol/dashboard-global-workflows.d.ts +9 -0
- package/dist/protocol/dashboard-global-workflows.js +3 -0
- package/dist/protocol/event-log-payload.d.ts +16 -0
- package/dist/protocol/event-log-payload.js +21 -0
- package/dist/protocol/messages/access-log.d.ts +545 -0
- package/dist/protocol/messages/access-log.js +175 -0
- package/dist/protocol/messages/actor.d.ts +100 -0
- package/dist/protocol/messages/actor.js +139 -0
- package/dist/protocol/messages/auth.d.ts +25 -0
- package/dist/protocol/messages/auth.js +36 -0
- package/dist/protocol/messages/browser.d.ts +369 -0
- package/dist/protocol/messages/browser.js +225 -0
- package/dist/protocol/messages/capabilities.d.ts +46 -0
- package/dist/protocol/messages/capabilities.js +42 -0
- package/dist/protocol/messages/common.d.ts +53 -0
- package/dist/protocol/messages/common.js +55 -0
- package/dist/protocol/messages/dashboard-global-workflows.d.ts +166 -0
- package/dist/protocol/messages/dashboard-global-workflows.js +80 -0
- package/dist/protocol/messages/dashboard.d.ts +4068 -0
- package/dist/protocol/messages/dashboard.js +1237 -0
- package/dist/protocol/messages/event-log.d.ts +49 -0
- package/dist/protocol/messages/event-log.js +45 -0
- package/dist/protocol/messages/execution-status.d.ts +164 -0
- package/dist/protocol/messages/execution-status.js +166 -0
- package/dist/protocol/messages/join.d.ts +18 -0
- package/dist/protocol/messages/join.js +28 -0
- package/dist/protocol/messages/log-pull.d.ts +27 -0
- package/dist/protocol/messages/log-pull.js +36 -0
- package/dist/protocol/messages/observe.d.ts +75 -0
- package/dist/protocol/messages/observe.js +70 -0
- package/dist/protocol/messages/orchestrator-agent.d.ts +606 -0
- package/dist/protocol/messages/orchestrator-agent.js +481 -0
- package/dist/protocol/messages/peer.d.ts +795 -0
- package/dist/protocol/messages/peer.js +372 -0
- package/dist/protocol/messages/platform-orchestrator.d.ts +1888 -0
- package/dist/protocol/messages/platform-orchestrator.js +379 -0
- package/dist/protocol/messages/run-events.d.ts +155 -0
- package/dist/protocol/messages/run-events.js +115 -0
- package/dist/protocol/messages/saas-orchestrator.d.ts +2179 -0
- package/dist/protocol/messages/source-registration.d.ts +103 -0
- package/dist/protocol/messages/source-registration.js +109 -0
- package/dist/protocol/messages/test-run.d.ts +59 -0
- package/dist/protocol/messages/test-run.js +52 -0
- package/dist/protocol/version.d.ts +12 -0
- package/dist/protocol/version.js +17 -0
- package/dist/provider/changed-files-fetcher.d.ts +24 -0
- package/dist/provider/changed-files-fetcher.js +2 -0
- package/dist/provider/check-run-conclusion.d.ts +15 -0
- package/dist/provider/check-run-conclusion.js +19 -0
- package/dist/provider/check-status-poster.d.ts +15 -0
- package/dist/provider/check-status-poster.js +2 -0
- package/dist/provider/clone-token-provider.d.ts +58 -0
- package/dist/provider/clone-token-provider.js +2 -0
- package/dist/provider/contributor-resolver.d.ts +22 -0
- package/dist/provider/contributor-resolver.js +2 -0
- package/dist/provider/index.d.ts +23 -0
- package/dist/provider/index.js +3 -0
- package/dist/provider/lock-file-fetcher.d.ts +24 -0
- package/dist/provider/lock-file-fetcher.js +2 -0
- package/dist/provider/repo-url-builder.d.ts +35 -0
- package/dist/provider/repo-url-builder.js +2 -0
- package/dist/provider/types.d.ts +9 -0
- package/dist/provider/types.js +2 -0
- package/dist/provider/webhook-normalizer.d.ts +163 -0
- package/dist/provider/webhook-normalizer.js +2 -0
- package/dist/registration/registerable-trigger-type.d.ts +52 -0
- package/dist/registration/registerable-trigger-type.js +56 -0
- package/dist/scaler/resource-types.d.ts +90 -0
- package/dist/scaler/resource-types.js +99 -0
- package/dist/scaler/scaler-backend-type.d.ts +16 -0
- package/dist/scaler/scaler-backend-type.js +20 -0
- package/dist/secrets/index.d.ts +7 -0
- package/dist/secrets/index.js +2 -0
- package/dist/secrets/types.d.ts +138 -0
- package/dist/secrets/types.js +2 -0
- package/dist/state-machine/index.d.ts +2 -0
- package/dist/state-machine/index.js +3 -0
- package/dist/state-machine/machine.d.ts +34 -0
- package/dist/state-machine/machine.js +103 -0
- package/dist/state-machine/types.d.ts +34 -0
- package/dist/state-machine/types.js +15 -0
- package/dist/trigger/decision-trace.d.ts +41 -0
- package/dist/trigger/decision-trace.js +30 -0
- package/dist/trigger/jsonpath-matcher.d.ts +27 -0
- package/dist/trigger/jsonpath-matcher.js +92 -0
- package/dist/trigger/matcher.d.ts +29 -0
- package/dist/trigger/matcher.js +704 -0
- package/dist/trigger/trigger-event-type.d.ts +14 -0
- package/dist/trigger/trigger-event-type.js +66 -0
- package/dist/trigger/types.d.ts +524 -0
- package/dist/trigger/types.js +48 -0
- package/dist/webhook/signature.d.ts +15 -0
- package/dist/webhook/signature.js +32 -0
- package/dist/ws/close-codes.d.ts +28 -0
- package/dist/ws/close-codes.js +33 -0
- package/dist/ws/rate-limiter.d.ts +86 -0
- package/dist/ws/rate-limiter.js +136 -0
- package/dist/ws/ws-like.d.ts +12 -0
- package/dist/ws/ws-like.js +2 -0
- package/package.json +54 -6
- package/sbom.spdx.json +202 -0
- package/index.js +0 -3
|
@@ -0,0 +1,795 @@
|
|
|
1
|
+
import { z } from 'zod';
|
|
2
|
+
/** Peer capabilities advertised during heartbeat and auth response. */
|
|
3
|
+
export declare const peerCapabilitiesSchema: z.ZodObject<{
|
|
4
|
+
s3LogAccess: z.ZodBoolean;
|
|
5
|
+
logRoutingOverride: z.ZodOptional<z.ZodEnum<{
|
|
6
|
+
coordinator: "coordinator";
|
|
7
|
+
direct: "direct";
|
|
8
|
+
}>>;
|
|
9
|
+
}, z.core.$strip>;
|
|
10
|
+
/** Scaler capacity summary included in peer heartbeat and auth response for routing decisions. */
|
|
11
|
+
declare const scalerCapacitySummarySchema: z.ZodObject<{
|
|
12
|
+
name: z.ZodOptional<z.ZodString>;
|
|
13
|
+
type: z.ZodOptional<z.ZodString>;
|
|
14
|
+
labelSets: z.ZodArray<z.ZodArray<z.ZodString>>;
|
|
15
|
+
maxAgents: z.ZodNumber;
|
|
16
|
+
activeCount: z.ZodNumber;
|
|
17
|
+
mandatoryLabels: z.ZodDefault<z.ZodOptional<z.ZodArray<z.ZodString>>>;
|
|
18
|
+
}, z.core.$strip>;
|
|
19
|
+
/** Peer hello: initiator sends ephemeral X25519 public key and nonce. */
|
|
20
|
+
export declare const peerHelloSchema: z.ZodObject<{
|
|
21
|
+
type: z.ZodLiteral<"peer.hello">;
|
|
22
|
+
ephemeralPublicKey: z.ZodString;
|
|
23
|
+
nonce: z.ZodString;
|
|
24
|
+
}, z.core.$strip>;
|
|
25
|
+
/** Peer hello response: responder sends their ephemeral X25519 public key. */
|
|
26
|
+
export declare const peerHelloResponseSchema: z.ZodObject<{
|
|
27
|
+
type: z.ZodLiteral<"peer.hello.response">;
|
|
28
|
+
ephemeralPublicKey: z.ZodString;
|
|
29
|
+
}, z.core.$strip>;
|
|
30
|
+
/** Peer auth request sent after ECDH handshake (encrypted channel established). */
|
|
31
|
+
export declare const peerAuthRequestSchema: z.ZodObject<{
|
|
32
|
+
type: z.ZodLiteral<"peer.auth.request">;
|
|
33
|
+
instanceId: z.ZodString;
|
|
34
|
+
token: z.ZodOptional<z.ZodString>;
|
|
35
|
+
proof: z.ZodOptional<z.ZodString>;
|
|
36
|
+
protocolVersion: z.ZodNumber;
|
|
37
|
+
softwareVersion: z.ZodOptional<z.ZodString>;
|
|
38
|
+
role: z.ZodOptional<z.ZodEnum<{
|
|
39
|
+
coordinator: "coordinator";
|
|
40
|
+
worker: "worker";
|
|
41
|
+
}>>;
|
|
42
|
+
}, z.core.$strip>;
|
|
43
|
+
/** Peer auth response indicating whether the connection was accepted. */
|
|
44
|
+
export declare const peerAuthResponseSchema: z.ZodObject<{
|
|
45
|
+
type: z.ZodLiteral<"peer.auth.response">;
|
|
46
|
+
accepted: z.ZodBoolean;
|
|
47
|
+
instanceId: z.ZodOptional<z.ZodString>;
|
|
48
|
+
reason: z.ZodOptional<z.ZodString>;
|
|
49
|
+
sessionCredential: z.ZodOptional<z.ZodString>;
|
|
50
|
+
role: z.ZodOptional<z.ZodString>;
|
|
51
|
+
softwareVersion: z.ZodOptional<z.ZodString>;
|
|
52
|
+
agents: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
53
|
+
agentId: z.ZodString;
|
|
54
|
+
labels: z.ZodArray<z.ZodString>;
|
|
55
|
+
activeJobs: z.ZodNumber;
|
|
56
|
+
maxConcurrency: z.ZodNumber;
|
|
57
|
+
platform: z.ZodString;
|
|
58
|
+
arch: z.ZodString;
|
|
59
|
+
mandatoryLabels: z.ZodDefault<z.ZodOptional<z.ZodArray<z.ZodString>>>;
|
|
60
|
+
}, z.core.$strip>>>;
|
|
61
|
+
scalerCapacity: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
62
|
+
name: z.ZodOptional<z.ZodString>;
|
|
63
|
+
type: z.ZodOptional<z.ZodString>;
|
|
64
|
+
labelSets: z.ZodArray<z.ZodArray<z.ZodString>>;
|
|
65
|
+
maxAgents: z.ZodNumber;
|
|
66
|
+
activeCount: z.ZodNumber;
|
|
67
|
+
mandatoryLabels: z.ZodDefault<z.ZodOptional<z.ZodArray<z.ZodString>>>;
|
|
68
|
+
}, z.core.$strip>>>;
|
|
69
|
+
capabilities: z.ZodOptional<z.ZodObject<{
|
|
70
|
+
s3LogAccess: z.ZodBoolean;
|
|
71
|
+
logRoutingOverride: z.ZodOptional<z.ZodEnum<{
|
|
72
|
+
coordinator: "coordinator";
|
|
73
|
+
direct: "direct";
|
|
74
|
+
}>>;
|
|
75
|
+
}, z.core.$strip>>;
|
|
76
|
+
}, z.core.$strip>;
|
|
77
|
+
/** Periodic heartbeat from one orchestrator to its peers. */
|
|
78
|
+
export declare const peerHeartbeatSchema: z.ZodObject<{
|
|
79
|
+
type: z.ZodLiteral<"peer.heartbeat">;
|
|
80
|
+
instanceId: z.ZodString;
|
|
81
|
+
term: z.ZodNumber;
|
|
82
|
+
leaderId: z.ZodNullable<z.ZodString>;
|
|
83
|
+
draining: z.ZodBoolean;
|
|
84
|
+
agents: z.ZodArray<z.ZodObject<{
|
|
85
|
+
agentId: z.ZodString;
|
|
86
|
+
labels: z.ZodArray<z.ZodString>;
|
|
87
|
+
activeJobs: z.ZodNumber;
|
|
88
|
+
maxConcurrency: z.ZodNumber;
|
|
89
|
+
platform: z.ZodString;
|
|
90
|
+
arch: z.ZodString;
|
|
91
|
+
mandatoryLabels: z.ZodDefault<z.ZodOptional<z.ZodArray<z.ZodString>>>;
|
|
92
|
+
}, z.core.$strip>>;
|
|
93
|
+
capabilities: z.ZodObject<{
|
|
94
|
+
s3LogAccess: z.ZodBoolean;
|
|
95
|
+
logRoutingOverride: z.ZodOptional<z.ZodEnum<{
|
|
96
|
+
coordinator: "coordinator";
|
|
97
|
+
direct: "direct";
|
|
98
|
+
}>>;
|
|
99
|
+
}, z.core.$strip>;
|
|
100
|
+
scalerCapacity: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
101
|
+
name: z.ZodOptional<z.ZodString>;
|
|
102
|
+
type: z.ZodOptional<z.ZodString>;
|
|
103
|
+
labelSets: z.ZodArray<z.ZodArray<z.ZodString>>;
|
|
104
|
+
maxAgents: z.ZodNumber;
|
|
105
|
+
activeCount: z.ZodNumber;
|
|
106
|
+
mandatoryLabels: z.ZodDefault<z.ZodOptional<z.ZodArray<z.ZodString>>>;
|
|
107
|
+
}, z.core.$strip>>>;
|
|
108
|
+
configVersion: z.ZodOptional<z.ZodNumber>;
|
|
109
|
+
registryVersion: z.ZodOptional<z.ZodNumber>;
|
|
110
|
+
timestamp: z.ZodNumber;
|
|
111
|
+
hostname: z.ZodOptional<z.ZodString>;
|
|
112
|
+
osRelease: z.ZodOptional<z.ZodString>;
|
|
113
|
+
totalMemoryMb: z.ZodOptional<z.ZodNumber>;
|
|
114
|
+
memoryUsedMb: z.ZodOptional<z.ZodNumber>;
|
|
115
|
+
memoryAvailableMb: z.ZodOptional<z.ZodNumber>;
|
|
116
|
+
cpuCount: z.ZodOptional<z.ZodNumber>;
|
|
117
|
+
uptimeSeconds: z.ZodOptional<z.ZodNumber>;
|
|
118
|
+
nodeVersion: z.ZodOptional<z.ZodString>;
|
|
119
|
+
runningAsUser: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
120
|
+
runningAsUid: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
|
|
121
|
+
version: z.ZodOptional<z.ZodString>;
|
|
122
|
+
}, z.core.$strip>;
|
|
123
|
+
/** Request to reroute a job to another orchestrator (no local agent can handle it). */
|
|
124
|
+
export declare const jobRerouteSchema: z.ZodObject<{
|
|
125
|
+
type: z.ZodLiteral<"job.reroute">;
|
|
126
|
+
messageId: z.ZodString;
|
|
127
|
+
jobId: z.ZodString;
|
|
128
|
+
runId: z.ZodString;
|
|
129
|
+
deliveryId: z.ZodString;
|
|
130
|
+
routingKey: z.ZodString;
|
|
131
|
+
event: z.ZodString;
|
|
132
|
+
action: z.ZodNullable<z.ZodString>;
|
|
133
|
+
payload: z.ZodRecord<z.ZodString, z.ZodUnknown>;
|
|
134
|
+
jobName: z.ZodString;
|
|
135
|
+
workflowName: z.ZodString;
|
|
136
|
+
runsOnLabels: z.ZodArray<z.ZodArray<z.ZodString>>;
|
|
137
|
+
excludeLabels: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
138
|
+
triedConnections: z.ZodArray<z.ZodString>;
|
|
139
|
+
maxHops: z.ZodNumber;
|
|
140
|
+
coordinatorId: z.ZodString;
|
|
141
|
+
requestId: z.ZodOptional<z.ZodString>;
|
|
142
|
+
traceId: z.ZodOptional<z.ZodString>;
|
|
143
|
+
jobConfig: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
|
|
144
|
+
repoUrl: z.ZodOptional<z.ZodString>;
|
|
145
|
+
ref: z.ZodOptional<z.ZodString>;
|
|
146
|
+
sha: z.ZodOptional<z.ZodString>;
|
|
147
|
+
provider: z.ZodOptional<z.ZodString>;
|
|
148
|
+
providerContext: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
|
|
149
|
+
sourceTarUrl: z.ZodOptional<z.ZodString>;
|
|
150
|
+
sourceTarHash: z.ZodOptional<z.ZodString>;
|
|
151
|
+
depsUrl: z.ZodOptional<z.ZodString>;
|
|
152
|
+
depsHash: z.ZodOptional<z.ZodString>;
|
|
153
|
+
cloneToken: z.ZodOptional<z.ZodString>;
|
|
154
|
+
encryptedSecrets: z.ZodOptional<z.ZodString>;
|
|
155
|
+
encryptedNamespacedSecrets: z.ZodOptional<z.ZodString>;
|
|
156
|
+
}, z.core.$strip>;
|
|
157
|
+
/** Acknowledgment of a job reroute request. */
|
|
158
|
+
export declare const jobRerouteAckSchema: z.ZodObject<{
|
|
159
|
+
type: z.ZodLiteral<"job.reroute.ack">;
|
|
160
|
+
messageId: z.ZodString;
|
|
161
|
+
accepted: z.ZodBoolean;
|
|
162
|
+
reason: z.ZodOptional<z.ZodString>;
|
|
163
|
+
}, z.core.$strip>;
|
|
164
|
+
/**
|
|
165
|
+
* Job or step progress update forwarded from a worker peer to its owning
|
|
166
|
+
* coordinator (the coord that has the run rows in its DB).
|
|
167
|
+
*
|
|
168
|
+
* `kind` is the discriminator the coord uses to decide which downstream
|
|
169
|
+
* call to make:
|
|
170
|
+
* - kind='job' → ExecutionTracker.onJobStatus, which is what drives the
|
|
171
|
+
* run-level state machine (running → success/failed/...).
|
|
172
|
+
* `stepIndex`/`stepName` are unused for this kind.
|
|
173
|
+
* - kind='step' → ExecutionTracker.onStepStatus, which only persists step
|
|
174
|
+
* rows. `stepIndex`/`stepName` MUST point at the step.
|
|
175
|
+
*
|
|
176
|
+
* Without the discriminator, the coord conflated the two and silently
|
|
177
|
+
* dropped every job-level event into onStepStatus, so the run never
|
|
178
|
+
* advanced past `running` for a peer-rerouted job.
|
|
179
|
+
*
|
|
180
|
+
* `state` is typed as the full ExecutionJobStatus enum because the worker
|
|
181
|
+
* forwards the agent's job.status verbatim; ExecutionStepStatus is a
|
|
182
|
+
* strict subset and the coord trusts `kind` to route correctly.
|
|
183
|
+
*/
|
|
184
|
+
export declare const jobProgressSchema: z.ZodObject<{
|
|
185
|
+
type: z.ZodLiteral<"job.progress">;
|
|
186
|
+
kind: z.ZodEnum<{
|
|
187
|
+
job: "job";
|
|
188
|
+
step: "step";
|
|
189
|
+
}>;
|
|
190
|
+
runId: z.ZodString;
|
|
191
|
+
jobId: z.ZodString;
|
|
192
|
+
jobName: z.ZodString;
|
|
193
|
+
stepIndex: z.ZodNumber;
|
|
194
|
+
stepName: z.ZodString;
|
|
195
|
+
state: z.ZodEnum<{
|
|
196
|
+
success: "success";
|
|
197
|
+
pending: "pending";
|
|
198
|
+
running: "running";
|
|
199
|
+
failed: "failed";
|
|
200
|
+
cancelled: "cancelled";
|
|
201
|
+
cancelling: "cancelling";
|
|
202
|
+
queued: "queued";
|
|
203
|
+
recovering: "recovering";
|
|
204
|
+
skipped: "skipped";
|
|
205
|
+
timed_out_stale: "timed_out_stale";
|
|
206
|
+
drift_dropped: "drift_dropped";
|
|
207
|
+
}>;
|
|
208
|
+
timestamp: z.ZodNumber;
|
|
209
|
+
data: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
|
|
210
|
+
}, z.core.$strip>;
|
|
211
|
+
/** Request to cancel a job on a peer orchestrator. */
|
|
212
|
+
export declare const peerJobCancelSchema: z.ZodObject<{
|
|
213
|
+
type: z.ZodLiteral<"peer.job.cancel">;
|
|
214
|
+
runId: z.ZodString;
|
|
215
|
+
jobId: z.ZodOptional<z.ZodString>;
|
|
216
|
+
reason: z.ZodString;
|
|
217
|
+
force: z.ZodOptional<z.ZodBoolean>;
|
|
218
|
+
}, z.core.$strip>;
|
|
219
|
+
/** Raft vote request during leader election. */
|
|
220
|
+
export declare const raftVoteRequestSchema: z.ZodObject<{
|
|
221
|
+
type: z.ZodLiteral<"raft.vote.request">;
|
|
222
|
+
term: z.ZodNumber;
|
|
223
|
+
candidateId: z.ZodString;
|
|
224
|
+
lastLogIndex: z.ZodNumber;
|
|
225
|
+
lastLogTerm: z.ZodNumber;
|
|
226
|
+
}, z.core.$strip>;
|
|
227
|
+
/** Raft vote response from a peer. */
|
|
228
|
+
export declare const raftVoteResponseSchema: z.ZodObject<{
|
|
229
|
+
type: z.ZodLiteral<"raft.vote.response">;
|
|
230
|
+
term: z.ZodNumber;
|
|
231
|
+
voteGranted: z.ZodBoolean;
|
|
232
|
+
voterId: z.ZodString;
|
|
233
|
+
}, z.core.$strip>;
|
|
234
|
+
/** Raft append entries (leader heartbeat only, no log entries). */
|
|
235
|
+
export declare const raftAppendEntriesSchema: z.ZodObject<{
|
|
236
|
+
type: z.ZodLiteral<"raft.append.entries">;
|
|
237
|
+
term: z.ZodNumber;
|
|
238
|
+
leaderId: z.ZodString;
|
|
239
|
+
}, z.core.$strip>;
|
|
240
|
+
/** Log chunk relay: worker -> coordinator. Batched log lines from agent execution. */
|
|
241
|
+
declare const peerLogChunkSchema: z.ZodObject<{
|
|
242
|
+
type: z.ZodLiteral<"peer.log.chunk">;
|
|
243
|
+
runId: z.ZodString;
|
|
244
|
+
jobId: z.ZodString;
|
|
245
|
+
stepIndex: z.ZodNumber;
|
|
246
|
+
lines: z.ZodArray<z.ZodObject<{
|
|
247
|
+
text: z.ZodString;
|
|
248
|
+
timestamp: z.ZodNumber;
|
|
249
|
+
stream: z.ZodOptional<z.ZodEnum<{
|
|
250
|
+
stdout: "stdout";
|
|
251
|
+
stderr: "stderr";
|
|
252
|
+
}>>;
|
|
253
|
+
}, z.core.$strip>>;
|
|
254
|
+
}, z.core.$strip>;
|
|
255
|
+
/** Cache upload request: worker -> coordinator. Worker agent needs upload URL. */
|
|
256
|
+
declare const peerCacheUploadRequestSchema: z.ZodObject<{
|
|
257
|
+
type: z.ZodLiteral<"peer.cache.upload.request">;
|
|
258
|
+
messageId: z.ZodString;
|
|
259
|
+
runId: z.ZodString;
|
|
260
|
+
jobId: z.ZodString;
|
|
261
|
+
cacheType: z.ZodEnum<{
|
|
262
|
+
source: "source";
|
|
263
|
+
deps: "deps";
|
|
264
|
+
}>;
|
|
265
|
+
hash: z.ZodString;
|
|
266
|
+
sizeBytes: z.ZodNumber;
|
|
267
|
+
}, z.core.$strip>;
|
|
268
|
+
/** Cache upload response: coordinator -> worker. Pre-signed upload URL. */
|
|
269
|
+
declare const peerCacheUploadResponseSchema: z.ZodObject<{
|
|
270
|
+
type: z.ZodLiteral<"peer.cache.upload.response">;
|
|
271
|
+
messageId: z.ZodString;
|
|
272
|
+
runId: z.ZodString;
|
|
273
|
+
jobId: z.ZodString;
|
|
274
|
+
uploadUrl: z.ZodString;
|
|
275
|
+
}, z.core.$strip>;
|
|
276
|
+
/**
|
|
277
|
+
* Config reload request: forwarded from one orchestrator to a specific peer
|
|
278
|
+
* when an operator calls POST /admin/config/reload with a `target` parameter.
|
|
279
|
+
* The receiving peer executes a local reload and replies with
|
|
280
|
+
* peer.config.reload.response.
|
|
281
|
+
*/
|
|
282
|
+
export declare const peerConfigReloadSchema: z.ZodObject<{
|
|
283
|
+
type: z.ZodLiteral<"peer.config.reload">;
|
|
284
|
+
messageId: z.ZodString;
|
|
285
|
+
drain: z.ZodOptional<z.ZodBoolean>;
|
|
286
|
+
}, z.core.$strip>;
|
|
287
|
+
/**
|
|
288
|
+
* Config reload response: sent back from the target peer carrying the
|
|
289
|
+
* ReloadResult fields produced by ConfigReloader.executeReload().
|
|
290
|
+
*/
|
|
291
|
+
export declare const peerConfigReloadResponseSchema: z.ZodObject<{
|
|
292
|
+
type: z.ZodLiteral<"peer.config.reload.response">;
|
|
293
|
+
messageId: z.ZodString;
|
|
294
|
+
success: z.ZodBoolean;
|
|
295
|
+
version: z.ZodOptional<z.ZodNumber>;
|
|
296
|
+
errors: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
297
|
+
restartRequired: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
298
|
+
fieldsChanged: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
299
|
+
}, z.core.$strip>;
|
|
300
|
+
/** Graceful shutdown announcement. Peers remove sender from registry immediately. */
|
|
301
|
+
export declare const peerLeavingSchema: z.ZodObject<{
|
|
302
|
+
type: z.ZodLiteral<"peer.leaving">;
|
|
303
|
+
instanceId: z.ZodString;
|
|
304
|
+
term: z.ZodNumber;
|
|
305
|
+
}, z.core.$strip>;
|
|
306
|
+
/**
|
|
307
|
+
* Notify every peer that an agent token has been revoked so each peer can
|
|
308
|
+
* close its own in-flight WS connections authenticated by that token.
|
|
309
|
+
* The originating peer kicks locally first (via the DELETE admin route),
|
|
310
|
+
* then broadcasts this message over the encrypted peer mesh.
|
|
311
|
+
*/
|
|
312
|
+
export declare const peerAgentTokenRevokeSchema: z.ZodObject<{
|
|
313
|
+
type: z.ZodLiteral<"peer.agent-token.revoke">;
|
|
314
|
+
tokenId: z.ZodString;
|
|
315
|
+
senderInstanceId: z.ZodString;
|
|
316
|
+
}, z.core.$strip>;
|
|
317
|
+
/** All peer-to-peer messages (outbound from this node). */
|
|
318
|
+
export declare const peerToPeerMessageSchema: z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
319
|
+
type: z.ZodLiteral<"peer.hello">;
|
|
320
|
+
ephemeralPublicKey: z.ZodString;
|
|
321
|
+
nonce: z.ZodString;
|
|
322
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
323
|
+
type: z.ZodLiteral<"peer.hello.response">;
|
|
324
|
+
ephemeralPublicKey: z.ZodString;
|
|
325
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
326
|
+
type: z.ZodLiteral<"peer.auth.request">;
|
|
327
|
+
instanceId: z.ZodString;
|
|
328
|
+
token: z.ZodOptional<z.ZodString>;
|
|
329
|
+
proof: z.ZodOptional<z.ZodString>;
|
|
330
|
+
protocolVersion: z.ZodNumber;
|
|
331
|
+
softwareVersion: z.ZodOptional<z.ZodString>;
|
|
332
|
+
role: z.ZodOptional<z.ZodEnum<{
|
|
333
|
+
coordinator: "coordinator";
|
|
334
|
+
worker: "worker";
|
|
335
|
+
}>>;
|
|
336
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
337
|
+
type: z.ZodLiteral<"peer.auth.response">;
|
|
338
|
+
accepted: z.ZodBoolean;
|
|
339
|
+
instanceId: z.ZodOptional<z.ZodString>;
|
|
340
|
+
reason: z.ZodOptional<z.ZodString>;
|
|
341
|
+
sessionCredential: z.ZodOptional<z.ZodString>;
|
|
342
|
+
role: z.ZodOptional<z.ZodString>;
|
|
343
|
+
softwareVersion: z.ZodOptional<z.ZodString>;
|
|
344
|
+
agents: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
345
|
+
agentId: z.ZodString;
|
|
346
|
+
labels: z.ZodArray<z.ZodString>;
|
|
347
|
+
activeJobs: z.ZodNumber;
|
|
348
|
+
maxConcurrency: z.ZodNumber;
|
|
349
|
+
platform: z.ZodString;
|
|
350
|
+
arch: z.ZodString;
|
|
351
|
+
mandatoryLabels: z.ZodDefault<z.ZodOptional<z.ZodArray<z.ZodString>>>;
|
|
352
|
+
}, z.core.$strip>>>;
|
|
353
|
+
scalerCapacity: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
354
|
+
name: z.ZodOptional<z.ZodString>;
|
|
355
|
+
type: z.ZodOptional<z.ZodString>;
|
|
356
|
+
labelSets: z.ZodArray<z.ZodArray<z.ZodString>>;
|
|
357
|
+
maxAgents: z.ZodNumber;
|
|
358
|
+
activeCount: z.ZodNumber;
|
|
359
|
+
mandatoryLabels: z.ZodDefault<z.ZodOptional<z.ZodArray<z.ZodString>>>;
|
|
360
|
+
}, z.core.$strip>>>;
|
|
361
|
+
capabilities: z.ZodOptional<z.ZodObject<{
|
|
362
|
+
s3LogAccess: z.ZodBoolean;
|
|
363
|
+
logRoutingOverride: z.ZodOptional<z.ZodEnum<{
|
|
364
|
+
coordinator: "coordinator";
|
|
365
|
+
direct: "direct";
|
|
366
|
+
}>>;
|
|
367
|
+
}, z.core.$strip>>;
|
|
368
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
369
|
+
type: z.ZodLiteral<"peer.heartbeat">;
|
|
370
|
+
instanceId: z.ZodString;
|
|
371
|
+
term: z.ZodNumber;
|
|
372
|
+
leaderId: z.ZodNullable<z.ZodString>;
|
|
373
|
+
draining: z.ZodBoolean;
|
|
374
|
+
agents: z.ZodArray<z.ZodObject<{
|
|
375
|
+
agentId: z.ZodString;
|
|
376
|
+
labels: z.ZodArray<z.ZodString>;
|
|
377
|
+
activeJobs: z.ZodNumber;
|
|
378
|
+
maxConcurrency: z.ZodNumber;
|
|
379
|
+
platform: z.ZodString;
|
|
380
|
+
arch: z.ZodString;
|
|
381
|
+
mandatoryLabels: z.ZodDefault<z.ZodOptional<z.ZodArray<z.ZodString>>>;
|
|
382
|
+
}, z.core.$strip>>;
|
|
383
|
+
capabilities: z.ZodObject<{
|
|
384
|
+
s3LogAccess: z.ZodBoolean;
|
|
385
|
+
logRoutingOverride: z.ZodOptional<z.ZodEnum<{
|
|
386
|
+
coordinator: "coordinator";
|
|
387
|
+
direct: "direct";
|
|
388
|
+
}>>;
|
|
389
|
+
}, z.core.$strip>;
|
|
390
|
+
scalerCapacity: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
391
|
+
name: z.ZodOptional<z.ZodString>;
|
|
392
|
+
type: z.ZodOptional<z.ZodString>;
|
|
393
|
+
labelSets: z.ZodArray<z.ZodArray<z.ZodString>>;
|
|
394
|
+
maxAgents: z.ZodNumber;
|
|
395
|
+
activeCount: z.ZodNumber;
|
|
396
|
+
mandatoryLabels: z.ZodDefault<z.ZodOptional<z.ZodArray<z.ZodString>>>;
|
|
397
|
+
}, z.core.$strip>>>;
|
|
398
|
+
configVersion: z.ZodOptional<z.ZodNumber>;
|
|
399
|
+
registryVersion: z.ZodOptional<z.ZodNumber>;
|
|
400
|
+
timestamp: z.ZodNumber;
|
|
401
|
+
hostname: z.ZodOptional<z.ZodString>;
|
|
402
|
+
osRelease: z.ZodOptional<z.ZodString>;
|
|
403
|
+
totalMemoryMb: z.ZodOptional<z.ZodNumber>;
|
|
404
|
+
memoryUsedMb: z.ZodOptional<z.ZodNumber>;
|
|
405
|
+
memoryAvailableMb: z.ZodOptional<z.ZodNumber>;
|
|
406
|
+
cpuCount: z.ZodOptional<z.ZodNumber>;
|
|
407
|
+
uptimeSeconds: z.ZodOptional<z.ZodNumber>;
|
|
408
|
+
nodeVersion: z.ZodOptional<z.ZodString>;
|
|
409
|
+
runningAsUser: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
410
|
+
runningAsUid: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
|
|
411
|
+
version: z.ZodOptional<z.ZodString>;
|
|
412
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
413
|
+
type: z.ZodLiteral<"job.reroute">;
|
|
414
|
+
messageId: z.ZodString;
|
|
415
|
+
jobId: z.ZodString;
|
|
416
|
+
runId: z.ZodString;
|
|
417
|
+
deliveryId: z.ZodString;
|
|
418
|
+
routingKey: z.ZodString;
|
|
419
|
+
event: z.ZodString;
|
|
420
|
+
action: z.ZodNullable<z.ZodString>;
|
|
421
|
+
payload: z.ZodRecord<z.ZodString, z.ZodUnknown>;
|
|
422
|
+
jobName: z.ZodString;
|
|
423
|
+
workflowName: z.ZodString;
|
|
424
|
+
runsOnLabels: z.ZodArray<z.ZodArray<z.ZodString>>;
|
|
425
|
+
excludeLabels: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
426
|
+
triedConnections: z.ZodArray<z.ZodString>;
|
|
427
|
+
maxHops: z.ZodNumber;
|
|
428
|
+
coordinatorId: z.ZodString;
|
|
429
|
+
requestId: z.ZodOptional<z.ZodString>;
|
|
430
|
+
traceId: z.ZodOptional<z.ZodString>;
|
|
431
|
+
jobConfig: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
|
|
432
|
+
repoUrl: z.ZodOptional<z.ZodString>;
|
|
433
|
+
ref: z.ZodOptional<z.ZodString>;
|
|
434
|
+
sha: z.ZodOptional<z.ZodString>;
|
|
435
|
+
provider: z.ZodOptional<z.ZodString>;
|
|
436
|
+
providerContext: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
|
|
437
|
+
sourceTarUrl: z.ZodOptional<z.ZodString>;
|
|
438
|
+
sourceTarHash: z.ZodOptional<z.ZodString>;
|
|
439
|
+
depsUrl: z.ZodOptional<z.ZodString>;
|
|
440
|
+
depsHash: z.ZodOptional<z.ZodString>;
|
|
441
|
+
cloneToken: z.ZodOptional<z.ZodString>;
|
|
442
|
+
encryptedSecrets: z.ZodOptional<z.ZodString>;
|
|
443
|
+
encryptedNamespacedSecrets: z.ZodOptional<z.ZodString>;
|
|
444
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
445
|
+
type: z.ZodLiteral<"job.reroute.ack">;
|
|
446
|
+
messageId: z.ZodString;
|
|
447
|
+
accepted: z.ZodBoolean;
|
|
448
|
+
reason: z.ZodOptional<z.ZodString>;
|
|
449
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
450
|
+
type: z.ZodLiteral<"job.progress">;
|
|
451
|
+
kind: z.ZodEnum<{
|
|
452
|
+
job: "job";
|
|
453
|
+
step: "step";
|
|
454
|
+
}>;
|
|
455
|
+
runId: z.ZodString;
|
|
456
|
+
jobId: z.ZodString;
|
|
457
|
+
jobName: z.ZodString;
|
|
458
|
+
stepIndex: z.ZodNumber;
|
|
459
|
+
stepName: z.ZodString;
|
|
460
|
+
state: z.ZodEnum<{
|
|
461
|
+
success: "success";
|
|
462
|
+
pending: "pending";
|
|
463
|
+
running: "running";
|
|
464
|
+
failed: "failed";
|
|
465
|
+
cancelled: "cancelled";
|
|
466
|
+
cancelling: "cancelling";
|
|
467
|
+
queued: "queued";
|
|
468
|
+
recovering: "recovering";
|
|
469
|
+
skipped: "skipped";
|
|
470
|
+
timed_out_stale: "timed_out_stale";
|
|
471
|
+
drift_dropped: "drift_dropped";
|
|
472
|
+
}>;
|
|
473
|
+
timestamp: z.ZodNumber;
|
|
474
|
+
data: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
|
|
475
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
476
|
+
type: z.ZodLiteral<"peer.job.cancel">;
|
|
477
|
+
runId: z.ZodString;
|
|
478
|
+
jobId: z.ZodOptional<z.ZodString>;
|
|
479
|
+
reason: z.ZodString;
|
|
480
|
+
force: z.ZodOptional<z.ZodBoolean>;
|
|
481
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
482
|
+
type: z.ZodLiteral<"raft.vote.request">;
|
|
483
|
+
term: z.ZodNumber;
|
|
484
|
+
candidateId: z.ZodString;
|
|
485
|
+
lastLogIndex: z.ZodNumber;
|
|
486
|
+
lastLogTerm: z.ZodNumber;
|
|
487
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
488
|
+
type: z.ZodLiteral<"raft.vote.response">;
|
|
489
|
+
term: z.ZodNumber;
|
|
490
|
+
voteGranted: z.ZodBoolean;
|
|
491
|
+
voterId: z.ZodString;
|
|
492
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
493
|
+
type: z.ZodLiteral<"raft.append.entries">;
|
|
494
|
+
term: z.ZodNumber;
|
|
495
|
+
leaderId: z.ZodString;
|
|
496
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
497
|
+
type: z.ZodLiteral<"peer.log.chunk">;
|
|
498
|
+
runId: z.ZodString;
|
|
499
|
+
jobId: z.ZodString;
|
|
500
|
+
stepIndex: z.ZodNumber;
|
|
501
|
+
lines: z.ZodArray<z.ZodObject<{
|
|
502
|
+
text: z.ZodString;
|
|
503
|
+
timestamp: z.ZodNumber;
|
|
504
|
+
stream: z.ZodOptional<z.ZodEnum<{
|
|
505
|
+
stdout: "stdout";
|
|
506
|
+
stderr: "stderr";
|
|
507
|
+
}>>;
|
|
508
|
+
}, z.core.$strip>>;
|
|
509
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
510
|
+
type: z.ZodLiteral<"peer.cache.upload.request">;
|
|
511
|
+
messageId: z.ZodString;
|
|
512
|
+
runId: z.ZodString;
|
|
513
|
+
jobId: z.ZodString;
|
|
514
|
+
cacheType: z.ZodEnum<{
|
|
515
|
+
source: "source";
|
|
516
|
+
deps: "deps";
|
|
517
|
+
}>;
|
|
518
|
+
hash: z.ZodString;
|
|
519
|
+
sizeBytes: z.ZodNumber;
|
|
520
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
521
|
+
type: z.ZodLiteral<"peer.cache.upload.response">;
|
|
522
|
+
messageId: z.ZodString;
|
|
523
|
+
runId: z.ZodString;
|
|
524
|
+
jobId: z.ZodString;
|
|
525
|
+
uploadUrl: z.ZodString;
|
|
526
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
527
|
+
type: z.ZodLiteral<"peer.config.reload">;
|
|
528
|
+
messageId: z.ZodString;
|
|
529
|
+
drain: z.ZodOptional<z.ZodBoolean>;
|
|
530
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
531
|
+
type: z.ZodLiteral<"peer.config.reload.response">;
|
|
532
|
+
messageId: z.ZodString;
|
|
533
|
+
success: z.ZodBoolean;
|
|
534
|
+
version: z.ZodOptional<z.ZodNumber>;
|
|
535
|
+
errors: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
536
|
+
restartRequired: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
537
|
+
fieldsChanged: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
538
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
539
|
+
type: z.ZodLiteral<"peer.leaving">;
|
|
540
|
+
instanceId: z.ZodString;
|
|
541
|
+
term: z.ZodNumber;
|
|
542
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
543
|
+
type: z.ZodLiteral<"peer.agent-token.revoke">;
|
|
544
|
+
tokenId: z.ZodString;
|
|
545
|
+
senderInstanceId: z.ZodString;
|
|
546
|
+
}, z.core.$strip>], "type">;
|
|
547
|
+
/** All peer-to-peer messages (inbound to this node). */
|
|
548
|
+
export declare const peerFromPeerMessageSchema: z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
549
|
+
type: z.ZodLiteral<"peer.hello">;
|
|
550
|
+
ephemeralPublicKey: z.ZodString;
|
|
551
|
+
nonce: z.ZodString;
|
|
552
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
553
|
+
type: z.ZodLiteral<"peer.hello.response">;
|
|
554
|
+
ephemeralPublicKey: z.ZodString;
|
|
555
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
556
|
+
type: z.ZodLiteral<"peer.auth.request">;
|
|
557
|
+
instanceId: z.ZodString;
|
|
558
|
+
token: z.ZodOptional<z.ZodString>;
|
|
559
|
+
proof: z.ZodOptional<z.ZodString>;
|
|
560
|
+
protocolVersion: z.ZodNumber;
|
|
561
|
+
softwareVersion: z.ZodOptional<z.ZodString>;
|
|
562
|
+
role: z.ZodOptional<z.ZodEnum<{
|
|
563
|
+
coordinator: "coordinator";
|
|
564
|
+
worker: "worker";
|
|
565
|
+
}>>;
|
|
566
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
567
|
+
type: z.ZodLiteral<"peer.auth.response">;
|
|
568
|
+
accepted: z.ZodBoolean;
|
|
569
|
+
instanceId: z.ZodOptional<z.ZodString>;
|
|
570
|
+
reason: z.ZodOptional<z.ZodString>;
|
|
571
|
+
sessionCredential: z.ZodOptional<z.ZodString>;
|
|
572
|
+
role: z.ZodOptional<z.ZodString>;
|
|
573
|
+
softwareVersion: z.ZodOptional<z.ZodString>;
|
|
574
|
+
agents: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
575
|
+
agentId: z.ZodString;
|
|
576
|
+
labels: z.ZodArray<z.ZodString>;
|
|
577
|
+
activeJobs: z.ZodNumber;
|
|
578
|
+
maxConcurrency: z.ZodNumber;
|
|
579
|
+
platform: z.ZodString;
|
|
580
|
+
arch: z.ZodString;
|
|
581
|
+
mandatoryLabels: z.ZodDefault<z.ZodOptional<z.ZodArray<z.ZodString>>>;
|
|
582
|
+
}, z.core.$strip>>>;
|
|
583
|
+
scalerCapacity: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
584
|
+
name: z.ZodOptional<z.ZodString>;
|
|
585
|
+
type: z.ZodOptional<z.ZodString>;
|
|
586
|
+
labelSets: z.ZodArray<z.ZodArray<z.ZodString>>;
|
|
587
|
+
maxAgents: z.ZodNumber;
|
|
588
|
+
activeCount: z.ZodNumber;
|
|
589
|
+
mandatoryLabels: z.ZodDefault<z.ZodOptional<z.ZodArray<z.ZodString>>>;
|
|
590
|
+
}, z.core.$strip>>>;
|
|
591
|
+
capabilities: z.ZodOptional<z.ZodObject<{
|
|
592
|
+
s3LogAccess: z.ZodBoolean;
|
|
593
|
+
logRoutingOverride: z.ZodOptional<z.ZodEnum<{
|
|
594
|
+
coordinator: "coordinator";
|
|
595
|
+
direct: "direct";
|
|
596
|
+
}>>;
|
|
597
|
+
}, z.core.$strip>>;
|
|
598
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
599
|
+
type: z.ZodLiteral<"peer.heartbeat">;
|
|
600
|
+
instanceId: z.ZodString;
|
|
601
|
+
term: z.ZodNumber;
|
|
602
|
+
leaderId: z.ZodNullable<z.ZodString>;
|
|
603
|
+
draining: z.ZodBoolean;
|
|
604
|
+
agents: z.ZodArray<z.ZodObject<{
|
|
605
|
+
agentId: z.ZodString;
|
|
606
|
+
labels: z.ZodArray<z.ZodString>;
|
|
607
|
+
activeJobs: z.ZodNumber;
|
|
608
|
+
maxConcurrency: z.ZodNumber;
|
|
609
|
+
platform: z.ZodString;
|
|
610
|
+
arch: z.ZodString;
|
|
611
|
+
mandatoryLabels: z.ZodDefault<z.ZodOptional<z.ZodArray<z.ZodString>>>;
|
|
612
|
+
}, z.core.$strip>>;
|
|
613
|
+
capabilities: z.ZodObject<{
|
|
614
|
+
s3LogAccess: z.ZodBoolean;
|
|
615
|
+
logRoutingOverride: z.ZodOptional<z.ZodEnum<{
|
|
616
|
+
coordinator: "coordinator";
|
|
617
|
+
direct: "direct";
|
|
618
|
+
}>>;
|
|
619
|
+
}, z.core.$strip>;
|
|
620
|
+
scalerCapacity: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
621
|
+
name: z.ZodOptional<z.ZodString>;
|
|
622
|
+
type: z.ZodOptional<z.ZodString>;
|
|
623
|
+
labelSets: z.ZodArray<z.ZodArray<z.ZodString>>;
|
|
624
|
+
maxAgents: z.ZodNumber;
|
|
625
|
+
activeCount: z.ZodNumber;
|
|
626
|
+
mandatoryLabels: z.ZodDefault<z.ZodOptional<z.ZodArray<z.ZodString>>>;
|
|
627
|
+
}, z.core.$strip>>>;
|
|
628
|
+
configVersion: z.ZodOptional<z.ZodNumber>;
|
|
629
|
+
registryVersion: z.ZodOptional<z.ZodNumber>;
|
|
630
|
+
timestamp: z.ZodNumber;
|
|
631
|
+
hostname: z.ZodOptional<z.ZodString>;
|
|
632
|
+
osRelease: z.ZodOptional<z.ZodString>;
|
|
633
|
+
totalMemoryMb: z.ZodOptional<z.ZodNumber>;
|
|
634
|
+
memoryUsedMb: z.ZodOptional<z.ZodNumber>;
|
|
635
|
+
memoryAvailableMb: z.ZodOptional<z.ZodNumber>;
|
|
636
|
+
cpuCount: z.ZodOptional<z.ZodNumber>;
|
|
637
|
+
uptimeSeconds: z.ZodOptional<z.ZodNumber>;
|
|
638
|
+
nodeVersion: z.ZodOptional<z.ZodString>;
|
|
639
|
+
runningAsUser: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
640
|
+
runningAsUid: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
|
|
641
|
+
version: z.ZodOptional<z.ZodString>;
|
|
642
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
643
|
+
type: z.ZodLiteral<"job.reroute">;
|
|
644
|
+
messageId: z.ZodString;
|
|
645
|
+
jobId: z.ZodString;
|
|
646
|
+
runId: z.ZodString;
|
|
647
|
+
deliveryId: z.ZodString;
|
|
648
|
+
routingKey: z.ZodString;
|
|
649
|
+
event: z.ZodString;
|
|
650
|
+
action: z.ZodNullable<z.ZodString>;
|
|
651
|
+
payload: z.ZodRecord<z.ZodString, z.ZodUnknown>;
|
|
652
|
+
jobName: z.ZodString;
|
|
653
|
+
workflowName: z.ZodString;
|
|
654
|
+
runsOnLabels: z.ZodArray<z.ZodArray<z.ZodString>>;
|
|
655
|
+
excludeLabels: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
656
|
+
triedConnections: z.ZodArray<z.ZodString>;
|
|
657
|
+
maxHops: z.ZodNumber;
|
|
658
|
+
coordinatorId: z.ZodString;
|
|
659
|
+
requestId: z.ZodOptional<z.ZodString>;
|
|
660
|
+
traceId: z.ZodOptional<z.ZodString>;
|
|
661
|
+
jobConfig: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
|
|
662
|
+
repoUrl: z.ZodOptional<z.ZodString>;
|
|
663
|
+
ref: z.ZodOptional<z.ZodString>;
|
|
664
|
+
sha: z.ZodOptional<z.ZodString>;
|
|
665
|
+
provider: z.ZodOptional<z.ZodString>;
|
|
666
|
+
providerContext: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
|
|
667
|
+
sourceTarUrl: z.ZodOptional<z.ZodString>;
|
|
668
|
+
sourceTarHash: z.ZodOptional<z.ZodString>;
|
|
669
|
+
depsUrl: z.ZodOptional<z.ZodString>;
|
|
670
|
+
depsHash: z.ZodOptional<z.ZodString>;
|
|
671
|
+
cloneToken: z.ZodOptional<z.ZodString>;
|
|
672
|
+
encryptedSecrets: z.ZodOptional<z.ZodString>;
|
|
673
|
+
encryptedNamespacedSecrets: z.ZodOptional<z.ZodString>;
|
|
674
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
675
|
+
type: z.ZodLiteral<"job.reroute.ack">;
|
|
676
|
+
messageId: z.ZodString;
|
|
677
|
+
accepted: z.ZodBoolean;
|
|
678
|
+
reason: z.ZodOptional<z.ZodString>;
|
|
679
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
680
|
+
type: z.ZodLiteral<"job.progress">;
|
|
681
|
+
kind: z.ZodEnum<{
|
|
682
|
+
job: "job";
|
|
683
|
+
step: "step";
|
|
684
|
+
}>;
|
|
685
|
+
runId: z.ZodString;
|
|
686
|
+
jobId: z.ZodString;
|
|
687
|
+
jobName: z.ZodString;
|
|
688
|
+
stepIndex: z.ZodNumber;
|
|
689
|
+
stepName: z.ZodString;
|
|
690
|
+
state: z.ZodEnum<{
|
|
691
|
+
success: "success";
|
|
692
|
+
pending: "pending";
|
|
693
|
+
running: "running";
|
|
694
|
+
failed: "failed";
|
|
695
|
+
cancelled: "cancelled";
|
|
696
|
+
cancelling: "cancelling";
|
|
697
|
+
queued: "queued";
|
|
698
|
+
recovering: "recovering";
|
|
699
|
+
skipped: "skipped";
|
|
700
|
+
timed_out_stale: "timed_out_stale";
|
|
701
|
+
drift_dropped: "drift_dropped";
|
|
702
|
+
}>;
|
|
703
|
+
timestamp: z.ZodNumber;
|
|
704
|
+
data: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
|
|
705
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
706
|
+
type: z.ZodLiteral<"peer.job.cancel">;
|
|
707
|
+
runId: z.ZodString;
|
|
708
|
+
jobId: z.ZodOptional<z.ZodString>;
|
|
709
|
+
reason: z.ZodString;
|
|
710
|
+
force: z.ZodOptional<z.ZodBoolean>;
|
|
711
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
712
|
+
type: z.ZodLiteral<"raft.vote.request">;
|
|
713
|
+
term: z.ZodNumber;
|
|
714
|
+
candidateId: z.ZodString;
|
|
715
|
+
lastLogIndex: z.ZodNumber;
|
|
716
|
+
lastLogTerm: z.ZodNumber;
|
|
717
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
718
|
+
type: z.ZodLiteral<"raft.vote.response">;
|
|
719
|
+
term: z.ZodNumber;
|
|
720
|
+
voteGranted: z.ZodBoolean;
|
|
721
|
+
voterId: z.ZodString;
|
|
722
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
723
|
+
type: z.ZodLiteral<"raft.append.entries">;
|
|
724
|
+
term: z.ZodNumber;
|
|
725
|
+
leaderId: z.ZodString;
|
|
726
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
727
|
+
type: z.ZodLiteral<"peer.log.chunk">;
|
|
728
|
+
runId: z.ZodString;
|
|
729
|
+
jobId: z.ZodString;
|
|
730
|
+
stepIndex: z.ZodNumber;
|
|
731
|
+
lines: z.ZodArray<z.ZodObject<{
|
|
732
|
+
text: z.ZodString;
|
|
733
|
+
timestamp: z.ZodNumber;
|
|
734
|
+
stream: z.ZodOptional<z.ZodEnum<{
|
|
735
|
+
stdout: "stdout";
|
|
736
|
+
stderr: "stderr";
|
|
737
|
+
}>>;
|
|
738
|
+
}, z.core.$strip>>;
|
|
739
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
740
|
+
type: z.ZodLiteral<"peer.cache.upload.request">;
|
|
741
|
+
messageId: z.ZodString;
|
|
742
|
+
runId: z.ZodString;
|
|
743
|
+
jobId: z.ZodString;
|
|
744
|
+
cacheType: z.ZodEnum<{
|
|
745
|
+
source: "source";
|
|
746
|
+
deps: "deps";
|
|
747
|
+
}>;
|
|
748
|
+
hash: z.ZodString;
|
|
749
|
+
sizeBytes: z.ZodNumber;
|
|
750
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
751
|
+
type: z.ZodLiteral<"peer.cache.upload.response">;
|
|
752
|
+
messageId: z.ZodString;
|
|
753
|
+
runId: z.ZodString;
|
|
754
|
+
jobId: z.ZodString;
|
|
755
|
+
uploadUrl: z.ZodString;
|
|
756
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
757
|
+
type: z.ZodLiteral<"peer.config.reload">;
|
|
758
|
+
messageId: z.ZodString;
|
|
759
|
+
drain: z.ZodOptional<z.ZodBoolean>;
|
|
760
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
761
|
+
type: z.ZodLiteral<"peer.config.reload.response">;
|
|
762
|
+
messageId: z.ZodString;
|
|
763
|
+
success: z.ZodBoolean;
|
|
764
|
+
version: z.ZodOptional<z.ZodNumber>;
|
|
765
|
+
errors: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
766
|
+
restartRequired: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
767
|
+
fieldsChanged: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
768
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
769
|
+
type: z.ZodLiteral<"peer.leaving">;
|
|
770
|
+
instanceId: z.ZodString;
|
|
771
|
+
term: z.ZodNumber;
|
|
772
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
773
|
+
type: z.ZodLiteral<"peer.agent-token.revoke">;
|
|
774
|
+
tokenId: z.ZodString;
|
|
775
|
+
senderInstanceId: z.ZodString;
|
|
776
|
+
}, z.core.$strip>], "type">;
|
|
777
|
+
export type PeerCapabilities = z.infer<typeof peerCapabilitiesSchema>;
|
|
778
|
+
export type ScalerCapacitySummary = z.infer<typeof scalerCapacitySummarySchema>;
|
|
779
|
+
export type PeerHeartbeat = z.infer<typeof peerHeartbeatSchema>;
|
|
780
|
+
export type JobReroute = z.infer<typeof jobRerouteSchema>;
|
|
781
|
+
export type JobProgress = z.infer<typeof jobProgressSchema>;
|
|
782
|
+
export type PeerJobCancel = z.infer<typeof peerJobCancelSchema>;
|
|
783
|
+
export type RaftVoteRequest = z.infer<typeof raftVoteRequestSchema>;
|
|
784
|
+
export type RaftVoteResponse = z.infer<typeof raftVoteResponseSchema>;
|
|
785
|
+
export type RaftAppendEntries = z.infer<typeof raftAppendEntriesSchema>;
|
|
786
|
+
export type PeerLogChunk = z.infer<typeof peerLogChunkSchema>;
|
|
787
|
+
export type PeerCacheUploadRequest = z.infer<typeof peerCacheUploadRequestSchema>;
|
|
788
|
+
export type PeerCacheUploadResponse = z.infer<typeof peerCacheUploadResponseSchema>;
|
|
789
|
+
export type PeerConfigReload = z.infer<typeof peerConfigReloadSchema>;
|
|
790
|
+
export type PeerConfigReloadResponse = z.infer<typeof peerConfigReloadResponseSchema>;
|
|
791
|
+
export type PeerLeaving = z.infer<typeof peerLeavingSchema>;
|
|
792
|
+
export type PeerAgentTokenRevoke = z.infer<typeof peerAgentTokenRevokeSchema>;
|
|
793
|
+
export type PeerToPeerMessage = z.infer<typeof peerToPeerMessageSchema>;
|
|
794
|
+
export {};
|
|
795
|
+
//# sourceMappingURL=peer.d.ts.map
|