From ccc199ad86cba12b03eb6adc8a1cc763a5ef5458 Mon Sep 17 00:00:00 2001 From: Pierre Curzola Date: Fri, 22 May 2026 18:07:52 +0200 Subject: [PATCH] feat: Add database continuous backup events for healthy, delayed, and stale states --- _scalingo_api/events.md | 144 ++++++++++++++++++++++++++++++++++++++++ 1 file changed, 144 insertions(+) diff --git a/_scalingo_api/events.md b/_scalingo_api/events.md index 420a172..b28c3fc 100644 --- a/_scalingo_api/events.md +++ b/_scalingo_api/events.md @@ -2045,6 +2045,150 @@ Example object: --- row --- +* **Database Continuous Backup Healthy** + +_When:_ Point-in-time recovery is available and restore points are up to date +`type=database_continuousbackup_healthy` + +{:.table} +| field | type | description | +| ------------------------------- | -------- | ------------------------------------------------------------------ | +| addon_name | string | The related addon name | +| resource_id | string | The related addon resource ID | +| addon_uuid | string | The related addon UUID | +| status | string | Continuous backup status. Possible values: `healthy`, `pgbackrest_error`, `wal_error` | +| error | string or null | Error message returned by the continuous backup checker | +| recoverable | boolean | Whether point-in-time recovery is currently available | +| checked_at | datetime | The date and time when the continuous backup status was checked | +| unrecoverable_duration_seconds | integer | Seconds elapsed since the resource last became unrecoverable | + +||| col ||| + +Example object: + +```json +{ + "id": "682ee9400d6f86026b179c53", + "created_at": "2026-05-22T08:00:01.103Z", + "type": "database_continuousbackup_healthy", + "app_id": "649e9d0389bca600016ea61b", + "app_name": "sample-go-martini", + "user": { + "username": "scalingo-platform", + "email": "deploy@scalingo.com", + "id": "us-b32ca09d-1608-4e6f-8f14-302b447b0e14" + }, + "type_data": { + "addon_name": "PostgreSQL", + "resource_id": "sample-go-martini-6184", + "addon_uuid": "ad-b48f347e-2e3d-4b48-8dee-40eed0539ee1", + "status": "healthy", + "error": null, + "recoverable": true, + "checked_at": "2026-05-22T08:00:00.000Z", + "unrecoverable_duration_seconds": 0 + } +} +``` + +--- row --- + +* **Database Continuous Backup Delayed** + +_When:_ The latest restorable point is more than 12 hours behind +`type=database_continuousbackup_delayed` + +{:.table} +| field | type | description | +| ------------------------------- | -------- | ------------------------------------------------------------------ | +| addon_name | string | The related addon name | +| resource_id | string | The related addon resource ID | +| addon_uuid | string | The related addon UUID | +| status | string | Continuous backup status. Possible values: `healthy`, `pgbackrest_error`, `wal_error` | +| error | string or null | Error message returned by the continuous backup checker | +| recoverable | boolean | Whether point-in-time recovery is currently available | +| checked_at | datetime | The date and time when the continuous backup status was checked | +| unrecoverable_duration_seconds | integer | Seconds elapsed since the resource last became unrecoverable | + +||| col ||| + +Example object: + +```json +{ + "id": "682ee9400d6f86026b179c54", + "created_at": "2026-05-22T08:00:01.103Z", + "type": "database_continuousbackup_delayed", + "app_id": "649e9d0389bca600016ea61b", + "app_name": "sample-go-martini", + "user": { + "username": "scalingo-platform", + "email": "deploy@scalingo.com", + "id": "us-b32ca09d-1608-4e6f-8f14-302b447b0e14" + }, + "type_data": { + "addon_name": "PostgreSQL", + "resource_id": "sample-go-martini-6184", + "addon_uuid": "ad-b48f347e-2e3d-4b48-8dee-40eed0539ee1", + "status": "pgbackrest_error", + "error": "pgBackRest archive-push has been failing for 12h", + "recoverable": false, + "checked_at": "2026-05-22T08:00:00.000Z", + "unrecoverable_duration_seconds": 43201 + } +} +``` + +--- row --- + +* **Database Continuous Backup Stale** + +_When:_ The latest restorable point is more than 24 hours behind +`type=database_continuousbackup_stale` + +{:.table} +| field | type | description | +| ------------------------------- | -------- | ------------------------------------------------------------------ | +| addon_name | string | The related addon name | +| resource_id | string | The related addon resource ID | +| addon_uuid | string | The related addon UUID | +| status | string | Continuous backup status. Possible values: `healthy`, `pgbackrest_error`, `wal_error` | +| error | string or null | Error message returned by the continuous backup checker | +| recoverable | boolean | Whether point-in-time recovery is currently available | +| checked_at | datetime | The date and time when the continuous backup status was checked | +| unrecoverable_duration_seconds | integer | Seconds elapsed since the resource last became unrecoverable | + +||| col ||| + +Example object: + +```json +{ + "id": "682ee9400d6f86026b179c55", + "created_at": "2026-05-22T08:00:01.103Z", + "type": "database_continuousbackup_stale", + "app_id": "649e9d0389bca600016ea61b", + "app_name": "sample-go-martini", + "user": { + "username": "scalingo-platform", + "email": "deploy@scalingo.com", + "id": "us-b32ca09d-1608-4e6f-8f14-302b447b0e14" + }, + "type_data": { + "addon_name": "PostgreSQL", + "resource_id": "sample-go-martini-6184", + "addon_uuid": "ad-b48f347e-2e3d-4b48-8dee-40eed0539ee1", + "status": "wal_error", + "error": "WAL archiving has been stale for more than 24h", + "recoverable": false, + "checked_at": "2026-05-22T08:00:00.000Z", + "unrecoverable_duration_seconds": 86401 + } +} +``` + +--- row --- + * **New Project Created** _When:_ A new project has been created