|
| 1 | +// Copyright 2017 Google Inc. |
| 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.bigtable.admin.cluster.v1; |
| 18 | + |
| 19 | +import "google/api/annotations.proto"; |
| 20 | +import "google/bigtable/admin/cluster/v1/bigtable_cluster_data.proto"; |
| 21 | +import "google/bigtable/admin/cluster/v1/bigtable_cluster_service_messages.proto"; |
| 22 | +import "google/longrunning/operations.proto"; |
| 23 | +import "google/protobuf/empty.proto"; |
| 24 | + |
| 25 | +option go_package = "google.golang.org/genproto/googleapis/bigtable/admin/cluster/v1;cluster"; |
| 26 | +option java_multiple_files = true; |
| 27 | +option java_outer_classname = "BigtableClusterServicesProto"; |
| 28 | +option java_package = "com.google.bigtable.admin.cluster.v1"; |
| 29 | + |
| 30 | +// Service for managing zonal Cloud Bigtable resources. |
| 31 | +service BigtableClusterService { |
| 32 | + // Lists the supported zones for the given project. |
| 33 | + rpc ListZones(ListZonesRequest) returns (ListZonesResponse) { |
| 34 | + option (google.api.http) = { |
| 35 | + get: "/v1/{name=projects/*}/zones" |
| 36 | + }; |
| 37 | + } |
| 38 | + |
| 39 | + // Gets information about a particular cluster. |
| 40 | + rpc GetCluster(GetClusterRequest) returns (Cluster) { |
| 41 | + option (google.api.http) = { |
| 42 | + get: "/v1/{name=projects/*/zones/*/clusters/*}" |
| 43 | + }; |
| 44 | + } |
| 45 | + |
| 46 | + // Lists all clusters in the given project, along with any zones for which |
| 47 | + // cluster information could not be retrieved. |
| 48 | + rpc ListClusters(ListClustersRequest) returns (ListClustersResponse) { |
| 49 | + option (google.api.http) = { |
| 50 | + get: "/v1/{name=projects/*}/aggregated/clusters" |
| 51 | + }; |
| 52 | + } |
| 53 | + |
| 54 | + // Creates a cluster and begins preparing it to begin serving. The returned |
| 55 | + // cluster embeds as its "current_operation" a long-running operation which |
| 56 | + // can be used to track the progress of turning up the new cluster. |
| 57 | + // Immediately upon completion of this request: |
| 58 | + // * The cluster will be readable via the API, with all requested attributes |
| 59 | + // but no allocated resources. |
| 60 | + // Until completion of the embedded operation: |
| 61 | + // * Cancelling the operation will render the cluster immediately unreadable |
| 62 | + // via the API. |
| 63 | + // * All other attempts to modify or delete the cluster will be rejected. |
| 64 | + // Upon completion of the embedded operation: |
| 65 | + // * Billing for all successfully-allocated resources will begin (some types |
| 66 | + // may have lower than the requested levels). |
| 67 | + // * New tables can be created in the cluster. |
| 68 | + // * The cluster's allocated resource levels will be readable via the API. |
| 69 | + // The embedded operation's "metadata" field type is |
| 70 | + // [CreateClusterMetadata][google.bigtable.admin.cluster.v1.CreateClusterMetadata] |
| 71 | + // The embedded operation's "response" field type is |
| 72 | + // [Cluster][google.bigtable.admin.cluster.v1.Cluster], if successful. |
| 73 | + rpc CreateCluster(CreateClusterRequest) returns (Cluster) { |
| 74 | + option (google.api.http) = { |
| 75 | + post: "/v1/{name=projects/*/zones/*}/clusters" |
| 76 | + body: "*" |
| 77 | + }; |
| 78 | + } |
| 79 | + |
| 80 | + // Updates a cluster, and begins allocating or releasing resources as |
| 81 | + // requested. The returned cluster embeds as its "current_operation" a |
| 82 | + // long-running operation which can be used to track the progress of updating |
| 83 | + // the cluster. |
| 84 | + // Immediately upon completion of this request: |
| 85 | + // * For resource types where a decrease in the cluster's allocation has been |
| 86 | + // requested, billing will be based on the newly-requested level. |
| 87 | + // Until completion of the embedded operation: |
| 88 | + // * Cancelling the operation will set its metadata's "cancelled_at_time", |
| 89 | + // and begin restoring resources to their pre-request values. The operation |
| 90 | + // is guaranteed to succeed at undoing all resource changes, after which |
| 91 | + // point it will terminate with a CANCELLED status. |
| 92 | + // * All other attempts to modify or delete the cluster will be rejected. |
| 93 | + // * Reading the cluster via the API will continue to give the pre-request |
| 94 | + // resource levels. |
| 95 | + // Upon completion of the embedded operation: |
| 96 | + // * Billing will begin for all successfully-allocated resources (some types |
| 97 | + // may have lower than the requested levels). |
| 98 | + // * All newly-reserved resources will be available for serving the cluster's |
| 99 | + // tables. |
| 100 | + // * The cluster's new resource levels will be readable via the API. |
| 101 | + // [UpdateClusterMetadata][google.bigtable.admin.cluster.v1.UpdateClusterMetadata] |
| 102 | + // The embedded operation's "response" field type is |
| 103 | + // [Cluster][google.bigtable.admin.cluster.v1.Cluster], if successful. |
| 104 | + rpc UpdateCluster(Cluster) returns (Cluster) { |
| 105 | + option (google.api.http) = { |
| 106 | + put: "/v1/{name=projects/*/zones/*/clusters/*}" |
| 107 | + body: "*" |
| 108 | + }; |
| 109 | + } |
| 110 | + |
| 111 | + // Marks a cluster and all of its tables for permanent deletion in 7 days. |
| 112 | + // Immediately upon completion of the request: |
| 113 | + // * Billing will cease for all of the cluster's reserved resources. |
| 114 | + // * The cluster's "delete_time" field will be set 7 days in the future. |
| 115 | + // Soon afterward: |
| 116 | + // * All tables within the cluster will become unavailable. |
| 117 | + // Prior to the cluster's "delete_time": |
| 118 | + // * The cluster can be recovered with a call to UndeleteCluster. |
| 119 | + // * All other attempts to modify or delete the cluster will be rejected. |
| 120 | + // At the cluster's "delete_time": |
| 121 | + // * The cluster and *all of its tables* will immediately and irrevocably |
| 122 | + // disappear from the API, and their data will be permanently deleted. |
| 123 | + rpc DeleteCluster(DeleteClusterRequest) returns (google.protobuf.Empty) { |
| 124 | + option (google.api.http) = { |
| 125 | + delete: "/v1/{name=projects/*/zones/*/clusters/*}" |
| 126 | + }; |
| 127 | + } |
| 128 | + |
| 129 | + // Cancels the scheduled deletion of an cluster and begins preparing it to |
| 130 | + // resume serving. The returned operation will also be embedded as the |
| 131 | + // cluster's "current_operation". |
| 132 | + // Immediately upon completion of this request: |
| 133 | + // * The cluster's "delete_time" field will be unset, protecting it from |
| 134 | + // automatic deletion. |
| 135 | + // Until completion of the returned operation: |
| 136 | + // * The operation cannot be cancelled. |
| 137 | + // Upon completion of the returned operation: |
| 138 | + // * Billing for the cluster's resources will resume. |
| 139 | + // * All tables within the cluster will be available. |
| 140 | + // [UndeleteClusterMetadata][google.bigtable.admin.cluster.v1.UndeleteClusterMetadata] |
| 141 | + // The embedded operation's "response" field type is |
| 142 | + // [Cluster][google.bigtable.admin.cluster.v1.Cluster], if successful. |
| 143 | + rpc UndeleteCluster(UndeleteClusterRequest) |
| 144 | + returns (google.longrunning.Operation) { |
| 145 | + option (google.api.http) = { |
| 146 | + post: "/v1/{name=projects/*/zones/*/clusters/*}:undelete" |
| 147 | + body: "" |
| 148 | + }; |
| 149 | + } |
| 150 | +} |
0 commit comments