deploy.cloudrun.rollback ​
Restore Cloud Run traffic to a previously stable revision.
Overview ​
| Property | Value |
|---|---|
| Workflow type | Dag |
| Library | App-deployments |
| Version | 1.0 |
Input Schema ​
| Field | Type | Required | Default | Description |
|---|---|---|---|---|
organization_uuid | uuid | Yes | — | Organization UUID. |
deployment_target_uuid | uuid | Yes | — | Deployment target UUID. |
rollout_uuid | uuid | No | — | Rollout UUID to roll back. |
connection_uuid | uuid | Yes | — | GCP connection UUID. |
project_id | string | No | — | GCP project override. |
region | string | Yes | — | Cloud Run region. |
service_name | string | Yes | — | Cloud Run service name. |
stable_revision | string | Yes | — | Revision that should receive traffic. |
candidate_revision | string | No | — | Candidate revision being rolled back. |
reason | string | No | — | Rollback reason. |
Output Schema ​
| Field | Type | Required | Default | Description |
|---|---|---|---|---|
deployment_target_uuid | uuid | No | — | Target UUID. |
rollout_uuid | uuid | No | — | Rollout UUID. |
service_name | string | No | — | Cloud Run service name. |
stable_revision | string | No | — | Revision restored to 100 percent. |
candidate_revision | string | No | — | Candidate revision removed from traffic. |
traffic | json | No | — | Final traffic split. |
status | string | No | — | Rollback status. |
wait_stable_revision | json | No | — | Result of wait_stable_revision DAG step. |
restore_stable_traffic | json | No | — | Result of restore_stable_traffic DAG step. |
failure_reason | string | No | — | Engine failure reason. |
failure_type | string | No | — | — |
failed_action | string | No | — | — |
failed_step | json | No | — | Failed DAG step envelope. |
failed_layer | json | No | — | Failed DAG layer envelope. |
failed_at_state | string | No | — | State where failure occurred. |
error | string | No | — | Error message. |
error_type | string | No | — | Error class. |
DAG Layers ​
| # | Layer | Steps | Compensation |
|---|---|---|---|
| 1 | verify_stable_revision | gcp.run.service.wait-ready | — |
| 2 | restore_traffic | gcp.run.service.update-traffic | — |
Execution Flow ​
Sub-workflows ​
| Sub-workflow | Step name |
|---|---|
gcp.run.service.wait-ready | wait_stable_revision |
gcp.run.service.update-traffic | restore_stable_traffic |
API Usage ​
bash
POST /api/workflows/start
Content-Type: application/json
{
"workflow_type": "deploy.cloudrun.rollback",
"initial_data": {
"organization_uuid": "value",
"deployment_target_uuid": "value",
"connection_uuid": "value",
"region": "value"
}
}