Synchronize new proto/yaml changes.

PiperOrigin-RevId: 251157279
This commit is contained in:
Google APIs 2019-06-02 20:20:23 -07:00 committed by Copybara-Service
parent a8ee1416f4
commit 797024a0a3
4 changed files with 199 additions and 70 deletions

View File

@ -3,7 +3,7 @@ common:
api_version: v1
organization_name: google-cloud
proto_deps:
- name: google-common-protos
- name: google-common-protos
src_proto_paths:
- v1
service_yaml: redis_v1.yaml

View File

@ -4,40 +4,22 @@ name: redis.googleapis.com
title: Google Cloud Memorystore for Redis API
apis:
- name: google.cloud.redis.v1.CloudRedis
- name: google.cloud.redis.v1.CloudRedis
types:
- name: google.cloud.redis.v1.LocationMetadata
- name: google.cloud.redis.v1.OperationMetadata
- name: google.cloud.redis.v1.ZoneMetadata
- name: google.cloud.redis.v1.LocationMetadata
- name: google.cloud.redis.v1.OperationMetadata
- name: google.cloud.redis.v1.ZoneMetadata
documentation:
summary: Creates and manages Redis instances on the Google Cloud Platform.
backend:
rules:
- selector: google.longrunning.Operations.ListOperations
deadline: 60.0
- selector: google.longrunning.Operations.GetOperation
deadline: 60.0
- selector: google.longrunning.Operations.DeleteOperation
deadline: 60.0
- selector: google.longrunning.Operations.CancelOperation
deadline: 60.0
- selector: google.longrunning.Operations.WaitOperation
deadline: 60.0
- selector: google.cloud.redis.v1.CloudRedis.ListInstances
deadline: 60.0
- selector: google.cloud.redis.v1.CloudRedis.GetInstance
deadline: 60.0
- selector: google.cloud.redis.v1.CloudRedis.CreateInstance
deadline: 60.0
- selector: google.cloud.redis.v1.CloudRedis.UpdateInstance
deadline: 60.0
- selector: google.cloud.redis.v1.CloudRedis.FailoverInstance
deadline: 60.0
- selector: google.cloud.redis.v1.CloudRedis.DeleteInstance
deadline: 60.0
- selector: 'google.cloud.redis.v1.CloudRedis.*'
deadline: 60.0
- selector: 'google.longrunning.Operations.*'
deadline: 60.0
http:
rules:
@ -55,11 +37,11 @@ http:
authentication:
rules:
- selector: 'google.cloud.redis.v1.CloudRedis.*'
oauth:
canonical_scopes: |-
https://www.googleapis.com/auth/cloud-platform
- selector: 'google.longrunning.Operations.*'
oauth:
canonical_scopes: |-
https://www.googleapis.com/auth/cloud-platform
- selector: 'google.cloud.redis.v1.CloudRedis.*'
oauth:
canonical_scopes: |-
https://www.googleapis.com/auth/cloud-platform
- selector: 'google.longrunning.Operations.*'
oauth:
canonical_scopes: |-
https://www.googleapis.com/auth/cloud-platform

View File

@ -18,17 +18,16 @@ syntax = "proto3";
package google.cloud.redis.v1;
import "google/api/annotations.proto";
import "google/api/resource.proto";
import "google/longrunning/operations.proto";
import "google/protobuf/field_mask.proto";
import "google/protobuf/timestamp.proto";
import "google/api/client.proto";
option go_package = "google.golang.org/genproto/googleapis/cloud/redis/v1;redis";
option java_multiple_files = true;
option java_outer_classname = "CloudRedisServiceV1Proto";
option java_package = "com.google.cloud.redis.v1";
// Configures and manages Cloud Memorystore for Redis instances
//
// Google Cloud Memorystore for Redis v1
@ -45,6 +44,8 @@ option java_package = "com.google.cloud.redis.v1";
// Note that location_id must be referring to a GCP `region`; for example:
// * `projects/redpepper-1290/locations/us-central1/instances/my-redis`
service CloudRedis {
option (google.api.default_host) = "redis.googleapis.com";
// Lists all Redis instances owned by a project in either the specified
// location (region) or all locations.
//
@ -97,8 +98,36 @@ service CloudRedis {
};
}
// Failover the master role to current replica node against a specific
// STANDARD tier redis instance.
// Import a Redis RDB snapshot file from Cloud Storage into a Redis instance.
//
// Redis may stop serving during this operation. Instance state will be
// IMPORTING for entire operation. When complete, the instance will contain
// only data from the imported file.
//
// The returned operation is automatically deleted after a few hours, so
// there is no need to call DeleteOperation.
rpc ImportInstance(ImportInstanceRequest) returns (google.longrunning.Operation) {
option (google.api.http) = {
post: "/v1/{name=projects/*/locations/*/instances/*}:import"
body: "*"
};
}
// Export Redis instance data into a Redis RDB format file in Cloud Storage.
//
// Redis will continue serving during this operation.
//
// The returned operation is automatically deleted after a few hours, so
// there is no need to call DeleteOperation.
rpc ExportInstance(ExportInstanceRequest) returns (google.longrunning.Operation) {
option (google.api.http) = {
post: "/v1/{name=projects/*/locations/*/instances/*}:export"
body: "*"
};
}
// Initiates a failover of the master node to current replica node for a
// specific STANDARD tier Cloud Memorystore for Redis instance.
rpc FailoverInstance(FailoverInstanceRequest) returns (google.longrunning.Operation) {
option (google.api.http) = {
post: "/v1/{name=projects/*/locations/*/instances/*}:failover"
@ -142,6 +171,9 @@ message Instance {
// Maintenance is being performed on this Redis instance.
MAINTENANCE = 6;
// Redis instance is importing data (availability may be affected).
IMPORTING = 8;
// Redis instance is failing over (availability may be affected).
FAILING_OVER = 9;
}
@ -190,7 +222,10 @@ message Instance {
// Optional. The version of Redis software.
// If not provided, latest supported version will be used. Updating the
// version will perform an upgrade/downgrade to the new version. Currently,
// the supported values are `REDIS_3_2` for Redis 3.2.
// the supported values are:
//
// * `REDIS_4_0` for Redis 4.0 compatibility (default)
// * `REDIS_3_2` for Redis 3.2 compatibility
string redis_version = 7;
// Optional. The CIDR range of internal addresses that are reserved for this
@ -227,8 +262,16 @@ message Instance {
// http://redis.io/topics/config. Currently, the only supported parameters
// are:
//
// Redis 3.2 and above:
//
// * maxmemory-policy
// * notify-keyspace-events
//
// Redis 4.0 and above:
//
// * activedefrag
// * lfu-log-factor
// * lfu-decay-time
map<string, string> redis_configs = 16;
// Required. The service tier of the instance.
@ -242,13 +285,20 @@ message Instance {
// instance is connected. If left unspecified, the `default` network
// will be used.
string authorized_network = 20;
// Output only. Cloud IAM identity used by import / export operations to
// transfer data to/from Cloud Storage. Format is
// "serviceAccount:<service_account_email>". The value may change over time
// for a given instance so should be checked before each import/export
// operation.
string persistence_iam_identity = 21;
}
// Request for [ListInstances][google.cloud.redis.v1.CloudRedis.ListInstances].
message ListInstancesRequest {
// Required. The resource name of the instance location using the form:
// `projects/{project_id}/locations/{location_id}`
// where `location_id` refers to a GCP region
// where `location_id` refers to a GCP region.
string parent = 1;
// The maximum number of items to return.
@ -291,7 +341,7 @@ message ListInstancesResponse {
message GetInstanceRequest {
// Required. Redis instance resource name using the form:
// `projects/{project_id}/locations/{location_id}/instances/{instance_id}`
// where `location_id` refers to a GCP region
// where `location_id` refers to a GCP region.
string name = 1;
}
@ -299,7 +349,7 @@ message GetInstanceRequest {
message CreateInstanceRequest {
// Required. The resource name of the instance location using the form:
// `projects/{project_id}/locations/{location_id}`
// where `location_id` refers to a GCP region
// where `location_id` refers to a GCP region.
string parent = 1;
// Required. The logical name of the Redis instance in the customer project
@ -337,13 +387,68 @@ message UpdateInstanceRequest {
message DeleteInstanceRequest {
// Required. Redis instance resource name using the form:
// `projects/{project_id}/locations/{location_id}/instances/{instance_id}`
// where `location_id` refers to a GCP region
// where `location_id` refers to a GCP region.
string name = 1;
}
// The Cloud Storage location for the input content
message GcsSource {
// Required. Source data URI. (e.g. 'gs://my_bucket/my_object').
string uri = 1;
}
// The input content
message InputConfig {
// Required. Specify source location of input data
oneof source {
// Google Cloud Storage location where input content is located.
GcsSource gcs_source = 1;
}
}
// Request for [Import][google.cloud.redis.v1.CloudRedis.ImportInstance].
message ImportInstanceRequest {
// Required. Redis instance resource name using the form:
// `projects/{project_id}/locations/{location_id}/instances/{instance_id}`
// where `location_id` refers to a GCP region.
string name = 1;
// Required. Specify data to be imported.
InputConfig input_config = 3;
}
// The Cloud Storage location for the output content
message GcsDestination {
// Required. Data destination URI (e.g.
// 'gs://my_bucket/my_object'). Existing files will be overwritten.
string uri = 1;
}
// The output content
message OutputConfig {
// Required. Specify destination location of output data
oneof destination {
// Google Cloud Storage destination for output content.
GcsDestination gcs_destination = 1;
}
}
// Request for [Export][google.cloud.redis.v1.CloudRedis.ExportInstance].
message ExportInstanceRequest {
// Required. Redis instance resource name using the form:
// `projects/{project_id}/locations/{location_id}/instances/{instance_id}`
// where `location_id` refers to a GCP region.
string name = 1;
// Required. Specify data to be exported.
OutputConfig output_config = 3;
}
// Request for [Failover][google.cloud.redis.v1.CloudRedis.FailoverInstance].
message FailoverInstanceRequest {
enum DataProtectionMode {
// Defaults to LIMITED_DATA_LOSS if a data protection mode is not
// specified.
DATA_PROTECTION_MODE_UNSPECIFIED = 0;
// Instance failover will be protected with data loss control. More
@ -358,7 +463,7 @@ message FailoverInstanceRequest {
// Required. Redis instance resource name using the form:
// `projects/{project_id}/locations/{location_id}/instances/{instance_id}`
// where `location_id` refers to a GCP region
// where `location_id` refers to a GCP region.
string name = 1;
// Optional. Available data protection modes that the user can choose. If it's

View File

@ -18,7 +18,7 @@ language_settings:
package_name: redis.v1
# A list of API interface configurations.
interfaces:
# The fully qualified name of the API interface.
# The fully qualified name of the API interface.
- name: google.cloud.redis.v1.CloudRedis
# A list of resource collection configurations.
# Consists of a name_pattern and an entity_name.
@ -157,18 +157,18 @@ interfaces:
retry_params_name: default
field_name_patterns:
parent: location
timeout_millis: 60000
long_running:
return_type: google.cloud.redis.v1.Instance
metadata_type: google.cloud.redis.v1.OperationMetadata
initial_poll_delay_millis: 60000 # 1 minutes
initial_poll_delay_millis: 60000 # 1 minutes
poll_delay_multiplier: 1.5
max_poll_delay_millis: 360000 # 6 minutes
total_poll_timeout_millis: 1200000 # 20 minutes
max_poll_delay_millis: 360000 # 6 minutes
total_poll_timeout_millis: 1200000 # 20 minutes
timeout_millis: 60000
sample_code_init_fields:
- instance_id="test_instance"
- instance.tier="BASIC"
- instance.memory_size_gb=1
- instance_id="test_instance"
- instance.tier="BASIC"
- instance.memory_size_gb=1
- name: UpdateInstance
resource_name_treatment: STATIC_TYPES
flattening:
@ -183,39 +183,61 @@ interfaces:
retry_params_name: default
field_name_patterns:
instance.name: instance
timeout_millis: 60000
long_running:
return_type: google.cloud.redis.v1.Instance
metadata_type: google.cloud.redis.v1.OperationMetadata
initial_poll_delay_millis: 60000 # 1 minutes
initial_poll_delay_millis: 60000 # 1 minutes
poll_delay_multiplier: 1.5
max_poll_delay_millis: 360000 # 6 minutes
total_poll_timeout_millis: 7200000 # 120 minutes
max_poll_delay_millis: 360000 # 6 minutes
total_poll_timeout_millis: 7200000 # 120 minutes
timeout_millis: 60000
sample_code_init_fields:
- update_mask.paths[0]="display_name"
- update_mask.paths[1]="memory_size_gb"
- instance.display_name="UpdatedDisplayName"
- update_mask.paths[0]="display_name"
- update_mask.paths[1]="memory_size_gb"
- instance.display_name="UpdatedDisplayName"
- instance.memory_size_gb=4
- name: DeleteInstance
- name: ImportInstance
flattening:
groups:
- parameters:
- name
- input_config
required_fields:
- name
resource_name_treatment: STATIC_TYPES
- input_config
retry_codes_name: non_idempotent
retry_params_name: default
field_name_patterns:
name: instance
timeout_millis: 60000
long_running:
return_type: google.protobuf.Empty
return_type: google.cloud.redis.v1.Instance
metadata_type: google.cloud.redis.v1.OperationMetadata
initial_poll_delay_millis: 60000 # 1 minutes
initial_poll_delay_millis: 60000 # 1 minutes
poll_delay_multiplier: 1.5
max_poll_delay_millis: 360000 # 6 minutes
total_poll_timeout_millis: 1200000 # 20 minutes
max_poll_delay_millis: 360000 # 6 minutes
total_poll_timeout_millis: 18000000 # 300 minutes
timeout_millis: 60000
- name: ExportInstance
flattening:
groups:
- parameters:
- name
- output_config
required_fields:
- name
- output_config
retry_codes_name: non_idempotent
retry_params_name: default
field_name_patterns:
name: instance
long_running:
return_type: google.cloud.redis.v1.Instance
metadata_type: google.cloud.redis.v1.OperationMetadata
initial_poll_delay_millis: 60000 # 1 minutes
poll_delay_multiplier: 1.5
max_poll_delay_millis: 360000 # 6 minutes
total_poll_timeout_millis: 18000000 # 300 minutes
timeout_millis: 60000
- name: FailoverInstance
flattening:
groups:
@ -233,10 +255,30 @@ interfaces:
long_running:
return_type: google.cloud.redis.v1.Instance
metadata_type: google.cloud.redis.v1.OperationMetadata
initial_poll_delay_millis: 60000 # 1 minutes
initial_poll_delay_millis: 60000 # 1 minutes
poll_delay_multiplier: 1.5
max_poll_delay_millis: 360000 # 6 minutes
total_poll_timeout_millis: 1200000 # 20 minutes
max_poll_delay_millis: 360000 # 6 minutes
total_poll_timeout_millis: 1200000 # 20 minutes
timeout_millis: 60000
- name: DeleteInstance
flattening:
groups:
- parameters:
- name
required_fields:
- name
resource_name_treatment: STATIC_TYPES
retry_codes_name: non_idempotent
retry_params_name: default
field_name_patterns:
name: instance
long_running:
return_type: google.protobuf.Empty
metadata_type: google.cloud.redis.v1.OperationMetadata
initial_poll_delay_millis: 60000 # 1 minutes
poll_delay_multiplier: 1.5
max_poll_delay_millis: 360000 # 6 minutes
total_poll_timeout_millis: 1200000 # 20 minutes
timeout_millis: 60000
resource_name_generation:
- message_name: ListInstancesRequest