cloud_redis.proto 24 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634
  1. // Copyright 2020 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. syntax = "proto3";
  15. package google.cloud.redis.v1;
  16. import "google/api/annotations.proto";
  17. import "google/api/client.proto";
  18. import "google/api/field_behavior.proto";
  19. import "google/api/resource.proto";
  20. import "google/longrunning/operations.proto";
  21. import "google/protobuf/field_mask.proto";
  22. import "google/protobuf/timestamp.proto";
  23. option go_package = "google.golang.org/genproto/googleapis/cloud/redis/v1;redis";
  24. option java_multiple_files = true;
  25. option java_outer_classname = "CloudRedisServiceV1Proto";
  26. option java_package = "com.google.cloud.redis.v1";
  27. // Configures and manages Cloud Memorystore for Redis instances
  28. //
  29. // Google Cloud Memorystore for Redis v1
  30. //
  31. // The `redis.googleapis.com` service implements the Google Cloud Memorystore
  32. // for Redis API and defines the following resource model for managing Redis
  33. // instances:
  34. // * The service works with a collection of cloud projects, named: `/projects/*`
  35. // * Each project has a collection of available locations, named: `/locations/*`
  36. // * Each location has a collection of Redis instances, named: `/instances/*`
  37. // * As such, Redis instances are resources of the form:
  38. // `/projects/{project_id}/locations/{location_id}/instances/{instance_id}`
  39. //
  40. // Note that location_id must be referring to a GCP `region`; for example:
  41. // * `projects/redpepper-1290/locations/us-central1/instances/my-redis`
  42. service CloudRedis {
  43. option (google.api.default_host) = "redis.googleapis.com";
  44. option (google.api.oauth_scopes) = "https://www.googleapis.com/auth/cloud-platform";
  45. // Lists all Redis instances owned by a project in either the specified
  46. // location (region) or all locations.
  47. //
  48. // The location should have the following format:
  49. //
  50. // * `projects/{project_id}/locations/{location_id}`
  51. //
  52. // If `location_id` is specified as `-` (wildcard), then all regions
  53. // available to the project are queried, and the results are aggregated.
  54. rpc ListInstances(ListInstancesRequest) returns (ListInstancesResponse) {
  55. option (google.api.http) = {
  56. get: "/v1/{parent=projects/*/locations/*}/instances"
  57. };
  58. option (google.api.method_signature) = "parent";
  59. }
  60. // Gets the details of a specific Redis instance.
  61. rpc GetInstance(GetInstanceRequest) returns (Instance) {
  62. option (google.api.http) = {
  63. get: "/v1/{name=projects/*/locations/*/instances/*}"
  64. };
  65. option (google.api.method_signature) = "name";
  66. }
  67. // Creates a Redis instance based on the specified tier and memory size.
  68. //
  69. // By default, the instance is accessible from the project's
  70. // [default network](https://cloud.google.com/vpc/docs/vpc).
  71. //
  72. // The creation is executed asynchronously and callers may check the returned
  73. // operation to track its progress. Once the operation is completed the Redis
  74. // instance will be fully functional. Completed longrunning.Operation will
  75. // contain the new instance object in the response field.
  76. //
  77. // The returned operation is automatically deleted after a few hours, so there
  78. // is no need to call DeleteOperation.
  79. rpc CreateInstance(CreateInstanceRequest) returns (google.longrunning.Operation) {
  80. option (google.api.http) = {
  81. post: "/v1/{parent=projects/*/locations/*}/instances"
  82. body: "instance"
  83. };
  84. option (google.api.method_signature) = "parent,instance_id,instance";
  85. option (google.longrunning.operation_info) = {
  86. response_type: "google.cloud.redis.v1.Instance"
  87. metadata_type: "google.cloud.redis.v1.OperationMetadata"
  88. };
  89. }
  90. // Updates the metadata and configuration of a specific Redis instance.
  91. //
  92. // Completed longrunning.Operation will contain the new instance object
  93. // in the response field. The returned operation is automatically deleted
  94. // after a few hours, so there is no need to call DeleteOperation.
  95. rpc UpdateInstance(UpdateInstanceRequest) returns (google.longrunning.Operation) {
  96. option (google.api.http) = {
  97. patch: "/v1/{instance.name=projects/*/locations/*/instances/*}"
  98. body: "instance"
  99. };
  100. option (google.api.method_signature) = "update_mask,instance";
  101. option (google.longrunning.operation_info) = {
  102. response_type: "google.cloud.redis.v1.Instance"
  103. metadata_type: "google.cloud.redis.v1.OperationMetadata"
  104. };
  105. }
  106. // Upgrades Redis instance to the newer Redis version specified in the
  107. // request.
  108. rpc UpgradeInstance(UpgradeInstanceRequest) returns (google.longrunning.Operation) {
  109. option (google.api.http) = {
  110. post: "/v1/{name=projects/*/locations/*/instances/*}:upgrade"
  111. body: "*"
  112. };
  113. option (google.api.method_signature) = "name,redis_version";
  114. option (google.longrunning.operation_info) = {
  115. response_type: "google.cloud.redis.v1.Instance"
  116. metadata_type: "google.cloud.redis.v1.OperationMetadata"
  117. };
  118. }
  119. // Import a Redis RDB snapshot file from Cloud Storage into a Redis instance.
  120. //
  121. // Redis may stop serving during this operation. Instance state will be
  122. // IMPORTING for entire operation. When complete, the instance will contain
  123. // only data from the imported file.
  124. //
  125. // The returned operation is automatically deleted after a few hours, so
  126. // there is no need to call DeleteOperation.
  127. rpc ImportInstance(ImportInstanceRequest) returns (google.longrunning.Operation) {
  128. option (google.api.http) = {
  129. post: "/v1/{name=projects/*/locations/*/instances/*}:import"
  130. body: "*"
  131. };
  132. option (google.api.method_signature) = "name,input_config";
  133. option (google.longrunning.operation_info) = {
  134. response_type: "google.cloud.redis.v1.Instance"
  135. metadata_type: "google.cloud.redis.v1.OperationMetadata"
  136. };
  137. }
  138. // Export Redis instance data into a Redis RDB format file in Cloud Storage.
  139. //
  140. // Redis will continue serving during this operation.
  141. //
  142. // The returned operation is automatically deleted after a few hours, so
  143. // there is no need to call DeleteOperation.
  144. rpc ExportInstance(ExportInstanceRequest) returns (google.longrunning.Operation) {
  145. option (google.api.http) = {
  146. post: "/v1/{name=projects/*/locations/*/instances/*}:export"
  147. body: "*"
  148. };
  149. option (google.api.method_signature) = "name,output_config";
  150. option (google.longrunning.operation_info) = {
  151. response_type: "google.cloud.redis.v1.Instance"
  152. metadata_type: "google.cloud.redis.v1.OperationMetadata"
  153. };
  154. }
  155. // Initiates a failover of the master node to current replica node for a
  156. // specific STANDARD tier Cloud Memorystore for Redis instance.
  157. rpc FailoverInstance(FailoverInstanceRequest) returns (google.longrunning.Operation) {
  158. option (google.api.http) = {
  159. post: "/v1/{name=projects/*/locations/*/instances/*}:failover"
  160. body: "*"
  161. };
  162. option (google.api.method_signature) = "name,data_protection_mode";
  163. option (google.longrunning.operation_info) = {
  164. response_type: "google.cloud.redis.v1.Instance"
  165. metadata_type: "google.cloud.redis.v1.OperationMetadata"
  166. };
  167. }
  168. // Deletes a specific Redis instance. Instance stops serving and data is
  169. // deleted.
  170. rpc DeleteInstance(DeleteInstanceRequest) returns (google.longrunning.Operation) {
  171. option (google.api.http) = {
  172. delete: "/v1/{name=projects/*/locations/*/instances/*}"
  173. };
  174. option (google.api.method_signature) = "name";
  175. option (google.longrunning.operation_info) = {
  176. response_type: "google.protobuf.Empty"
  177. metadata_type: "google.cloud.redis.v1.OperationMetadata"
  178. };
  179. }
  180. }
  181. // A Google Cloud Redis instance.
  182. message Instance {
  183. option (google.api.resource) = {
  184. type: "redis.googleapis.com/Instance"
  185. pattern: "projects/{project}/locations/{location}/instances/{instance}"
  186. };
  187. // Represents the different states of a Redis instance.
  188. enum State {
  189. // Not set.
  190. STATE_UNSPECIFIED = 0;
  191. // Redis instance is being created.
  192. CREATING = 1;
  193. // Redis instance has been created and is fully usable.
  194. READY = 2;
  195. // Redis instance configuration is being updated. Certain kinds of updates
  196. // may cause the instance to become unusable while the update is in
  197. // progress.
  198. UPDATING = 3;
  199. // Redis instance is being deleted.
  200. DELETING = 4;
  201. // Redis instance is being repaired and may be unusable.
  202. REPAIRING = 5;
  203. // Maintenance is being performed on this Redis instance.
  204. MAINTENANCE = 6;
  205. // Redis instance is importing data (availability may be affected).
  206. IMPORTING = 8;
  207. // Redis instance is failing over (availability may be affected).
  208. FAILING_OVER = 9;
  209. }
  210. // Available service tiers to choose from
  211. enum Tier {
  212. // Not set.
  213. TIER_UNSPECIFIED = 0;
  214. // BASIC tier: standalone instance
  215. BASIC = 1;
  216. // STANDARD_HA tier: highly available primary/replica instances
  217. STANDARD_HA = 3;
  218. }
  219. // Available connection modes.
  220. enum ConnectMode {
  221. // Not set.
  222. CONNECT_MODE_UNSPECIFIED = 0;
  223. // Connect via direct peering to the Memorystore for Redis hosted service.
  224. DIRECT_PEERING = 1;
  225. // Connect your Memorystore for Redis instance using Private Service
  226. // Access. Private services access provides an IP address range for multiple
  227. // Google Cloud services, including Memorystore.
  228. PRIVATE_SERVICE_ACCESS = 2;
  229. }
  230. // Required. Unique name of the resource in this scope including project and
  231. // location using the form:
  232. // `projects/{project_id}/locations/{location_id}/instances/{instance_id}`
  233. //
  234. // Note: Redis instances are managed and addressed at regional level so
  235. // location_id here refers to a GCP region; however, users may choose which
  236. // specific zone (or collection of zones for cross-zone instances) an instance
  237. // should be provisioned in. Refer to [location_id][google.cloud.redis.v1.Instance.location_id] and
  238. // [alternative_location_id][google.cloud.redis.v1.Instance.alternative_location_id] fields for more details.
  239. string name = 1 [(google.api.field_behavior) = REQUIRED];
  240. // An arbitrary and optional user-provided name for the instance.
  241. string display_name = 2;
  242. // Resource labels to represent user provided metadata
  243. map<string, string> labels = 3;
  244. // Optional. The zone where the instance will be provisioned. If not provided,
  245. // the service will choose a zone for the instance. For STANDARD_HA tier,
  246. // instances will be created across two zones for protection against zonal
  247. // failures. If [alternative_location_id][google.cloud.redis.v1.Instance.alternative_location_id] is also provided, it must be
  248. // different from [location_id][google.cloud.redis.v1.Instance.location_id].
  249. string location_id = 4 [(google.api.field_behavior) = OPTIONAL];
  250. // Optional. Only applicable to STANDARD_HA tier which protects the instance
  251. // against zonal failures by provisioning it across two zones. If provided, it
  252. // must be a different zone from the one provided in [location_id][google.cloud.redis.v1.Instance.location_id].
  253. string alternative_location_id = 5 [(google.api.field_behavior) = OPTIONAL];
  254. // Optional. The version of Redis software.
  255. // If not provided, latest supported version will be used. Currently, the
  256. // supported values are:
  257. //
  258. // * `REDIS_3_2` for Redis 3.2 compatibility
  259. // * `REDIS_4_0` for Redis 4.0 compatibility (default)
  260. // * `REDIS_5_0` for Redis 5.0 compatibility
  261. string redis_version = 7 [(google.api.field_behavior) = OPTIONAL];
  262. // Optional. The CIDR range of internal addresses that are reserved for this
  263. // instance. If not provided, the service will choose an unused /29 block,
  264. // for example, 10.0.0.0/29 or 192.168.0.0/29. Ranges must be unique
  265. // and non-overlapping with existing subnets in an authorized network.
  266. string reserved_ip_range = 9 [(google.api.field_behavior) = OPTIONAL];
  267. // Output only. Hostname or IP address of the exposed Redis endpoint used by
  268. // clients to connect to the service.
  269. string host = 10 [(google.api.field_behavior) = OUTPUT_ONLY];
  270. // Output only. The port number of the exposed Redis endpoint.
  271. int32 port = 11 [(google.api.field_behavior) = OUTPUT_ONLY];
  272. // Output only. The current zone where the Redis endpoint is placed. For Basic
  273. // Tier instances, this will always be the same as the [location_id][google.cloud.redis.v1.Instance.location_id]
  274. // provided by the user at creation time. For Standard Tier instances,
  275. // this can be either [location_id][google.cloud.redis.v1.Instance.location_id] or [alternative_location_id][google.cloud.redis.v1.Instance.alternative_location_id] and can
  276. // change after a failover event.
  277. string current_location_id = 12 [(google.api.field_behavior) = OUTPUT_ONLY];
  278. // Output only. The time the instance was created.
  279. google.protobuf.Timestamp create_time = 13 [(google.api.field_behavior) = OUTPUT_ONLY];
  280. // Output only. The current state of this instance.
  281. State state = 14 [(google.api.field_behavior) = OUTPUT_ONLY];
  282. // Output only. Additional information about the current status of this
  283. // instance, if available.
  284. string status_message = 15 [(google.api.field_behavior) = OUTPUT_ONLY];
  285. // Optional. Redis configuration parameters, according to
  286. // http://redis.io/topics/config. Currently, the only supported parameters
  287. // are:
  288. //
  289. // Redis version 3.2 and newer:
  290. //
  291. // * maxmemory-policy
  292. // * notify-keyspace-events
  293. //
  294. // Redis version 4.0 and newer:
  295. //
  296. // * activedefrag
  297. // * lfu-decay-time
  298. // * lfu-log-factor
  299. // * maxmemory-gb
  300. //
  301. // Redis version 5.0 and newer:
  302. //
  303. // * stream-node-max-bytes
  304. // * stream-node-max-entries
  305. map<string, string> redis_configs = 16 [(google.api.field_behavior) = OPTIONAL];
  306. // Required. The service tier of the instance.
  307. Tier tier = 17 [(google.api.field_behavior) = REQUIRED];
  308. // Required. Redis memory size in GiB.
  309. int32 memory_size_gb = 18 [(google.api.field_behavior) = REQUIRED];
  310. // Optional. The full name of the Google Compute Engine
  311. // [network](https://cloud.google.com/vpc/docs/vpc) to which the
  312. // instance is connected. If left unspecified, the `default` network
  313. // will be used.
  314. string authorized_network = 20 [(google.api.field_behavior) = OPTIONAL];
  315. // Output only. Cloud IAM identity used by import / export operations to
  316. // transfer data to/from Cloud Storage. Format is
  317. // "serviceAccount:<service_account_email>". The value may change over time
  318. // for a given instance so should be checked before each import/export
  319. // operation.
  320. string persistence_iam_identity = 21 [(google.api.field_behavior) = OUTPUT_ONLY];
  321. // Optional. The network connect mode of the Redis instance.
  322. // If not provided, the connect mode defaults to DIRECT_PEERING.
  323. ConnectMode connect_mode = 22 [(google.api.field_behavior) = OPTIONAL];
  324. }
  325. // Request for [ListInstances][google.cloud.redis.v1.CloudRedis.ListInstances].
  326. message ListInstancesRequest {
  327. // Required. The resource name of the instance location using the form:
  328. // `projects/{project_id}/locations/{location_id}`
  329. // where `location_id` refers to a GCP region.
  330. string parent = 1 [
  331. (google.api.field_behavior) = REQUIRED,
  332. (google.api.resource_reference) = {
  333. type: "locations.googleapis.com/Location"
  334. }
  335. ];
  336. // The maximum number of items to return.
  337. //
  338. // If not specified, a default value of 1000 will be used by the service.
  339. // Regardless of the page_size value, the response may include a partial list
  340. // and a caller should only rely on response's
  341. // [`next_page_token`][google.cloud.redis.v1.ListInstancesResponse.next_page_token]
  342. // to determine if there are more instances left to be queried.
  343. int32 page_size = 2;
  344. // The `next_page_token` value returned from a previous
  345. // [ListInstances][google.cloud.redis.v1.CloudRedis.ListInstances] request, if any.
  346. string page_token = 3;
  347. }
  348. // Response for [ListInstances][google.cloud.redis.v1.CloudRedis.ListInstances].
  349. message ListInstancesResponse {
  350. // A list of Redis instances in the project in the specified location,
  351. // or across all locations.
  352. //
  353. // If the `location_id` in the parent field of the request is "-", all regions
  354. // available to the project are queried, and the results aggregated.
  355. // If in such an aggregated query a location is unavailable, a dummy Redis
  356. // entry is included in the response with the `name` field set to a value of
  357. // the form `projects/{project_id}/locations/{location_id}/instances/`- and
  358. // the `status` field set to ERROR and `status_message` field set to "location
  359. // not available for ListInstances".
  360. repeated Instance instances = 1;
  361. // Token to retrieve the next page of results, or empty if there are no more
  362. // results in the list.
  363. string next_page_token = 2;
  364. // Locations that could not be reached.
  365. repeated string unreachable = 3;
  366. }
  367. // Request for [GetInstance][google.cloud.redis.v1.CloudRedis.GetInstance].
  368. message GetInstanceRequest {
  369. // Required. Redis instance resource name using the form:
  370. // `projects/{project_id}/locations/{location_id}/instances/{instance_id}`
  371. // where `location_id` refers to a GCP region.
  372. string name = 1 [
  373. (google.api.field_behavior) = REQUIRED,
  374. (google.api.resource_reference) = {
  375. type: "redis.googleapis.com/Instance"
  376. }
  377. ];
  378. }
  379. // Request for [CreateInstance][google.cloud.redis.v1.CloudRedis.CreateInstance].
  380. message CreateInstanceRequest {
  381. // Required. The resource name of the instance location using the form:
  382. // `projects/{project_id}/locations/{location_id}`
  383. // where `location_id` refers to a GCP region.
  384. string parent = 1 [
  385. (google.api.field_behavior) = REQUIRED,
  386. (google.api.resource_reference) = {
  387. type: "locations.googleapis.com/Location"
  388. }
  389. ];
  390. // Required. The logical name of the Redis instance in the customer project
  391. // with the following restrictions:
  392. //
  393. // * Must contain only lowercase letters, numbers, and hyphens.
  394. // * Must start with a letter.
  395. // * Must be between 1-40 characters.
  396. // * Must end with a number or a letter.
  397. // * Must be unique within the customer project / location
  398. string instance_id = 2 [(google.api.field_behavior) = REQUIRED];
  399. // Required. A Redis [Instance] resource
  400. Instance instance = 3 [(google.api.field_behavior) = REQUIRED];
  401. }
  402. // Request for [UpdateInstance][google.cloud.redis.v1.CloudRedis.UpdateInstance].
  403. message UpdateInstanceRequest {
  404. // Required. Mask of fields to update. At least one path must be supplied in
  405. // this field. The elements of the repeated paths field may only include these
  406. // fields from [Instance][google.cloud.redis.v1.Instance]:
  407. //
  408. // * `displayName`
  409. // * `labels`
  410. // * `memorySizeGb`
  411. // * `redisConfig`
  412. google.protobuf.FieldMask update_mask = 1 [(google.api.field_behavior) = REQUIRED];
  413. // Required. Update description.
  414. // Only fields specified in update_mask are updated.
  415. Instance instance = 2 [(google.api.field_behavior) = REQUIRED];
  416. }
  417. // Request for [UpgradeInstance][google.cloud.redis.v1.CloudRedis.UpgradeInstance].
  418. message UpgradeInstanceRequest {
  419. // Required. Redis instance resource name using the form:
  420. // `projects/{project_id}/locations/{location_id}/instances/{instance_id}`
  421. // where `location_id` refers to a GCP region.
  422. string name = 1 [
  423. (google.api.field_behavior) = REQUIRED,
  424. (google.api.resource_reference) = {
  425. type: "redis.googleapis.com/Instance"
  426. }
  427. ];
  428. // Required. Specifies the target version of Redis software to upgrade to.
  429. string redis_version = 2 [(google.api.field_behavior) = REQUIRED];
  430. }
  431. // Request for [DeleteInstance][google.cloud.redis.v1.CloudRedis.DeleteInstance].
  432. message DeleteInstanceRequest {
  433. // Required. Redis instance resource name using the form:
  434. // `projects/{project_id}/locations/{location_id}/instances/{instance_id}`
  435. // where `location_id` refers to a GCP region.
  436. string name = 1 [
  437. (google.api.field_behavior) = REQUIRED,
  438. (google.api.resource_reference) = {
  439. type: "redis.googleapis.com/Instance"
  440. }
  441. ];
  442. }
  443. // The Cloud Storage location for the input content
  444. message GcsSource {
  445. // Required. Source data URI. (e.g. 'gs://my_bucket/my_object').
  446. string uri = 1 [(google.api.field_behavior) = REQUIRED];
  447. }
  448. // The input content
  449. message InputConfig {
  450. // Required. Specify source location of input data
  451. oneof source {
  452. // Google Cloud Storage location where input content is located.
  453. GcsSource gcs_source = 1;
  454. }
  455. }
  456. // Request for [Import][google.cloud.redis.v1.CloudRedis.ImportInstance].
  457. message ImportInstanceRequest {
  458. // Required. Redis instance resource name using the form:
  459. // `projects/{project_id}/locations/{location_id}/instances/{instance_id}`
  460. // where `location_id` refers to a GCP region.
  461. string name = 1 [(google.api.field_behavior) = REQUIRED];
  462. // Required. Specify data to be imported.
  463. InputConfig input_config = 3 [(google.api.field_behavior) = REQUIRED];
  464. }
  465. // The Cloud Storage location for the output content
  466. message GcsDestination {
  467. // Required. Data destination URI (e.g.
  468. // 'gs://my_bucket/my_object'). Existing files will be overwritten.
  469. string uri = 1 [(google.api.field_behavior) = REQUIRED];
  470. }
  471. // The output content
  472. message OutputConfig {
  473. // Required. Specify destination location of output data
  474. oneof destination {
  475. // Google Cloud Storage destination for output content.
  476. GcsDestination gcs_destination = 1;
  477. }
  478. }
  479. // Request for [Export][google.cloud.redis.v1.CloudRedis.ExportInstance].
  480. message ExportInstanceRequest {
  481. // Required. Redis instance resource name using the form:
  482. // `projects/{project_id}/locations/{location_id}/instances/{instance_id}`
  483. // where `location_id` refers to a GCP region.
  484. string name = 1 [(google.api.field_behavior) = REQUIRED];
  485. // Required. Specify data to be exported.
  486. OutputConfig output_config = 3 [(google.api.field_behavior) = REQUIRED];
  487. }
  488. // Request for [Failover][google.cloud.redis.v1.CloudRedis.FailoverInstance].
  489. message FailoverInstanceRequest {
  490. // Specifies different modes of operation in relation to the data retention.
  491. enum DataProtectionMode {
  492. // Defaults to LIMITED_DATA_LOSS if a data protection mode is not
  493. // specified.
  494. DATA_PROTECTION_MODE_UNSPECIFIED = 0;
  495. // Instance failover will be protected with data loss control. More
  496. // specifically, the failover will only be performed if the current
  497. // replication offset diff between master and replica is under a certain
  498. // threshold.
  499. LIMITED_DATA_LOSS = 1;
  500. // Instance failover will be performed without data loss control.
  501. FORCE_DATA_LOSS = 2;
  502. }
  503. // Required. Redis instance resource name using the form:
  504. // `projects/{project_id}/locations/{location_id}/instances/{instance_id}`
  505. // where `location_id` refers to a GCP region.
  506. string name = 1 [
  507. (google.api.field_behavior) = REQUIRED,
  508. (google.api.resource_reference) = {
  509. type: "redis.googleapis.com/Instance"
  510. }
  511. ];
  512. // Optional. Available data protection modes that the user can choose. If it's
  513. // unspecified, data protection mode will be LIMITED_DATA_LOSS by default.
  514. DataProtectionMode data_protection_mode = 2 [(google.api.field_behavior) = OPTIONAL];
  515. }
  516. // Represents the v1 metadata of the long-running operation.
  517. message OperationMetadata {
  518. // Creation timestamp.
  519. google.protobuf.Timestamp create_time = 1;
  520. // End timestamp.
  521. google.protobuf.Timestamp end_time = 2;
  522. // Operation target.
  523. string target = 3;
  524. // Operation verb.
  525. string verb = 4;
  526. // Operation status details.
  527. string status_detail = 5;
  528. // Specifies if cancellation was requested for the operation.
  529. bool cancel_requested = 6;
  530. // API version.
  531. string api_version = 7;
  532. }
  533. // This location metadata represents additional configuration options for a
  534. // given location where a Redis instance may be created. All fields are output
  535. // only. It is returned as content of the
  536. // `google.cloud.location.Location.metadata` field.
  537. message LocationMetadata {
  538. // Output only. The set of available zones in the location. The map is keyed
  539. // by the lowercase ID of each zone, as defined by GCE. These keys can be
  540. // specified in `location_id` or `alternative_location_id` fields when
  541. // creating a Redis instance.
  542. map<string, ZoneMetadata> available_zones = 1 [(google.api.field_behavior) = OUTPUT_ONLY];
  543. }
  544. // Defines specific information for a particular zone. Currently empty and
  545. // reserved for future use only.
  546. message ZoneMetadata {
  547. }