Skip to content

Commit 899da36

Browse files
swanandxgz
authored andcommitted
pipeline-manager: fix checkpoint sync docs
Signed-off-by: Swanand Mulay <73115739+swanandx@users.noreply.github.com>
1 parent 2c42c5a commit 899da36

File tree

4 files changed

+84
-8
lines changed

4 files changed

+84
-8
lines changed

crates/pipeline-manager/src/api/endpoints/pipeline_interaction.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1126,7 +1126,7 @@ pub(crate) async fn get_checkpoint_status(
11261126
(status = OK
11271127
, description = "Checkpoint sync status retrieved successfully"
11281128
, content_type = "application/json"
1129-
, body = CheckpointStatus),
1129+
, body = CheckpointSyncStatus),
11301130
(status = NOT_FOUND
11311131
, description = "Pipeline with that name does not exist"
11321132
, body = ErrorResponse

crates/pipeline-manager/src/api/main.rs

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -425,8 +425,10 @@ It contains the following fields:
425425
feldera_types::completion_token::CompletionStatus,
426426
feldera_types::completion_token::CompletionStatusResponse,
427427
feldera_types::checkpoint::CheckpointStatus,
428+
feldera_types::checkpoint::CheckpointSyncStatus,
428429
feldera_types::checkpoint::CheckpointResponse,
429430
feldera_types::checkpoint::CheckpointFailure,
431+
feldera_types::checkpoint::CheckpointSyncFailure,
430432
feldera_types::checkpoint::CheckpointMetadata,
431433
feldera_types::transaction::StartTransactionResponse,
432434
feldera_types::transaction::CommitProgressSummary,

docs.feldera.com/docs/pipelines/checkpoint-sync.md

Lines changed: 35 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -283,28 +283,57 @@ The status of the sync operation can be checked by making a `GET` request to:
283283
curl http://localhost/v0/pipelines/{PIPELINE_NAME}/checkpoint/sync_status
284284
```
285285

286+
### Response fields
287+
288+
| Field | Type | Description |
289+
| ---------- | --------------- | ------------------------------------------------------------------------------------------------------------ |
290+
| `success` | `uuid \| null` | UUID of the most recently successful manually triggered checkpoint sync (`POST /checkpoint/sync`). |
291+
| `failure` | `object \| null`| Details of the most recently failed manually triggered checkpoint sync. Contains `uuid` and `error` fields. |
292+
| `periodic` | `uuid \| null` | UUID of the most recently successful automatic periodic checkpoint sync (configured via `push_interval`). |
293+
294+
`success` and `periodic` track different sync mechanisms:
295+
- `success` is updated only by manual syncs triggered via `POST /checkpoint/sync`.
296+
- `periodic` is updated only by automatic syncs configured via `push_interval`.
297+
286298
### Response examples
287299

288-
**In Progress:**
300+
**No syncs yet:**
289301

290302
```json
291-
{ "success": null, "failure": null }
303+
{ "success": null, "failure": null, "periodic": null }
292304
```
293305

294-
**Success:**
306+
**Successful manual sync:**
295307

296308
```json
297-
{ "success": "019779b4-8760-75f2-bdf0-71b825e63610", "failure": null }
309+
{ "success": "019779b4-8760-75f2-bdf0-71b825e63610", "failure": null, "periodic": null }
298310
```
299311

300-
**Failure:**
312+
**Failed manual sync:**
301313

302314
```json
303315
{
304316
"success": null,
305317
"failure": {
306318
"uuid": "019779c1-8317-7a71-bd78-7b971f4a3c43",
307319
"error": "Error pushing checkpoint to object store: ... SignatureDoesNotMatch ..."
308-
}
320+
},
321+
"periodic": null
322+
}
323+
```
324+
325+
**Automatic periodic sync only (no manual syncs):**
326+
327+
```json
328+
{ "success": null, "failure": null, "periodic": "019779c1-8317-7a71-bd78-7b971f4a3c43" }
329+
```
330+
331+
**Both manual and automatic syncs:**
332+
333+
```json
334+
{
335+
"success": "019779b4-8760-75f2-bdf0-71b825e63610",
336+
"failure": null,
337+
"periodic": "019779c1-8317-7a71-bd78-7b971f4a3c43"
309338
}
310339
```

openapi.json

Lines changed: 46 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2310,7 +2310,7 @@
23102310
"content": {
23112311
"application/json": {
23122312
"schema": {
2313-
"$ref": "#/components/schemas/CheckpointStatus"
2313+
"$ref": "#/components/schemas/CheckpointSyncStatus"
23142314
}
23152315
}
23162316
}
@@ -6829,6 +6829,51 @@
68296829
}
68306830
}
68316831
},
6832+
"CheckpointSyncFailure": {
6833+
"type": "object",
6834+
"description": "Information about a failed checkpoint sync.",
6835+
"required": [
6836+
"uuid",
6837+
"error"
6838+
],
6839+
"properties": {
6840+
"error": {
6841+
"type": "string",
6842+
"description": "Error message associated with the failure."
6843+
},
6844+
"uuid": {
6845+
"type": "string",
6846+
"format": "uuid",
6847+
"description": "UUID of the failed checkpoint."
6848+
}
6849+
}
6850+
},
6851+
"CheckpointSyncStatus": {
6852+
"type": "object",
6853+
"description": "Checkpoint status returned by the `/checkpoint/sync_status` endpoint.",
6854+
"properties": {
6855+
"failure": {
6856+
"allOf": [
6857+
{
6858+
"$ref": "#/components/schemas/CheckpointSyncFailure"
6859+
}
6860+
],
6861+
"nullable": true
6862+
},
6863+
"periodic": {
6864+
"type": "string",
6865+
"format": "uuid",
6866+
"description": "Most recently successful automated periodic checkpoint sync.",
6867+
"nullable": true
6868+
},
6869+
"success": {
6870+
"type": "string",
6871+
"format": "uuid",
6872+
"description": "Most recently successful checkpoint sync.",
6873+
"nullable": true
6874+
}
6875+
}
6876+
},
68326877
"Chunk": {
68336878
"type": "object",
68346879
"description": "A set of updates to a SQL table or view.\n\nThe `sequence_number` field stores the offset of the chunk relative to the\nstart of the stream and can be used to implement reliable delivery.\nThe payload is stored in the `bin_data`, `text_data`, or `json_data` field\ndepending on the data format used.",

0 commit comments

Comments
 (0)