Resources / Scenario
Scenario
An incident kept as a permanent test (spec 0047 section 6.4): a small reference to the recorded slice of the object graph on the failing Intent's dependency path, with its provider read-backs and probe results and every secret stripped. The slice itself is a compressed document in the platform bucket, never state in the store.
Overview
| API | platform.etorm.com/v1alpha1 |
| Resource | scenarios (cluster-scoped inside its cluster) |
| Short names | scn |
| Available in | the platform only |
| Status | written by a controller through /status |
Minimal example
apiVersion: platform.etorm.com/v1alpha1
kind: Scenario
metadata:
name: example
spec:
incidentRef:
name: "<name>"
intent: "<intent>"
dedupKey: "<dedupKey>"
blob:
bucket: "<bucket>"
key: "<key>"
sha256: "<sha256>"
bytes: 1
Spec
| Field | Type | Required | Default | Allowed | Description |
incidentRef | object | yes | | | The first Incident that made this scenario. |
incidentRef.name | string | yes | | | Name of the Incident. |
incidentRef.cluster | string | | "platform" | | Its cluster. |
intent | string | yes | | up to 63 characters | The Intent that failed. |
dedupKey | string | yes | | up to 64 characters | The failing link plus the sorted kinds and reasons of the probable causes, hashed: the same cause is one scenario however many incidents it opens. |
expect | string (one of) | | "expected-failing" | pass, expected-failing | expected-failing while the incident is open (it is replayed and reported, and blocks no release); pass once it is fixed. |
blob | object | yes | | | Where the recorded slice is. |
blob.bucket | string | yes | | | The platform bucket. |
blob.key | string | yes | | | The object key. |
blob.sha256 | string | yes | | | Digest of the stored (compressed) bytes. |
blob.bytes | integer | yes | | at most 1048576 | Size of the stored bytes (at most 1 MiB). |
blob.encoding | string (one of) | | "deflate" | deflate | How the JSON document is compressed. |
Status
| Field | Type | Required | Default | Allowed | Description |
state | string (one of) | | | Open, Fixed | Open while the incident is open; Fixed once it has resolved. |
incidents | list of string | | | | Every later incident with the same key. |
fixedBy | string | | | | The commit of the active release when the incident resolved. |
fixedAt | integer | | | | Unix time it was fixed. |
conditions | list of object | | | | Ready (the slice is stored). |
conditions[].type | string | | | | Ready. |
conditions[].status | string | | | | True, False or Unknown. |
Columns in listings
| Column | From |
|---|
| Intent | .spec.intent |
| Expect | .spec.expect |
| State | .status.state |
| Fixed-By | .status.fixedBy |
All resources