-
Notifications
You must be signed in to change notification settings - Fork 22
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Signed-off-by: Andrea Frittoli <andrea.frittoli@gmail.com>
- Loading branch information
Showing
5 changed files
with
164 additions
and
3 deletions.
There are no files selected for viewing
File renamed without changes.
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,157 @@ | ||
<!-- | ||
--- | ||
linkTitle: "Continuous Operations Events" | ||
weight: 70 | ||
description: > | ||
Continuous Operations Events | ||
--- | ||
--> | ||
# Continuous Operations Events | ||
|
||
Continuous Operations events are related to the operation of services deployed in target environments, tracking of incidents and their remediation. Incidents, and their resolution, can be detected by a number of different actors, like the end-user, a quality gate, a monitoring system, an SRE through a ticketing system or event the service itself. | ||
Multiple events may be associated to the same incident as well as its resolution, coming from diverse sources. | ||
|
||
## Subjects | ||
|
||
This specification defines two subjects in this stage: `environment` and `service`. The term `service` is used to represent a running Artifact. A `service` can represent a binary that is running, a daemon, an application, a docker container. The term `environment` represent any platform which has all the means to run a `service`. | ||
|
||
| Subject | Description | Predicates | | ||
|---------|-------------|------------| | ||
| [`environment`](#environment) | An environment where to run services | [`created`](#environment-created), [`modified`](#environment-modified), [`deleted`](#environment-deleted)| | ||
| [`service`](#service) | A service | [`deployed`](#service-deployed), [`upgraded`](#service-upgraded), [`rolledback`](#service-rolledback), [`removed`](#service-removed), [`published`](#service-published)| | ||
|
||
### `environment` | ||
|
||
An `environment` is a platform which may run a `service`. | ||
|
||
| Field | Type | Description | Examples | | ||
|-------|------|-------------|----------| | ||
| id | `String` | Uniquely identifies the subject within the source. | `1234`, `maven123`, `builds/taskrun123` | | ||
| source | `URI-Reference` | [source](../spec.md#source) from the context | `staging/tekton`, `tekton-dev-123`| | ||
| name | `String` | Name of the environment | `dev`, `staging`, `production`, `ci-123`| | ||
| url | `String` | URL to reference where the environment is located | `https://my-cluster.zone.my-cloud-provider`| | ||
|
||
### `service` | ||
|
||
A `service` can represent for example a binary that is running, a daemon, an application or a docker container. | ||
|
||
| Field | Type | Description | Examples | | ||
|-------|------|-------------|----------| | ||
| id | `String` | Uniquely identifies the subject within the source. | `service/myapp`, `daemonset/myapp` | | ||
| source | `URI-Reference` | [source](../spec.md#source) from the context | `staging/tekton`, `tekton-dev-123`| | ||
| environment | `Object` ([`environment`](#environment)) | Reference for the environment where the service runs | `{"id": "1234"}`, `{"id": "maven123, "source": "tekton-dev-123"}` | | ||
| artifactId | `Purl` | Identifier of the artifact deployed with this service | `pkg:oci/myapp@sha256%3A0b31b1c02ff458ad9b7b81cbdf8f028bd54699fa151f221d1e8de6817db93427`, `pkg:golang/mygit.com/myorg/myapp@234fd47e07d1004f0aed9c` | | ||
|
||
## Events | ||
|
||
### `environment created` | ||
|
||
This event represents an environment that has been created. Such an environment can be used to deploy services in. | ||
|
||
- Event Type: __`dev.cdevents.environment.created.0.1.0`__ | ||
- Predicate: created | ||
- Subject: [`environment`](#environment) | ||
|
||
| Field | Type | Description | Examples | Mandatory ✅ \| Optional ⚪ | | ||
|-------|------|-------------|----------|----------------------------| | ||
| id | `String` | Uniquely identifies the subject within the source. | `tenant1/12345-abcde`, `namespace/pipelinerun-1234` | ✅ | | ||
| source | `URI-Reference` | [source](../spec.md#source) from the context | | ⚪ | | ||
| name | `String` | Name of the environment | `dev`, `staging`, `production`, `ci-123`| ⚪ | | ||
| url | `String` | URL to reference where the environment is located | `https://my-cluster.zone.my-cloud-provider`| ⚪ | | ||
|
||
### `environment modified` | ||
|
||
This event represents an environment that has been modified. | ||
|
||
- Event Type: __`dev.cdevents.environment.modified.0.1.0`__ | ||
- Predicate: modified | ||
- Subject: [`environment`](#environment) | ||
|
||
| Field | Type | Description | Examples | Mandatory ✅ \| Optional ⚪ | | ||
|-------|------|-------------|----------|----------------------------| | ||
| id | `String` | Uniquely identifies the subject within the source. | `tenant1/12345-abcde`, `namespace/pipelinerun-1234` | ✅ | | ||
| source | `URI-Reference` | [source](../spec.md#source) from the context | | ⚪ | | ||
| name | `String` | Name of the environment | `dev`, `staging`, `production`, `ci-123`| ⚪ | | ||
| url | `String` | URL to reference where the environment is located | `https://my-cluster.zone.my-cloud-provider`| ⚪ | | ||
|
||
### `environment deleted` | ||
|
||
This event represents an environment that has been deleted.``` | ||
|
||
- Event Type: __`dev.cdevents.environment.deleted.0.1.0`__ | ||
- Predicate: deleted | ||
- Subject: [`environment`](#environment) | ||
|
||
| Field | Type | Description | Examples | Mandatory ✅ \| Optional ⚪ | | ||
|-------|------|-------------|----------|----------------------------| | ||
| id | `String` | Uniquely identifies the subject within the source. | `tenant1/12345-abcde`, `namespace/pipelinerun-1234` | ✅ | | ||
| source | `URI-Reference` | [source](../spec.md#source) from the context | | ⚪ | | ||
| name | `String` | Name of the environment | `dev`, `staging`, `production`, `ci-123`| ⚪ | | ||
|
||
### `service deployed` | ||
|
||
This event represents a new instance of a service that has been deployed | ||
|
||
- Event Type: __`dev.cdevents.service.deployed.0.1.0`__ | ||
- Predicate: deployed | ||
- Subject: [`service`](#service) | ||
|
||
| Field | Type | Description | Examples | Mandatory ✅ \| Optional ⚪ | | ||
|-------|------|-------------|----------|----------------------------| | ||
| id | `String` | Uniquely identifies the subject within the source. | `service/myapp`, `daemonset/myapp` | ✅ | | ||
| environment | `Object` ([`environment`](#environment)) | Reference for the environment where the service runs | `{"id": "1234"}`, `{"id": "maven123, "source": "tekton-dev-123"}` | ✅ | | ||
| artifactId | `Purl` | Identifier of the artifact deployed with this service | `0b31b1c02ff458ad9b7b81cbdf8f028bd54699fa151f221d1e8de6817db93427`, `927aa808433d17e315a258b98e2f1a55f8258e0cb782ccb76280646d0dbe17b5`, `six-1.14.0-py2.py3-none-any.whl` | ✅ | | ||
|
||
### `service upgraded` | ||
|
||
This event represents an existing instance of a service that has been upgraded to a new version | ||
|
||
- Event Type: __`dev.cdevents.service.upgraded.0.1.0`__ | ||
- Predicate: upgraded | ||
- Subject: [`service`](#service) | ||
|
||
| Field | Type | Description | Examples | Mandatory ✅ \| Optional ⚪ | | ||
|-------|------|-------------|----------|----------------------------| | ||
| id | `String` | Uniquely identifies the subject within the source. | `service/myapp`, `daemonset/myapp` | ✅ | | ||
| environment | `Object` ([`environment`](#environment)) | Reference for the environment where the service runs | `{"id": "1234"}`, `{"id": "maven123, "source": "tekton-dev-123"}` | ✅ | | ||
| artifactId | `Purl` | Identifier of the artifact deployed with this service |`pkg:oci/myapp@sha256%3A0b31b1c02ff458ad9b7b81cbdf8f028bd54699fa151f221d1e8de6817db93427`, `pkg:golang/mygit.com/myorg/myapp@234fd47e07d1004f0aed9c` | ✅ | | ||
|
||
### `service rolledback` | ||
|
||
This event represents an existing instance of a service that has been rolled back to a previous version | ||
|
||
- Event Type: __`dev.cdevents.service.rolledback.0.1.0`__ | ||
- Predicate: rolledback | ||
- Subject: [`service`](#service) | ||
|
||
| Field | Type | Description | Examples | Mandatory ✅ \| Optional ⚪ | | ||
|-------|------|-------------|----------|----------------------------| | ||
| id | `String` | Uniquely identifies the subject within the source. | `service/myapp`, `daemonset/myapp` | ✅ | | ||
| environment | `Object` ([`environment`](#environment)) | Reference for the environment where the service runs | `{"id": "1234"}`, `{"id": "maven123, "source": "tekton-dev-123"}` | ✅ | | ||
| artifactId | `Purl` | Identifier of the artifact deployed with this service | `pkg:oci/myapp@sha256%3A0b31b1c02ff458ad9b7b81cbdf8f028bd54699fa151f221d1e8de6817db93427`, `pkg:golang/mygit.com/myorg/myapp@234fd47e07d1004f0aed9c` | ✅ | | ||
|
||
### `service removed` | ||
|
||
This event represents the removal of a previously deployed service instance and is thus not longer present in the specified environment | ||
|
||
- Event Type: __`dev.cdevents.service.removed.0.1.0`__ | ||
- Predicate: removed | ||
- Subject: [`service`](#service) | ||
|
||
| Field | Type | Description | Examples | Mandatory ✅ \| Optional ⚪ | | ||
|-------|------|-------------|----------|----------------------------| | ||
| id | `String` | Uniquely identifies the subject within the source. | `service/myapp`, `daemonset/myapp` | ✅ | | ||
| environment | `Object` ([`environment`](#environment)) | Reference for the environment where the service runs | `{"id": "1234"}`, `{"id": "maven123, "source": "tekton-dev-123"}` | ✅ | | ||
|
||
### `service published` | ||
|
||
This event represents an existing instance of a service that has an accessible URL for users to interact with it. This event can be used to let other tools know that the service is ready and also available for consumption. | ||
|
||
- Event Type: __`dev.cdevents.service.published.0.1.0`__ | ||
- Predicate: published | ||
- Subject: [`service`](#service) | ||
|
||
| Field | Type | Description | Examples | Mandatory ✅ \| Optional ⚪ | | ||
|-------|------|-------------|----------|----------------------------| | ||
| id | `String` | Uniquely identifies the subject within the source. | `service/myapp`, `daemonset/myapp` | ✅ | | ||
| environment | `Object` ([`environment`](#environment)) | Reference for the environment where the service runs | `{"id": "1234"}`, `{"id": "maven123, "source": "tekton-dev-123"}` | ✅ | |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters