Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: add NotebookRuntime resource and APIs to public v1 client library
PiperOrigin-RevId: 620353345
- Loading branch information
Google APIs
authored and
Copybara-Service
committed
Mar 29, 2024
1 parent
b8b25af
commit 98ae609
Showing
9 changed files
with
989 additions
and
0 deletions.
There are no files selected for viewing
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
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,50 @@ | ||
// Copyright 2023 Google LLC | ||
// | ||
// Licensed under the Apache License, Version 2.0 (the "License"); | ||
// you may not use this file except in compliance with the License. | ||
// You may obtain a copy of the License at | ||
// | ||
// http://www.apache.org/licenses/LICENSE-2.0 | ||
// | ||
// Unless required by applicable law or agreed to in writing, software | ||
// distributed under the License is distributed on an "AS IS" BASIS, | ||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
// See the License for the specific language governing permissions and | ||
// limitations under the License. | ||
|
||
syntax = "proto3"; | ||
|
||
package google.cloud.aiplatform.v1; | ||
|
||
import "google/api/resource.proto"; | ||
|
||
option csharp_namespace = "Google.Cloud.AIPlatform.V1"; | ||
option go_package = "cloud.google.com/go/aiplatform/apiv1/aiplatformpb;aiplatformpb"; | ||
option java_multiple_files = true; | ||
option java_outer_classname = "NetworkSpecProto"; | ||
option java_package = "com.google.cloud.aiplatform.v1"; | ||
option php_namespace = "Google\\Cloud\\AIPlatform\\V1"; | ||
option ruby_package = "Google::Cloud::AIPlatform::V1"; | ||
option (google.api.resource_definition) = { | ||
type: "compute.googleapis.com/Subnetwork" | ||
pattern: "projects/{project}/regions/{region}/subnetworks/{subnetwork}" | ||
}; | ||
|
||
// Network spec. | ||
message NetworkSpec { | ||
// Whether to enable public internet access. Default false. | ||
bool enable_internet_access = 1; | ||
|
||
// The full name of the Google Compute Engine | ||
// [network](https://cloud.google.com//compute/docs/networks-and-firewalls#networks) | ||
string network = 2 [ | ||
(google.api.resource_reference) = { type: "compute.googleapis.com/Network" } | ||
]; | ||
|
||
// The name of the subnet that this instance is in. | ||
// Format: | ||
// `projects/{project_id_or_number}/regions/{region}/subnetworks/{subnetwork_id}` | ||
string subnetwork = 3 [(google.api.resource_reference) = { | ||
type: "compute.googleapis.com/Subnetwork" | ||
}]; | ||
} |
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,44 @@ | ||
// Copyright 2023 Google LLC | ||
// | ||
// Licensed under the Apache License, Version 2.0 (the "License"); | ||
// you may not use this file except in compliance with the License. | ||
// You may obtain a copy of the License at | ||
// | ||
// http://www.apache.org/licenses/LICENSE-2.0 | ||
// | ||
// Unless required by applicable law or agreed to in writing, software | ||
// distributed under the License is distributed on an "AS IS" BASIS, | ||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
// See the License for the specific language governing permissions and | ||
// limitations under the License. | ||
|
||
syntax = "proto3"; | ||
|
||
package google.cloud.aiplatform.v1; | ||
|
||
import "google/api/field_behavior.proto"; | ||
|
||
option csharp_namespace = "Google.Cloud.AIPlatform.V1"; | ||
option go_package = "cloud.google.com/go/aiplatform/apiv1/aiplatformpb;aiplatformpb"; | ||
option java_multiple_files = true; | ||
option java_outer_classname = "NotebookEucConfigProto"; | ||
option java_package = "com.google.cloud.aiplatform.v1"; | ||
option php_namespace = "Google\\Cloud\\AIPlatform\\V1"; | ||
option ruby_package = "Google::Cloud::AIPlatform::V1"; | ||
|
||
// The euc configuration of NotebookRuntimeTemplate. | ||
message NotebookEucConfig { | ||
// Input only. Whether EUC is disabled in this NotebookRuntimeTemplate. | ||
// In proto3, the default value of a boolean is false. In this way, by default | ||
// EUC will be enabled for NotebookRuntimeTemplate. | ||
bool euc_disabled = 1 [(google.api.field_behavior) = INPUT_ONLY]; | ||
|
||
// Output only. Whether ActAs check is bypassed for service account attached | ||
// to the VM. If false, we need ActAs check for the default Compute Engine | ||
// Service account. When a Runtime is created, a VM is allocated using Default | ||
// Compute Engine Service Account. Any user requesting to use this Runtime | ||
// requires Service Account User (ActAs) permission over this SA. If true, | ||
// Runtime owner is using EUC and does not require the above permission as VM | ||
// no longer use default Compute Engine SA, but a P4SA. | ||
bool bypass_actas_check = 2 [(google.api.field_behavior) = OUTPUT_ONLY]; | ||
} |
41 changes: 41 additions & 0 deletions
41
google/cloud/aiplatform/v1/notebook_idle_shutdown_config.proto
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,41 @@ | ||
// Copyright 2023 Google LLC | ||
// | ||
// Licensed under the Apache License, Version 2.0 (the "License"); | ||
// you may not use this file except in compliance with the License. | ||
// You may obtain a copy of the License at | ||
// | ||
// http://www.apache.org/licenses/LICENSE-2.0 | ||
// | ||
// Unless required by applicable law or agreed to in writing, software | ||
// distributed under the License is distributed on an "AS IS" BASIS, | ||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
// See the License for the specific language governing permissions and | ||
// limitations under the License. | ||
|
||
syntax = "proto3"; | ||
|
||
package google.cloud.aiplatform.v1; | ||
|
||
import "google/api/field_behavior.proto"; | ||
import "google/protobuf/duration.proto"; | ||
|
||
option csharp_namespace = "Google.Cloud.AIPlatform.V1"; | ||
option go_package = "cloud.google.com/go/aiplatform/apiv1/aiplatformpb;aiplatformpb"; | ||
option java_multiple_files = true; | ||
option java_outer_classname = "NotebookIdleShutdownConfigProto"; | ||
option java_package = "com.google.cloud.aiplatform.v1"; | ||
option php_namespace = "Google\\Cloud\\AIPlatform\\V1"; | ||
option ruby_package = "Google::Cloud::AIPlatform::V1"; | ||
|
||
// The idle shutdown configuration of NotebookRuntimeTemplate, which contains | ||
// the idle_timeout as required field. | ||
message NotebookIdleShutdownConfig { | ||
// Required. Duration is accurate to the second. In Notebook, Idle Timeout is | ||
// accurate to minute so the range of idle_timeout (second) is: 10 * 60 ~ 1440 | ||
// * 60. | ||
google.protobuf.Duration idle_timeout = 1 | ||
[(google.api.field_behavior) = REQUIRED]; | ||
|
||
// Whether Idle Shutdown is disabled in this NotebookRuntimeTemplate. | ||
bool idle_shutdown_disabled = 2; | ||
} |
Oops, something went wrong.