feat: bind job events to command leases

This commit is contained in:
2026-08-13 06:45:54 +00:00
parent 4ec852014d
commit 03b6751d42
12 changed files with 71 additions and 17 deletions
+1 -1
View File
@@ -1,6 +1,6 @@
{
"protocolVersion": {
"major": 1,
"major": 2,
"minor": 0
},
"messageId": "2fc6a524-84cd-47ab-bd73-30d463b7c43f",
+1 -1
View File
@@ -1,6 +1,6 @@
{
"protocolVersion": {
"major": 1,
"major": 2,
"minor": 0
},
"messageId": "9c62fcda-5f83-4286-80cf-a628001e44d3",
+1 -1
View File
@@ -1,6 +1,6 @@
{
"protocolVersion": {
"major": 1,
"major": 2,
"minor": 0
},
"messageId": "7c4a3534-c754-4c4d-a12e-1a1047e3f96e",
+1 -1
View File
@@ -1,6 +1,6 @@
{
"protocolVersion": {
"major": 1,
"major": 2,
"minor": 0
},
"messageId": "56aae470-d1c9-402a-bf14-d7a28ff8998f",
+1 -1
View File
@@ -1,6 +1,6 @@
{
"protocolVersion": {
"major": 1,
"major": 2,
"minor": 0
},
"messageId": "830626f3-dc76-46f0-a9b1-a6fb61b3ba73",
+1 -1
View File
@@ -1,6 +1,6 @@
{
"protocolVersion": {
"major": 1,
"major": 2,
"minor": 0
},
"messageId": "d00def27-cde1-43b7-a6af-ee3582d0c7c1",
+2 -1
View File
@@ -1,6 +1,6 @@
{
"protocolVersion": {
"major": 1,
"major": 2,
"minor": 0
},
"messageId": "f337dc9c-84b8-42c6-a2ae-52f8f91258a8",
@@ -8,6 +8,7 @@
"sentAt": "2026-07-22T12:08:00Z",
"jobEvent": {
"eventId": "ecfbd79e-e0fe-41da-ab77-012cde0ed53f",
"commandId": "6bfccbf4-866f-46fe-bf67-d8943c1ece91",
"jobId": "fd6844d0-ed76-475e-8375-2f98d8eea470",
"sequence": "23",
"jobRevision": "9",
+2 -1
View File
@@ -1,6 +1,6 @@
{
"protocolVersion": {
"major": 1,
"major": 2,
"minor": 0
},
"messageId": "44b64096-cd58-4f49-bae4-d829f50f787c",
@@ -8,6 +8,7 @@
"sentAt": "2026-07-22T12:04:00Z",
"jobEvent": {
"eventId": "18cf6a34-b0a5-429e-b56a-9228b2dca640",
"commandId": "6bfccbf4-866f-46fe-bf67-d8943c1ece91",
"jobId": "fd6844d0-ed76-475e-8375-2f98d8eea470",
"sequence": "17",
"jobRevision": "6",
+34
View File
@@ -0,0 +1,34 @@
{
"protocolVersion": {
"major": 2
},
"messageId": "4be5df55-3d95-4f60-8f6b-1cfd0b64cfbb",
"sentAt": "2026-08-13T06:00:00Z",
"command": {
"commandId": "94b4f73f-31a8-426b-8511-12b91987f1b4",
"createdAt": "2026-08-13T06:00:00Z",
"reconcileJob": {
"authoritativeJob": {
"definition": {
"jobId": "3173ae0d-ecc4-4113-a659-7897aac6c66f",
"idempotencyKey": "55b6d968-e20d-444b-8fae-17914d15fdf5",
"operation": "JOB_OPERATION_ARCHIVE",
"resourceDisplayName": "example",
"createdAt": "2026-08-13T05:00:00Z",
"transfer": {
"sourceClientId": "cache-1",
"targetClientId": "archive-1",
"routeId": "route-example"
}
},
"state": "JOB_STATE_RUNNING",
"revision": "12"
},
"authoritativeLastEventSequence": "12",
"supersededCommandIds": [
"6d4ab7f8-2ff0-47d8-8c7c-45a67dce8535"
],
"reason": "control cursor is authoritative after stale event replay"
}
}
}
+2 -2
View File
@@ -1,13 +1,13 @@
{
"protocolVersion": {
"major": 1,
"major": 2,
"minor": 0
},
"messageId": "0d6d31f8-1242-4a40-a261-433897102fe4",
"sentAt": "2026-07-22T12:00:00Z",
"registerRequest": {
"protocolVersion": {
"major": 1,
"major": 2,
"minor": 0
},
"client": {