Skip to content

Commit c875f2b

Browse files
Google APIscopybara-github
authored andcommitted
feat: add failure_policy to PipelineJob in aiplatform v1 & v1beta1 pipeline_job.proto
PiperOrigin-RevId: 450704795
1 parent c6fb6ac commit c875f2b

6 files changed

Lines changed: 108 additions & 0 deletions

File tree

google/cloud/aiplatform/v1/BUILD.bazel

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -81,6 +81,7 @@ proto_library(
8181
"model_monitoring.proto",
8282
"model_service.proto",
8383
"operation.proto",
84+
"pipeline_failure_policy.proto",
8485
"pipeline_job.proto",
8586
"pipeline_service.proto",
8687
"pipeline_state.proto",
Lines changed: 44 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,44 @@
1+
// Copyright 2022 Google LLC
2+
//
3+
// Licensed under the Apache License, Version 2.0 (the "License");
4+
// you may not use this file except in compliance with the License.
5+
// You may obtain a copy of the License at
6+
//
7+
// http://www.apache.org/licenses/LICENSE-2.0
8+
//
9+
// Unless required by applicable law or agreed to in writing, software
10+
// distributed under the License is distributed on an "AS IS" BASIS,
11+
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12+
// See the License for the specific language governing permissions and
13+
// limitations under the License.
14+
15+
syntax = "proto3";
16+
17+
package google.cloud.aiplatform.v1;
18+
19+
option csharp_namespace = "Google.Cloud.AIPlatform.V1";
20+
option go_package = "google.golang.org/genproto/googleapis/cloud/aiplatform/v1;aiplatform";
21+
option java_multiple_files = true;
22+
option java_outer_classname = "PipelineFailurePolicyProto";
23+
option java_package = "com.google.cloud.aiplatform.v1";
24+
option php_namespace = "Google\\Cloud\\AIPlatform\\V1";
25+
option ruby_package = "Google::Cloud::AIPlatform::V1";
26+
27+
// Represents the failure policy of a pipeline. Currently, the default of a
28+
// pipeline is that the pipeline will continue to run until no more tasks can be
29+
// executed, also known as PIPELINE_FAILURE_POLICY_FAIL_SLOW. However, if a
30+
// pipeline is set to PIPELINE_FAILURE_POLICY_FAIL_FAST, it will stop scheduling
31+
// any new tasks when a task has failed. Any scheduled tasks will continue to
32+
// completion.
33+
enum PipelineFailurePolicy {
34+
// Default value, and follows fail slow behavior.
35+
PIPELINE_FAILURE_POLICY_UNSPECIFIED = 0;
36+
37+
// Indicates that the pipeline should continue to run until all possible
38+
// tasks have been scheduled and completed.
39+
PIPELINE_FAILURE_POLICY_FAIL_SLOW = 1;
40+
41+
// Indicates that the pipeline should stop scheduling new tasks after a task
42+
// has failed.
43+
PIPELINE_FAILURE_POLICY_FAIL_FAST = 2;
44+
}

google/cloud/aiplatform/v1/pipeline_job.proto

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,7 @@ import "google/cloud/aiplatform/v1/artifact.proto";
2222
import "google/cloud/aiplatform/v1/context.proto";
2323
import "google/cloud/aiplatform/v1/encryption_spec.proto";
2424
import "google/cloud/aiplatform/v1/execution.proto";
25+
import "google/cloud/aiplatform/v1/pipeline_failure_policy.proto";
2526
import "google/cloud/aiplatform/v1/pipeline_state.proto";
2627
import "google/cloud/aiplatform/v1/value.proto";
2728
import "google/protobuf/struct.proto";
@@ -72,6 +73,14 @@ message PipelineJob {
7273
// `PipelineJob.pipeline_spec.schema_version` 2.1.0, such as pipelines built
7374
// using Kubeflow Pipelines SDK 1.9 or higher and the v2 DSL.
7475
map<string, google.protobuf.Value> parameter_values = 3;
76+
77+
// Represents the failure policy of a pipeline. Currently, the default of a
78+
// pipeline is that the pipeline will continue to run until no more tasks
79+
// can be executed, also known as PIPELINE_FAILURE_POLICY_FAIL_SLOW.
80+
// However, if a pipeline is set to PIPELINE_FAILURE_POLICY_FAIL_FAST, it
81+
// will stop scheduling any new tasks when a task has failed. Any scheduled
82+
// tasks will continue to completion.
83+
PipelineFailurePolicy failure_policy = 4;
7584
}
7685

7786
// Output only. The resource name of the PipelineJob.

google/cloud/aiplatform/v1beta1/BUILD.bazel

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -74,6 +74,7 @@ proto_library(
7474
"model_monitoring.proto",
7575
"model_service.proto",
7676
"operation.proto",
77+
"pipeline_failure_policy.proto",
7778
"pipeline_job.proto",
7879
"pipeline_service.proto",
7980
"pipeline_state.proto",
Lines changed: 44 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,44 @@
1+
// Copyright 2022 Google LLC
2+
//
3+
// Licensed under the Apache License, Version 2.0 (the "License");
4+
// you may not use this file except in compliance with the License.
5+
// You may obtain a copy of the License at
6+
//
7+
// http://www.apache.org/licenses/LICENSE-2.0
8+
//
9+
// Unless required by applicable law or agreed to in writing, software
10+
// distributed under the License is distributed on an "AS IS" BASIS,
11+
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12+
// See the License for the specific language governing permissions and
13+
// limitations under the License.
14+
15+
syntax = "proto3";
16+
17+
package google.cloud.aiplatform.v1beta1;
18+
19+
option csharp_namespace = "Google.Cloud.AIPlatform.V1Beta1";
20+
option go_package = "google.golang.org/genproto/googleapis/cloud/aiplatform/v1beta1;aiplatform";
21+
option java_multiple_files = true;
22+
option java_outer_classname = "PipelineFailurePolicyProto";
23+
option java_package = "com.google.cloud.aiplatform.v1beta1";
24+
option php_namespace = "Google\\Cloud\\AIPlatform\\V1beta1";
25+
option ruby_package = "Google::Cloud::AIPlatform::V1beta1";
26+
27+
// Represents the failure policy of a pipeline. Currently, the default of a
28+
// pipeline is that the pipeline will continue to run until no more tasks can be
29+
// executed, also known as PIPELINE_FAILURE_POLICY_FAIL_SLOW. However, if a
30+
// pipeline is set to PIPELINE_FAILURE_POLICY_FAIL_FAST, it will stop scheduling
31+
// any new tasks when a task has failed. Any scheduled tasks will continue to
32+
// completion.
33+
enum PipelineFailurePolicy {
34+
// Default value, and follows fail slow behavior.
35+
PIPELINE_FAILURE_POLICY_UNSPECIFIED = 0;
36+
37+
// Indicates that the pipeline should continue to run until all possible
38+
// tasks have been scheduled and completed.
39+
PIPELINE_FAILURE_POLICY_FAIL_SLOW = 1;
40+
41+
// Indicates that the pipeline should stop scheduling new tasks after a task
42+
// has failed.
43+
PIPELINE_FAILURE_POLICY_FAIL_FAST = 2;
44+
}

google/cloud/aiplatform/v1beta1/pipeline_job.proto

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,7 @@ import "google/cloud/aiplatform/v1beta1/artifact.proto";
2222
import "google/cloud/aiplatform/v1beta1/context.proto";
2323
import "google/cloud/aiplatform/v1beta1/encryption_spec.proto";
2424
import "google/cloud/aiplatform/v1beta1/execution.proto";
25+
import "google/cloud/aiplatform/v1beta1/pipeline_failure_policy.proto";
2526
import "google/cloud/aiplatform/v1beta1/pipeline_state.proto";
2627
import "google/cloud/aiplatform/v1beta1/value.proto";
2728
import "google/protobuf/struct.proto";
@@ -72,6 +73,14 @@ message PipelineJob {
7273
// `PipelineJob.pipeline_spec.schema_version` 2.1.0, such as pipelines built
7374
// using Kubeflow Pipelines SDK 1.9 or higher and the v2 DSL.
7475
map<string, google.protobuf.Value> parameter_values = 3;
76+
77+
// Represents the failure policy of a pipeline. Currently, the default of a
78+
// pipeline is that the pipeline will continue to run until no more tasks
79+
// can be executed, also known as PIPELINE_FAILURE_POLICY_FAIL_SLOW.
80+
// However, if a pipeline is set to PIPELINE_FAILURE_POLICY_FAIL_FAST, it
81+
// will stop scheduling any new tasks when a task has failed. Any scheduled
82+
// tasks will continue to completion.
83+
PipelineFailurePolicy failure_policy = 4;
7584
}
7685

7786
// Output only. The resource name of the PipelineJob.

0 commit comments

Comments
 (0)