Skip to content

Commit

Permalink
🎨 small proto-changes to pipeline and pipeline-service (#1264)
Browse files Browse the repository at this point in the history
  • Loading branch information
Munklinde96 authored Oct 7, 2024
1 parent c1dd5fa commit 5b691b2
Show file tree
Hide file tree
Showing 4 changed files with 24 additions and 4 deletions.
13 changes: 9 additions & 4 deletions docs/docs/api/platform-api.md
Original file line number Diff line number Diff line change
Expand Up @@ -4212,6 +4212,7 @@ The actual log message
| state | [PhaseState](#api-v1-capsule-pipeline-PhaseState) | | |
| rollout_id | [uint64](#uint64) | | |
| messages | [PhaseMessage](#api-v1-capsule-pipeline-PhaseMessage) | repeated | |
| started_at | [google.protobuf.Timestamp](#google-protobuf-Timestamp) | | |



Expand All @@ -4233,6 +4234,7 @@ The actual log message
| phase_statuses | [PhaseStatus](#api-v1-capsule-pipeline-PhaseStatus) | repeated | The statuses of the phases in the pipeline. |
| started_at | [google.protobuf.Timestamp](#google-protobuf-Timestamp) | | When the pipeline was started. |
| updated_at | [google.protobuf.Timestamp](#google-protobuf-Timestamp) | | When the pipeline was last updated. |
| current_phase | [uint32](#uint32) | | current phase |



Expand Down Expand Up @@ -6587,6 +6589,7 @@ The response of a capsule.Logs RPC
| execution_id | [uint64](#uint64) | | |
| dry_run | [bool](#bool) | | If true, the progression will not be executed, but instead a breakdown of changes will be returned |
| field_changes | [FieldChange](#api-v1-capsule-FieldChange) | repeated | additional changes to include in the manual promotion |
| force | [bool](#bool) | | If true, the pipeline will be force promoted to the next environment regardless of the state of the pipeline and the triggers. |



Expand Down Expand Up @@ -6724,6 +6727,7 @@ RestartInstanceResponse is an empty response.
| capsule_id | [string](#string) | | |
| pipeline_name | [string](#string) | | |
| dry_run | [bool](#bool) | | |
| abort_current | [bool](#bool) | | If true, and the pipeline is already running for the capsule and project, it will be aborted and a new one started. |



Expand Down Expand Up @@ -8359,10 +8363,11 @@ A docker image tag.
| Field | Type | Label | Description |
| ----- | ---- | ----- | ----------- |
| name | [string](#string) | | Custom name for the pipeline. |
| initial_environment | [string](#string) | | |
| phases | [Phase](#model-Phase) | repeated | |
| created_at | [google.protobuf.Timestamp](#google-protobuf-Timestamp) | | |
| updated_at | [google.protobuf.Timestamp](#google-protobuf-Timestamp) | | |
| initial_environment | [string](#string) | | The environment to base the pipeline on. |
| phases | [Phase](#model-Phase) | repeated | The subsequent phases of the pipeline to promote to. |
| created_at | [google.protobuf.Timestamp](#google-protobuf-Timestamp) | | The time the pipeline was created. |
| updated_at | [google.protobuf.Timestamp](#google-protobuf-Timestamp) | | The time the pipeline was updated. |
| description | [string](#string) | | User specified description of the pipeline. |



Expand Down
3 changes: 3 additions & 0 deletions proto/rig/api/v1/capsule/pipeline/status.proto
Original file line number Diff line number Diff line change
Expand Up @@ -19,13 +19,16 @@ message Status {
google.protobuf.Timestamp started_at = 6;
// When the pipeline was last updated.
google.protobuf.Timestamp updated_at = 7;
// current phase
uint32 current_phase = 8;
}

message PhaseStatus {
string environment_id = 1;
PhaseState state = 2;
uint64 rollout_id = 3;
repeated PhaseMessage messages = 4;
google.protobuf.Timestamp started_at = 5;
}

message PhaseMessage {
Expand Down
6 changes: 6 additions & 0 deletions proto/rig/api/v1/capsule/service.proto
Original file line number Diff line number Diff line change
Expand Up @@ -152,6 +152,9 @@ message PromotePipelineRequest {
bool dry_run = 2;
// additional changes to include in the manual promotion
repeated api.v1.capsule.FieldChange field_changes = 3;
// If true, the pipeline will be force promoted to the next environment
// regardless of the state of the pipeline and the triggers.
bool force = 4;
}

message PromotePipelineResponse {
Expand Down Expand Up @@ -184,6 +187,9 @@ message StartPipelineRequest {
string capsule_id = 2;
string pipeline_name = 3;
bool dry_run = 4;
// If true, and the pipeline is already running for the capsule and project,
// it will be aborted and a new one started.
bool abort_current = 5;
}

message StartPipelineResponse {
Expand Down
6 changes: 6 additions & 0 deletions proto/rig/model/pipeline.proto
Original file line number Diff line number Diff line change
Expand Up @@ -8,10 +8,16 @@ import "google/protobuf/duration.proto";
message Pipeline {
// Custom name for the pipeline.
string name = 1;
// The environment to base the pipeline on.
string initial_environment = 2;
// The subsequent phases of the pipeline to promote to.
repeated Phase phases = 3;
// The time the pipeline was created.
google.protobuf.Timestamp created_at = 4;
// The time the pipeline was updated.
google.protobuf.Timestamp updated_at = 5;
// User specified description of the pipeline.
string description = 6;
}

message Phase {
Expand Down

0 comments on commit 5b691b2

Please sign in to comment.