123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940 |
- // Copyright 2022 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.gkebackup.v1;
- import "google/api/annotations.proto";
- import "google/api/client.proto";
- import "google/api/field_behavior.proto";
- import "google/api/resource.proto";
- import "google/cloud/gkebackup/v1/backup.proto";
- import "google/cloud/gkebackup/v1/backup_plan.proto";
- import "google/cloud/gkebackup/v1/restore.proto";
- import "google/cloud/gkebackup/v1/restore_plan.proto";
- import "google/cloud/gkebackup/v1/volume.proto";
- import "google/longrunning/operations.proto";
- import "google/protobuf/field_mask.proto";
- import "google/protobuf/timestamp.proto";
- option csharp_namespace = "Google.Cloud.GkeBackup.V1";
- option go_package = "google.golang.org/genproto/googleapis/cloud/gkebackup/v1;gkebackup";
- option java_multiple_files = true;
- option java_outer_classname = "GKEBackupProto";
- option java_package = "com.google.cloud.gkebackup.v1";
- option php_namespace = "Google\\Cloud\\GkeBackup\\V1";
- option ruby_package = "Google::Cloud::GkeBackup::V1";
- option (google.api.resource_definition) = {
- type: "container.googleapis.com/Cluster"
- pattern: "projects/{project}/locations/{location}/clusters/{cluster}"
- };
- option (google.api.resource_definition) = {
- type: "cloudkms.googleapis.com/CryptoKey"
- pattern: "projects/{project}/locations/{location}/keyRings/{key_ring}/cryptoKeys/{crypto_key}"
- };
- // BackupForGKE allows Kubernetes administrators to configure, execute, and
- // manage backup and restore operations for their GKE clusters.
- service BackupForGKE {
- option (google.api.default_host) = "gkebackup.googleapis.com";
- option (google.api.oauth_scopes) = "https://www.googleapis.com/auth/cloud-platform";
- // Creates a new BackupPlan in a given location.
- rpc CreateBackupPlan(CreateBackupPlanRequest) returns (google.longrunning.Operation) {
- option (google.api.http) = {
- post: "/v1/{parent=projects/*/locations/*}/backupPlans"
- body: "backup_plan"
- };
- option (google.api.method_signature) = "parent,backup_plan,backup_plan_id";
- option (google.longrunning.operation_info) = {
- response_type: "BackupPlan"
- metadata_type: "OperationMetadata"
- };
- }
- // Lists BackupPlans in a given location.
- rpc ListBackupPlans(ListBackupPlansRequest) returns (ListBackupPlansResponse) {
- option (google.api.http) = {
- get: "/v1/{parent=projects/*/locations/*}/backupPlans"
- };
- option (google.api.method_signature) = "parent";
- }
- // Retrieve the details of a single BackupPlan.
- rpc GetBackupPlan(GetBackupPlanRequest) returns (BackupPlan) {
- option (google.api.http) = {
- get: "/v1/{name=projects/*/locations/*/backupPlans/*}"
- };
- option (google.api.method_signature) = "name";
- }
- // Update a BackupPlan.
- rpc UpdateBackupPlan(UpdateBackupPlanRequest) returns (google.longrunning.Operation) {
- option (google.api.http) = {
- patch: "/v1/{backup_plan.name=projects/*/locations/*/backupPlans/*}"
- body: "backup_plan"
- };
- option (google.api.method_signature) = "backup_plan,update_mask";
- option (google.longrunning.operation_info) = {
- response_type: "BackupPlan"
- metadata_type: "OperationMetadata"
- };
- }
- // Deletes an existing BackupPlan.
- rpc DeleteBackupPlan(DeleteBackupPlanRequest) returns (google.longrunning.Operation) {
- option (google.api.http) = {
- delete: "/v1/{name=projects/*/locations/*/backupPlans/*}"
- };
- option (google.api.method_signature) = "name";
- option (google.longrunning.operation_info) = {
- response_type: "google.protobuf.Empty"
- metadata_type: "OperationMetadata"
- };
- }
- // Creates a Backup for the given BackupPlan.
- rpc CreateBackup(CreateBackupRequest) returns (google.longrunning.Operation) {
- option (google.api.http) = {
- post: "/v1/{parent=projects/*/locations/*/backupPlans/*}/backups"
- body: "backup"
- };
- option (google.api.method_signature) = "parent,backup,backup_id";
- option (google.longrunning.operation_info) = {
- response_type: "Backup"
- metadata_type: "OperationMetadata"
- };
- }
- // Lists the Backups for a given BackupPlan.
- rpc ListBackups(ListBackupsRequest) returns (ListBackupsResponse) {
- option (google.api.http) = {
- get: "/v1/{parent=projects/*/locations/*/backupPlans/*}/backups"
- };
- option (google.api.method_signature) = "parent";
- }
- // Retrieve the details of a single Backup.
- rpc GetBackup(GetBackupRequest) returns (Backup) {
- option (google.api.http) = {
- get: "/v1/{name=projects/*/locations/*/backupPlans/*/backups/*}"
- };
- option (google.api.method_signature) = "name";
- }
- // Update a Backup.
- rpc UpdateBackup(UpdateBackupRequest) returns (google.longrunning.Operation) {
- option (google.api.http) = {
- patch: "/v1/{backup.name=projects/*/locations/*/backupPlans/*/backups/*}"
- body: "backup"
- };
- option (google.api.method_signature) = "backup,update_mask";
- option (google.longrunning.operation_info) = {
- response_type: "Backup"
- metadata_type: "OperationMetadata"
- };
- }
- // Deletes an existing Backup.
- rpc DeleteBackup(DeleteBackupRequest) returns (google.longrunning.Operation) {
- option (google.api.http) = {
- delete: "/v1/{name=projects/*/locations/*/backupPlans/*/backups/*}"
- };
- option (google.api.method_signature) = "name";
- option (google.longrunning.operation_info) = {
- response_type: "google.protobuf.Empty"
- metadata_type: "OperationMetadata"
- };
- }
- // Lists the VolumeBackups for a given Backup.
- rpc ListVolumeBackups(ListVolumeBackupsRequest) returns (ListVolumeBackupsResponse) {
- option (google.api.http) = {
- get: "/v1/{parent=projects/*/locations/*/backupPlans/*/backups/*}/volumeBackups"
- };
- option (google.api.method_signature) = "parent";
- }
- // Retrieve the details of a single VolumeBackup.
- rpc GetVolumeBackup(GetVolumeBackupRequest) returns (VolumeBackup) {
- option (google.api.http) = {
- get: "/v1/{name=projects/*/locations/*/backupPlans/*/backups/*/volumeBackups/*}"
- };
- option (google.api.method_signature) = "name";
- }
- // Creates a new RestorePlan in a given location.
- rpc CreateRestorePlan(CreateRestorePlanRequest) returns (google.longrunning.Operation) {
- option (google.api.http) = {
- post: "/v1/{parent=projects/*/locations/*}/restorePlans"
- body: "restore_plan"
- };
- option (google.api.method_signature) = "parent,restore_plan,restore_plan_id";
- option (google.longrunning.operation_info) = {
- response_type: "RestorePlan"
- metadata_type: "OperationMetadata"
- };
- }
- // Lists RestorePlans in a given location.
- rpc ListRestorePlans(ListRestorePlansRequest) returns (ListRestorePlansResponse) {
- option (google.api.http) = {
- get: "/v1/{parent=projects/*/locations/*}/restorePlans"
- };
- option (google.api.method_signature) = "parent";
- }
- // Retrieve the details of a single RestorePlan.
- rpc GetRestorePlan(GetRestorePlanRequest) returns (RestorePlan) {
- option (google.api.http) = {
- get: "/v1/{name=projects/*/locations/*/restorePlans/*}"
- };
- option (google.api.method_signature) = "name";
- }
- // Update a RestorePlan.
- rpc UpdateRestorePlan(UpdateRestorePlanRequest) returns (google.longrunning.Operation) {
- option (google.api.http) = {
- patch: "/v1/{restore_plan.name=projects/*/locations/*/restorePlans/*}"
- body: "restore_plan"
- };
- option (google.api.method_signature) = "restore_plan,update_mask";
- option (google.longrunning.operation_info) = {
- response_type: "RestorePlan"
- metadata_type: "OperationMetadata"
- };
- }
- // Deletes an existing RestorePlan.
- rpc DeleteRestorePlan(DeleteRestorePlanRequest) returns (google.longrunning.Operation) {
- option (google.api.http) = {
- delete: "/v1/{name=projects/*/locations/*/restorePlans/*}"
- };
- option (google.api.method_signature) = "name";
- option (google.longrunning.operation_info) = {
- response_type: "google.protobuf.Empty"
- metadata_type: "OperationMetadata"
- };
- }
- // Creates a new Restore for the given RestorePlan.
- rpc CreateRestore(CreateRestoreRequest) returns (google.longrunning.Operation) {
- option (google.api.http) = {
- post: "/v1/{parent=projects/*/locations/*/restorePlans/*}/restores"
- body: "restore"
- };
- option (google.api.method_signature) = "parent,restore,restore_id";
- option (google.longrunning.operation_info) = {
- response_type: "Restore"
- metadata_type: "OperationMetadata"
- };
- }
- // Lists the Restores for a given RestorePlan.
- rpc ListRestores(ListRestoresRequest) returns (ListRestoresResponse) {
- option (google.api.http) = {
- get: "/v1/{parent=projects/*/locations/*/restorePlans/*}/restores"
- };
- option (google.api.method_signature) = "parent";
- }
- // Retrieves the details of a single Restore.
- rpc GetRestore(GetRestoreRequest) returns (Restore) {
- option (google.api.http) = {
- get: "/v1/{name=projects/*/locations/*/restorePlans/*/restores/*}"
- };
- option (google.api.method_signature) = "name";
- }
- // Update a Restore.
- rpc UpdateRestore(UpdateRestoreRequest) returns (google.longrunning.Operation) {
- option (google.api.http) = {
- patch: "/v1/{restore.name=projects/*/locations/*/restorePlans/*/restores/*}"
- body: "restore"
- };
- option (google.api.method_signature) = "restore,update_mask";
- option (google.longrunning.operation_info) = {
- response_type: "Restore"
- metadata_type: "OperationMetadata"
- };
- }
- // Deletes an existing Restore.
- rpc DeleteRestore(DeleteRestoreRequest) returns (google.longrunning.Operation) {
- option (google.api.http) = {
- delete: "/v1/{name=projects/*/locations/*/restorePlans/*/restores/*}"
- };
- option (google.api.method_signature) = "name";
- option (google.longrunning.operation_info) = {
- response_type: "google.protobuf.Empty"
- metadata_type: "OperationMetadata"
- };
- }
- // Lists the VolumeRestores for a given Restore.
- rpc ListVolumeRestores(ListVolumeRestoresRequest) returns (ListVolumeRestoresResponse) {
- option (google.api.http) = {
- get: "/v1/{parent=projects/*/locations/*/restorePlans/*/restores/*}/volumeRestores"
- };
- option (google.api.method_signature) = "parent";
- }
- // Retrieve the details of a single VolumeRestore.
- rpc GetVolumeRestore(GetVolumeRestoreRequest) returns (VolumeRestore) {
- option (google.api.http) = {
- get: "/v1/{name=projects/*/locations/*/restorePlans/*/restores/*/volumeRestores/*}"
- };
- option (google.api.method_signature) = "name";
- }
- }
- // Represents the metadata of the long-running operation.
- message OperationMetadata {
- // Output only. The time the operation was created.
- google.protobuf.Timestamp create_time = 1 [(google.api.field_behavior) = OUTPUT_ONLY];
- // Output only. The time the operation finished running.
- google.protobuf.Timestamp end_time = 2 [(google.api.field_behavior) = OUTPUT_ONLY];
- // Output only. Server-defined resource path for the target of the operation.
- string target = 3 [(google.api.field_behavior) = OUTPUT_ONLY];
- // Output only. Name of the verb executed by the operation.
- string verb = 4 [(google.api.field_behavior) = OUTPUT_ONLY];
- // Output only. Human-readable status of the operation, if any.
- string status_message = 5 [(google.api.field_behavior) = OUTPUT_ONLY];
- // Output only. Identifies whether the user has requested cancellation
- // of the operation. Operations that have successfully been cancelled
- // have [Operation.error][] value with a [google.rpc.Status.code][google.rpc.Status.code] of 1,
- // corresponding to `Code.CANCELLED`.
- bool requested_cancellation = 6 [(google.api.field_behavior) = OUTPUT_ONLY];
- // Output only. API version used to start the operation.
- string api_version = 7 [(google.api.field_behavior) = OUTPUT_ONLY];
- }
- // Request message for CreateBackupPlan.
- message CreateBackupPlanRequest {
- // Required. The location within which to create the BackupPlan.
- // Format: projects/*/locations/*
- string parent = 1 [
- (google.api.field_behavior) = REQUIRED,
- (google.api.resource_reference) = {
- type: "locations.googleapis.com/Location"
- }
- ];
- // Required. The BackupPlan resource object to create.
- BackupPlan backup_plan = 2 [(google.api.field_behavior) = REQUIRED];
- // Required. The client-provided short name for the BackupPlan resource.
- // This name must:
- //
- // - be between 1 and 63 characters long (inclusive)
- // - consist of only lower-case ASCII letters, numbers, and dashes
- // - start with a lower-case letter
- // - end with a lower-case letter or number
- // - be unique within the set of BackupPlans in this location
- string backup_plan_id = 3 [(google.api.field_behavior) = REQUIRED];
- }
- // Request message for ListBackupPlans.
- message ListBackupPlansRequest {
- // Required. The location that contains the BackupPlans to list.
- // Format: projects/*/locations/*
- string parent = 1 [
- (google.api.field_behavior) = REQUIRED,
- (google.api.resource_reference) = {
- type: "locations.googleapis.com/Location"
- }
- ];
- // The target number of results to return in a single response.
- // If not specified, a default value will be chosen by the service.
- // Note that the response may inclue a partial list and a caller should
- // only rely on the response's
- // [next_page_token][google.cloud.gkebackup.v1.ListBackupPlansResponse.next_page_token]
- // to determine if there are more instances left to be queried.
- int32 page_size = 2;
- // The value of
- // [next_page_token][google.cloud.gkebackup.v1.ListBackupPlansResponse.next_page_token]
- // received from a previous `ListBackupPlans` call.
- // Provide this to retrieve the subsequent page in a multi-page list of
- // results. When paginating, all other parameters provided to
- // `ListBackupPlans` must match the call that provided the page token.
- string page_token = 3;
- // Field match expression used to filter the results.
- string filter = 4;
- // Field by which to sort the results.
- string order_by = 5;
- }
- // Response message for ListBackupPlans.
- message ListBackupPlansResponse {
- // The list of BackupPlans matching the given criteria.
- repeated BackupPlan backup_plans = 1;
- // A token which may be sent as
- // [page_token][google.cloud.gkebackup.v1.ListBackupPlansRequest.page_token] in a subsequent
- // `ListBackupPlans` call to retrieve the next page of results.
- // If this field is omitted or empty, then there are no more results to
- // return.
- string next_page_token = 2;
- // Locations that could not be reached.
- repeated string unreachable = 3;
- }
- // Request message for GetBackupPlan.
- message GetBackupPlanRequest {
- // Required. Fully qualified BackupPlan name.
- // Format: projects/*/locations/*/backupPlans/*
- string name = 1 [
- (google.api.field_behavior) = REQUIRED,
- (google.api.resource_reference) = {
- type: "gkebackup.googleapis.com/BackupPlan"
- }
- ];
- }
- // Request message for UpdateBackupPlan.
- message UpdateBackupPlanRequest {
- // Required. A new version of the BackupPlan resource that contains updated fields.
- // This may be sparsely populated if an `update_mask` is provided.
- BackupPlan backup_plan = 1 [(google.api.field_behavior) = REQUIRED];
- // This is used to specify the fields to be overwritten in the
- // BackupPlan targeted for update. The values for each of these
- // updated fields will be taken from the `backup_plan` provided
- // with this request. Field names are relative to the root of the resource
- // (e.g., `description`, `backup_config.include_volume_data`, etc.)
- // If no `update_mask` is provided, all fields in `backup_plan` will be
- // written to the target BackupPlan resource.
- // Note that OUTPUT_ONLY and IMMUTABLE fields in `backup_plan` are ignored
- // and are not used to update the target BackupPlan.
- google.protobuf.FieldMask update_mask = 2;
- }
- // Request message for DeleteBackupPlan.
- message DeleteBackupPlanRequest {
- // Required. Fully qualified BackupPlan name.
- // Format: projects/*/locations/*/backupPlans/*
- string name = 1 [
- (google.api.field_behavior) = REQUIRED,
- (google.api.resource_reference) = {
- type: "gkebackup.googleapis.com/BackupPlan"
- }
- ];
- // If provided, this value must match the current value of the
- // target BackupPlan's [etag][google.cloud.gkebackup.v1.BackupPlan.etag] field or the request is
- // rejected.
- string etag = 2;
- }
- // Request message for CreateBackup.
- message CreateBackupRequest {
- // Required. The BackupPlan within which to create the Backup.
- // Format: projects/*/locations/*/backupPlans/*
- string parent = 1 [
- (google.api.field_behavior) = REQUIRED,
- (google.api.resource_reference) = {
- type: "gkebackup.googleapis.com/BackupPlan"
- }
- ];
- // The Backup resource to create.
- Backup backup = 2;
- // The client-provided short name for the Backup resource.
- // This name must:
- //
- // - be between 1 and 63 characters long (inclusive)
- // - consist of only lower-case ASCII letters, numbers, and dashes
- // - start with a lower-case letter
- // - end with a lower-case letter or number
- // - be unique within the set of Backups in this BackupPlan
- string backup_id = 3;
- }
- // Request message for ListBackups.
- message ListBackupsRequest {
- // Required. The BackupPlan that contains the Backups to list.
- // Format: projects/*/locations/*/backupPlans/*
- string parent = 1 [
- (google.api.field_behavior) = REQUIRED,
- (google.api.resource_reference) = {
- type: "gkebackup.googleapis.com/BackupPlan"
- }
- ];
- // The target number of results to return in a single response.
- // If not specified, a default value will be chosen by the service.
- // Note that the response may inclue a partial list and a caller should
- // only rely on the response's
- // [next_page_token][google.cloud.gkebackup.v1.ListBackupsResponse.next_page_token]
- // to determine if there are more instances left to be queried.
- int32 page_size = 2;
- // The value of
- // [next_page_token][google.cloud.gkebackup.v1.ListBackupsResponse.next_page_token]
- // received from a previous `ListBackups` call.
- // Provide this to retrieve the subsequent page in a multi-page list of
- // results. When paginating, all other parameters provided to
- // `ListBackups` must match the call that provided the page token.
- string page_token = 3;
- // Field match expression used to filter the results.
- string filter = 4;
- // Field by which to sort the results.
- string order_by = 5;
- }
- // Response message for ListBackups.
- message ListBackupsResponse {
- // The list of Backups matching the given criteria.
- repeated Backup backups = 1;
- // A token which may be sent as [page_token][google.cloud.gkebackup.v1.ListBackupsRequest.page_token] in
- // a subsequent `ListBackups` call to retrieve the next page of results. If
- // this field is omitted or empty, then there are no more results to return.
- string next_page_token = 2;
- }
- // Request message for GetBackup.
- message GetBackupRequest {
- // Required. Full name of the Backup resource.
- // Format: projects/*/locations/*/backupPlans/*/backups/*
- string name = 1 [
- (google.api.field_behavior) = REQUIRED,
- (google.api.resource_reference) = {
- type: "gkebackup.googleapis.com/Backup"
- }
- ];
- }
- // Request message for UpdateBackup.
- message UpdateBackupRequest {
- // Required. A new version of the Backup resource that contains updated fields.
- // This may be sparsely populated if an `update_mask` is provided.
- Backup backup = 1 [(google.api.field_behavior) = REQUIRED];
- // This is used to specify the fields to be overwritten in the
- // Backup targeted for update. The values for each of these
- // updated fields will be taken from the `backup_plan` provided
- // with this request. Field names are relative to the root of the resource.
- // If no `update_mask` is provided, all fields in `backup` will be
- // written to the target Backup resource.
- // Note that OUTPUT_ONLY and IMMUTABLE fields in `backup` are ignored
- // and are not used to update the target Backup.
- google.protobuf.FieldMask update_mask = 2;
- }
- // Request message for DeleteBackup.
- message DeleteBackupRequest {
- // Required. Name of the Backup resource.
- // Format: projects/*/locations/*/backupPlans/*/backups/*
- string name = 1 [
- (google.api.field_behavior) = REQUIRED,
- (google.api.resource_reference) = {
- type: "gkebackup.googleapis.com/Backup"
- }
- ];
- // If provided, this value must match the current value of the
- // target Backup's [etag][google.cloud.gkebackup.v1.Backup.etag] field or the request is
- // rejected.
- string etag = 2;
- // If set to true, any VolumeBackups below this Backup will also be deleted.
- // Otherwise, the request will only succeed if the Backup has no
- // VolumeBackups.
- bool force = 3;
- }
- // Request message for ListVolumeBackups.
- message ListVolumeBackupsRequest {
- // Required. The Backup that contains the VolumeBackups to list.
- // Format: projects/*/locations/*/backupPlans/*/backups/*
- string parent = 1 [
- (google.api.field_behavior) = REQUIRED,
- (google.api.resource_reference) = {
- type: "gkebackup.googleapis.com/Backup"
- }
- ];
- // The target number of results to return in a single response.
- // If not specified, a default value will be chosen by the service.
- // Note that the response may inclue a partial list and a caller should
- // only rely on the response's
- // [next_page_token][google.cloud.gkebackup.v1.ListVolumeBackupsResponse.next_page_token]
- // to determine if there are more instances left to be queried.
- int32 page_size = 2;
- // The value of
- // [next_page_token][google.cloud.gkebackup.v1.ListVolumeBackupsResponse.next_page_token]
- // received from a previous `ListVolumeBackups` call.
- // Provide this to retrieve the subsequent page in a multi-page list of
- // results. When paginating, all other parameters provided to
- // `ListVolumeBackups` must match the call that provided the page token.
- string page_token = 3;
- // Field match expression used to filter the results.
- string filter = 4;
- // Field by which to sort the results.
- string order_by = 5;
- }
- // Response message for ListVolumeBackups.
- message ListVolumeBackupsResponse {
- // The list of VolumeBackups matching the given criteria.
- repeated VolumeBackup volume_backups = 1;
- // A token which may be sent as
- // [page_token][google.cloud.gkebackup.v1.ListVolumeBackupsRequest.page_token] in a subsequent
- // `ListVolumeBackups` call to retrieve the next page of results.
- // If this field is omitted or empty, then there are no more results to
- // return.
- string next_page_token = 2;
- }
- // Request message for GetVolumeBackup.
- message GetVolumeBackupRequest {
- // Required. Full name of the VolumeBackup resource.
- // Format: projects/*/locations/*/backupPlans/*/backups/*/volumeBackups/*
- string name = 1 [
- (google.api.field_behavior) = REQUIRED,
- (google.api.resource_reference) = {
- type: "gkebackup.googleapis.com/VolumeBackup"
- }
- ];
- }
- // Request message for CreateRestorePlan.
- message CreateRestorePlanRequest {
- // Required. The location within which to create the RestorePlan.
- // Format: projects/*/locations/*
- string parent = 1 [
- (google.api.field_behavior) = REQUIRED,
- (google.api.resource_reference) = {
- type: "locations.googleapis.com/Location"
- }
- ];
- // Required. The RestorePlan resource object to create.
- RestorePlan restore_plan = 2 [(google.api.field_behavior) = REQUIRED];
- // Required. The client-provided short name for the RestorePlan resource.
- // This name must:
- //
- // - be between 1 and 63 characters long (inclusive)
- // - consist of only lower-case ASCII letters, numbers, and dashes
- // - start with a lower-case letter
- // - end with a lower-case letter or number
- // - be unique within the set of RestorePlans in this location
- string restore_plan_id = 3 [(google.api.field_behavior) = REQUIRED];
- }
- // Request message for ListRestorePlans.
- message ListRestorePlansRequest {
- // Required. The location that contains the RestorePlans to list.
- // Format: projects/*/locations/*
- string parent = 1 [
- (google.api.field_behavior) = REQUIRED,
- (google.api.resource_reference) = {
- type: "locations.googleapis.com/Location"
- }
- ];
- // The target number of results to return in a single response.
- // If not specified, a default value will be chosen by the service.
- // Note that the response may inclue a partial list and a caller should
- // only rely on the response's
- // [next_page_token][google.cloud.gkebackup.v1.ListRestorePlansResponse.next_page_token]
- // to determine if there are more instances left to be queried.
- int32 page_size = 2;
- // The value of
- // [next_page_token][google.cloud.gkebackup.v1.ListRestorePlansResponse.next_page_token]
- // received from a previous `ListRestorePlans` call.
- // Provide this to retrieve the subsequent page in a multi-page list of
- // results. When paginating, all other parameters provided to
- // `ListRestorePlans` must match the call that provided the page token.
- string page_token = 3;
- // Field match expression used to filter the results.
- string filter = 4;
- // Field by which to sort the results.
- string order_by = 5;
- }
- // Response message for ListRestorePlans.
- message ListRestorePlansResponse {
- // The list of RestorePlans matching the given criteria.
- repeated RestorePlan restore_plans = 1;
- // A token which may be sent as
- // [page_token][google.cloud.gkebackup.v1.ListRestorePlansRequest.page_token] in a subsequent
- // `ListRestorePlans` call to retrieve the next page of results.
- // If this field is omitted or empty, then there are no more results to
- // return.
- string next_page_token = 2;
- // Locations that could not be reached.
- repeated string unreachable = 3;
- }
- // Request message for GetRestorePlan.
- message GetRestorePlanRequest {
- // Required. Fully qualified RestorePlan name.
- // Format: projects/*/locations/*/restorePlans/*
- string name = 1 [
- (google.api.field_behavior) = REQUIRED,
- (google.api.resource_reference) = {
- type: "gkebackup.googleapis.com/RestorePlan"
- }
- ];
- }
- // Request message for UpdateRestorePlan.
- message UpdateRestorePlanRequest {
- // Required. A new version of the RestorePlan resource that contains updated fields.
- // This may be sparsely populated if an `update_mask` is provided.
- RestorePlan restore_plan = 1 [(google.api.field_behavior) = REQUIRED];
- // This is used to specify the fields to be overwritten in the
- // RestorePlan targeted for update. The values for each of these
- // updated fields will be taken from the `restore_plan` provided
- // with this request. Field names are relative to the root of the resource.
- // If no `update_mask` is provided, all fields in `restore_plan` will be
- // written to the target RestorePlan resource.
- // Note that OUTPUT_ONLY and IMMUTABLE fields in `restore_plan` are ignored
- // and are not used to update the target RestorePlan.
- google.protobuf.FieldMask update_mask = 2;
- }
- // Request message for DeleteRestorePlan.
- message DeleteRestorePlanRequest {
- // Required. Fully qualified RestorePlan name.
- // Format: projects/*/locations/*/restorePlans/*
- string name = 1 [
- (google.api.field_behavior) = REQUIRED,
- (google.api.resource_reference) = {
- type: "gkebackup.googleapis.com/RestorePlan"
- }
- ];
- // If provided, this value must match the current value of the
- // target RestorePlan's [etag][google.cloud.gkebackup.v1.RestorePlan.etag] field or the request is
- // rejected.
- string etag = 2;
- // If set to true, any Restores below this RestorePlan will also be deleted.
- // Otherwise, the request will only succeed if the RestorePlan has no
- // Restores.
- bool force = 3;
- }
- // Request message for CreateRestore.
- message CreateRestoreRequest {
- // Required. The RestorePlan within which to create the Restore.
- // Format: projects/*/locations/*/restorePlans/*
- string parent = 1 [
- (google.api.field_behavior) = REQUIRED,
- (google.api.resource_reference) = {
- type: "gkebackup.googleapis.com/RestorePlan"
- }
- ];
- // Required. The restore resource to create.
- Restore restore = 2 [(google.api.field_behavior) = REQUIRED];
- // Required. The client-provided short name for the Restore resource.
- // This name must:
- //
- // - be between 1 and 63 characters long (inclusive)
- // - consist of only lower-case ASCII letters, numbers, and dashes
- // - start with a lower-case letter
- // - end with a lower-case letter or number
- // - be unique within the set of Restores in this RestorePlan.
- string restore_id = 3 [(google.api.field_behavior) = REQUIRED];
- }
- // Request message for ListRestores.
- message ListRestoresRequest {
- // Required. The RestorePlan that contains the Restores to list.
- // Format: projects/*/locations/*/restorePlans/*
- string parent = 1 [
- (google.api.field_behavior) = REQUIRED,
- (google.api.resource_reference) = {
- type: "gkebackup.googleapis.com/RestorePlan"
- }
- ];
- // The target number of results to return in a single response.
- // If not specified, a default value will be chosen by the service.
- // Note that the response may inclue a partial list and a caller should
- // only rely on the response's
- // [next_page_token][google.cloud.gkebackup.v1.ListRestoresResponse.next_page_token]
- // to determine if there are more instances left to be queried.
- int32 page_size = 2;
- // The value of
- // [next_page_token][google.cloud.gkebackup.v1.ListRestoresResponse.next_page_token]
- // received from a previous `ListRestores` call.
- // Provide this to retrieve the subsequent page in a multi-page list of
- // results. When paginating, all other parameters provided to `ListRestores`
- // must match the call that provided the page token.
- string page_token = 3;
- // Field match expression used to filter the results.
- string filter = 4;
- // Field by which to sort the results.
- string order_by = 5;
- }
- // Response message for ListRestores.
- message ListRestoresResponse {
- // The list of Restores matching the given criteria.
- repeated Restore restores = 1;
- // A token which may be sent as [page_token][google.cloud.gkebackup.v1.ListRestoresRequest.page_token]
- // in a subsequent `ListRestores` call to retrieve the next page of results.
- // If this field is omitted or empty, then there are no more results to
- // return.
- string next_page_token = 2;
- // Locations that could not be reached.
- repeated string unreachable = 3;
- }
- // Request message for GetRestore.
- message GetRestoreRequest {
- // Required. Name of the restore resource.
- // Format: projects/*/locations/*/restorePlans/*/restores/*
- string name = 1 [
- (google.api.field_behavior) = REQUIRED,
- (google.api.resource_reference) = {
- type: "gkebackup.googleapis.com/Restore"
- }
- ];
- }
- // Request message for UpdateRestore.
- message UpdateRestoreRequest {
- // Required. A new version of the Restore resource that contains updated fields.
- // This may be sparsely populated if an `update_mask` is provided.
- Restore restore = 1 [(google.api.field_behavior) = REQUIRED];
- // This is used to specify the fields to be overwritten in the
- // Restore targeted for update. The values for each of these
- // updated fields will be taken from the `restore` provided
- // with this request. Field names are relative to the root of the resource.
- // If no `update_mask` is provided, all fields in `restore` will be
- // written to the target Restore resource.
- // Note that OUTPUT_ONLY and IMMUTABLE fields in `restore` are ignored
- // and are not used to update the target Restore.
- google.protobuf.FieldMask update_mask = 2;
- }
- // Request message for DeleteRestore.
- message DeleteRestoreRequest {
- // Required. Full name of the Restore
- // Format: projects/*/locations/*/restorePlans/*/restores/*
- string name = 1 [
- (google.api.field_behavior) = REQUIRED,
- (google.api.resource_reference) = {
- type: "gkebackup.googleapis.com/Restore"
- }
- ];
- // If provided, this value must match the current value of the
- // target Restore's [etag][google.cloud.gkebackup.v1.Restore.etag] field or the request is
- // rejected.
- string etag = 2;
- // If set to true, any VolumeRestores below this restore will also be deleted.
- // Otherwise, the request will only succeed if the restore has no
- // VolumeRestores.
- bool force = 3;
- }
- // Request message for ListVolumeRestores.
- message ListVolumeRestoresRequest {
- // Required. The Restore that contains the VolumeRestores to list.
- // Format: projects/*/locations/*/restorePlans/*/restores/*
- string parent = 1 [
- (google.api.field_behavior) = REQUIRED,
- (google.api.resource_reference) = {
- type: "gkebackup.googleapis.com/Restore"
- }
- ];
- // The target number of results to return in a single response.
- // If not specified, a default value will be chosen by the service.
- // Note that the response may inclue a partial list and a caller should
- // only rely on the response's
- // [next_page_token][google.cloud.gkebackup.v1.ListVolumeRestoresResponse.next_page_token]
- // to determine if there are more instances left to be queried.
- int32 page_size = 2;
- // The value of
- // [next_page_token][google.cloud.gkebackup.v1.ListVolumeRestoresResponse.next_page_token]
- // received from a previous `ListVolumeRestores` call.
- // Provide this to retrieve the subsequent page in a multi-page list of
- // results. When paginating, all other parameters provided to
- // `ListVolumeRestores` must match the call that provided the page token.
- string page_token = 3;
- // Field match expression used to filter the results.
- string filter = 4;
- // Field by which to sort the results.
- string order_by = 5;
- }
- // Response message for ListVolumeRestores.
- message ListVolumeRestoresResponse {
- // The list of VolumeRestores matching the given criteria.
- repeated VolumeRestore volume_restores = 1;
- // A token which may be sent as
- // [page_token][google.cloud.gkebackup.v1.ListVolumeRestoresRequest.page_token] in a subsequent
- // `ListVolumeRestores` call to retrieve the next page of results.
- // If this field is omitted or empty, then there are no more results to
- // return.
- string next_page_token = 2;
- }
- // Request message for GetVolumeRestore.
- message GetVolumeRestoreRequest {
- // Required. Full name of the VolumeRestore resource.
- // Format: projects/*/locations/*/restorePlans/*/restores/*/volumeRestores/*
- string name = 1 [
- (google.api.field_behavior) = REQUIRED,
- (google.api.resource_reference) = {
- type: "gkebackup.googleapis.com/VolumeRestore"
- }
- ];
- }
|