blob: cfeb388ebe748013fe9dd01bb747e1bc2a9aa19e [file] [log] [blame]
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001<html><body>
2<style>
3
4body, h1, h2, h3, div, span, p, pre, a {
5 margin: 0;
6 padding: 0;
7 border: 0;
8 font-weight: inherit;
9 font-style: inherit;
10 font-size: 100%;
11 font-family: inherit;
12 vertical-align: baseline;
13}
14
15body {
16 font-size: 13px;
17 padding: 1em;
18}
19
20h1 {
21 font-size: 26px;
22 margin-bottom: 1em;
23}
24
25h2 {
26 font-size: 24px;
27 margin-bottom: 1em;
28}
29
30h3 {
31 font-size: 20px;
32 margin-bottom: 1em;
33 margin-top: 1em;
34}
35
36pre, code {
37 line-height: 1.5;
38 font-family: Monaco, 'DejaVu Sans Mono', 'Bitstream Vera Sans Mono', 'Lucida Console', monospace;
39}
40
41pre {
42 margin-top: 0.5em;
43}
44
45h1, h2, h3, p {
46 font-family: Arial, sans serif;
47}
48
49h1, h2, h3 {
50 border-bottom: solid #CCC 1px;
51}
52
53.toc_element {
54 margin-top: 0.5em;
55}
56
57.firstline {
58 margin-left: 2 em;
59}
60
61.method {
62 margin-top: 1em;
63 border: solid 1px #CCC;
64 padding: 1em;
65 background: #EEE;
66}
67
68.details {
69 font-weight: bold;
70 font-size: 14px;
71}
72
73</style>
74
75<h1><a href="redis_v1beta1.html">Google Cloud Memorystore for Redis API</a> . <a href="redis_v1beta1.projects.html">projects</a> . <a href="redis_v1beta1.projects.locations.html">locations</a> . <a href="redis_v1beta1.projects.locations.instances.html">instances</a></h1>
76<h2>Instance Methods</h2>
77<p class="toc_element">
Dan O'Mearadd494642020-05-01 07:42:23 -070078 <code><a href="#create">create(parent, body=None, instanceId=None, x__xgafv=None)</a></code></p>
Bu Sun Kim715bd7f2019-06-14 16:50:42 -070079<p class="firstline">Creates a Redis instance based on the specified tier and memory size.</p>
80<p class="toc_element">
81 <code><a href="#delete">delete(name, x__xgafv=None)</a></code></p>
82<p class="firstline">Deletes a specific Redis instance. Instance stops serving and data is</p>
83<p class="toc_element">
Dan O'Mearadd494642020-05-01 07:42:23 -070084 <code><a href="#export">export(name, body=None, x__xgafv=None)</a></code></p>
Bu Sun Kim715bd7f2019-06-14 16:50:42 -070085<p class="firstline">Export Redis instance data into a Redis RDB format file in Cloud Storage.</p>
86<p class="toc_element">
Dan O'Mearadd494642020-05-01 07:42:23 -070087 <code><a href="#failover">failover(name, body=None, x__xgafv=None)</a></code></p>
88<p class="firstline">Initiates a failover of the master node to current replica node for a</p>
89<p class="toc_element">
Bu Sun Kim715bd7f2019-06-14 16:50:42 -070090 <code><a href="#get">get(name, x__xgafv=None)</a></code></p>
91<p class="firstline">Gets the details of a specific Redis instance.</p>
92<p class="toc_element">
Dan O'Mearadd494642020-05-01 07:42:23 -070093 <code><a href="#import_">import_(name, body=None, x__xgafv=None)</a></code></p>
Bu Sun Kim715bd7f2019-06-14 16:50:42 -070094<p class="firstline">Import a Redis RDB snapshot file from Cloud Storage into a Redis instance.</p>
95<p class="toc_element">
Bu Sun Kim65020912020-05-20 12:08:20 -070096 <code><a href="#list">list(parent, pageToken=None, pageSize=None, x__xgafv=None)</a></code></p>
Bu Sun Kim715bd7f2019-06-14 16:50:42 -070097<p class="firstline">Lists all Redis instances owned by a project in either the specified</p>
98<p class="toc_element">
99 <code><a href="#list_next">list_next(previous_request, previous_response)</a></code></p>
100<p class="firstline">Retrieves the next page of results.</p>
101<p class="toc_element">
Dan O'Mearadd494642020-05-01 07:42:23 -0700102 <code><a href="#patch">patch(name, body=None, updateMask=None, x__xgafv=None)</a></code></p>
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700103<p class="firstline">Updates the metadata and configuration of a specific Redis instance.</p>
Dan O'Mearadd494642020-05-01 07:42:23 -0700104<p class="toc_element">
105 <code><a href="#upgrade">upgrade(name, body=None, x__xgafv=None)</a></code></p>
106<p class="firstline">Upgrades Redis instance to the newer Redis version specified in the</p>
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700107<h3>Method Details</h3>
108<div class="method">
Dan O'Mearadd494642020-05-01 07:42:23 -0700109 <code class="details" id="create">create(parent, body=None, instanceId=None, x__xgafv=None)</code>
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700110 <pre>Creates a Redis instance based on the specified tier and memory size.
111
Bu Sun Kim65020912020-05-20 12:08:20 -0700112By default, the instance is accessible from the project&#x27;s
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700113[default network](https://cloud.google.com/vpc/docs/vpc).
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700114
115The creation is executed asynchronously and callers may check the returned
116operation to track its progress. Once the operation is completed the Redis
117instance will be fully functional. Completed longrunning.Operation will
118contain the new instance object in the response field.
119
120The returned operation is automatically deleted after a few hours, so there
121is no need to call DeleteOperation.
122
123Args:
124 parent: string, Required. The resource name of the instance location using the form:
125 `projects/{project_id}/locations/{location_id}`
126where `location_id` refers to a GCP region. (required)
Dan O'Mearadd494642020-05-01 07:42:23 -0700127 body: object, The request body.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700128 The object takes the form of:
129
130{ # A Google Cloud Redis instance.
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -0700131 &quot;persistenceIamIdentity&quot;: &quot;A String&quot;, # Output only. Cloud IAM identity used by import / export operations to
132 # transfer data to/from Cloud Storage. Format is
133 # &quot;serviceAccount:&lt;service_account_email&gt;&quot;. The value may change over time
134 # for a given instance so should be checked before each import/export
135 # operation.
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700136 &quot;reservedIpRange&quot;: &quot;A String&quot;, # Optional. The CIDR range of internal addresses that are reserved for this
137 # instance. If not provided, the service will choose an unused /29 block,
138 # for example, 10.0.0.0/29 or 192.168.0.0/29. Ranges must be unique
139 # and non-overlapping with existing subnets in an authorized network.
140 &quot;locationId&quot;: &quot;A String&quot;, # Optional. The zone where the instance will be provisioned. If not provided,
141 # the service will choose a zone for the instance. For STANDARD_HA tier,
142 # instances will be created across two zones for protection against zonal
143 # failures. If alternative_location_id is also provided, it must be
144 # different from location_id.
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -0700145 &quot;redisConfigs&quot;: { # Optional. Redis configuration parameters, according to
146 # http://redis.io/topics/config. Currently, the only supported parameters
147 # are:
148 #
149 # Redis version 3.2 and newer:
150 #
151 # * maxmemory-policy
152 # * notify-keyspace-events
153 #
154 # Redis version 4.0 and newer:
155 #
156 # * activedefrag
157 # * lfu-decay-time
158 # * lfu-log-factor
159 # * maxmemory-gb
160 #
161 # Redis version 5.0 and newer:
162 #
163 # * stream-node-max-bytes
164 # * stream-node-max-entries
165 &quot;a_key&quot;: &quot;A String&quot;,
166 },
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700167 &quot;state&quot;: &quot;A String&quot;, # Output only. The current state of this instance.
168 &quot;authorizedNetwork&quot;: &quot;A String&quot;, # Optional. The full name of the Google Compute Engine
169 # [network](https://cloud.google.com/vpc/docs/vpc) to which the
170 # instance is connected. If left unspecified, the `default` network
171 # will be used.
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -0700172 &quot;port&quot;: 42, # Output only. The port number of the exposed Redis endpoint.
173 &quot;host&quot;: &quot;A String&quot;, # Output only. Hostname or IP address of the exposed Redis endpoint used by
174 # clients to connect to the service.
175 &quot;redisVersion&quot;: &quot;A String&quot;, # Optional. The version of Redis software.
176 # If not provided, latest supported version will be used. Currently, the
177 # supported values are:
178 #
179 # * `REDIS_3_2` for Redis 3.2 compatibility
180 # * `REDIS_4_0` for Redis 4.0 compatibility (default)
181 # * `REDIS_5_0` for Redis 5.0 compatibility
182 &quot;tier&quot;: &quot;A String&quot;, # Required. The service tier of the instance.
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700183 &quot;createTime&quot;: &quot;A String&quot;, # Output only. The time the instance was created.
184 &quot;statusMessage&quot;: &quot;A String&quot;, # Output only. Additional information about the current status of this
185 # instance, if available.
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -0700186 &quot;displayName&quot;: &quot;A String&quot;, # An arbitrary and optional user-provided name for the instance.
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700187 &quot;alternativeLocationId&quot;: &quot;A String&quot;, # Optional. Only applicable to STANDARD_HA tier which protects the instance
188 # against zonal failures by provisioning it across two zones. If provided, it
189 # must be a different zone from the one provided in location_id.
190 &quot;name&quot;: &quot;A String&quot;, # Required. Unique name of the resource in this scope including project and
191 # location using the form:
192 # `projects/{project_id}/locations/{location_id}/instances/{instance_id}`
193 #
194 # Note: Redis instances are managed and addressed at regional level so
195 # location_id here refers to a GCP region; however, users may choose which
196 # specific zone (or collection of zones for cross-zone instances) an instance
197 # should be provisioned in. Refer to location_id and
198 # alternative_location_id fields for more details.
199 &quot;labels&quot;: { # Resource labels to represent user provided metadata
200 &quot;a_key&quot;: &quot;A String&quot;,
201 },
202 &quot;memorySizeGb&quot;: 42, # Required. Redis memory size in GiB.
203 &quot;connectMode&quot;: &quot;A String&quot;, # Optional. The network connect mode of the Redis instance.
204 # If not provided, the connect mode defaults to DIRECT_PEERING.
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -0700205 &quot;currentLocationId&quot;: &quot;A String&quot;, # Output only. The current zone where the Redis endpoint is placed. For Basic
206 # Tier instances, this will always be the same as the location_id
207 # provided by the user at creation time. For Standard Tier instances,
208 # this can be either location_id or alternative_location_id and can
209 # change after a failover event.
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -0700210 }
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700211
212 instanceId: string, Required. The logical name of the Redis instance in the customer project
213with the following restrictions:
214
215* Must contain only lowercase letters, numbers, and hyphens.
216* Must start with a letter.
217* Must be between 1-40 characters.
218* Must end with a number or a letter.
219* Must be unique within the customer project / location
220 x__xgafv: string, V1 error format.
221 Allowed values
222 1 - v1 error format
223 2 - v2 error format
224
225Returns:
226 An object of the form:
227
228 { # This resource represents a long-running operation that is the result of a
229 # network API call.
Bu Sun Kim65020912020-05-20 12:08:20 -0700230 &quot;response&quot;: { # The normal response of the operation in case of success. If the original
231 # method returns no data on success, such as `Delete`, the response is
232 # `google.protobuf.Empty`. If the original method is standard
233 # `Get`/`Create`/`Update`, the response should be the resource. For other
234 # methods, the response should have the type `XxxResponse`, where `Xxx`
235 # is the original method name. For example, if the original method name
236 # is `TakeSnapshot()`, the inferred response type is
237 # `TakeSnapshotResponse`.
238 &quot;a_key&quot;: &quot;&quot;, # Properties of the object. Contains field @type with type URL.
239 },
Bu Sun Kim65020912020-05-20 12:08:20 -0700240 &quot;metadata&quot;: { # {
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700241 #
242 # `createTime`: The time the operation was created.
243 #
244 # `endTime`: The time the operation finished running.
245 #
246 # `target`: Server-defined resource path for the target of the operation.
247 #
248 # `verb`: Name of the verb executed by the operation.
249 #
250 # `statusDetail`: Human-readable status of the operation, if any.
251 #
252 # `cancelRequested`: 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 of 1, corresponding to `Code.CANCELLED`.
253 #
254 # `apiVersion`: API version used to start the operation.
255 #
256 # }
Bu Sun Kim65020912020-05-20 12:08:20 -0700257 &quot;a_key&quot;: &quot;&quot;, # Properties of the object. Contains field @type with type URL.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700258 },
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700259 &quot;done&quot;: True or False, # If the value is `false`, it means the operation is still in progress.
260 # If `true`, the operation is completed, and either `error` or `response` is
261 # available.
262 &quot;error&quot;: { # The `Status` type defines a logical error model that is suitable for # The error result of the operation in case of failure or cancellation.
263 # different programming environments, including REST APIs and RPC APIs. It is
264 # used by [gRPC](https://github.com/grpc). Each `Status` message contains
265 # three pieces of data: error code, error message, and error details.
266 #
267 # You can find out more about this error model and how to work with it in the
268 # [API Design Guide](https://cloud.google.com/apis/design/errors).
269 &quot;message&quot;: &quot;A String&quot;, # A developer-facing error message, which should be in English. Any
270 # user-facing error message should be localized and sent in the
271 # google.rpc.Status.details field, or localized by the client.
272 &quot;code&quot;: 42, # The status code, which should be an enum value of google.rpc.Code.
273 &quot;details&quot;: [ # A list of messages that carry the error details. There is a common set of
274 # message types for APIs to use.
275 {
276 &quot;a_key&quot;: &quot;&quot;, # Properties of the object. Contains field @type with type URL.
277 },
278 ],
279 },
280 &quot;name&quot;: &quot;A String&quot;, # The server-assigned name, which is only unique within the same service that
281 # originally returns it. If you use the default HTTP mapping, the
282 # `name` should be a resource name ending with `operations/{unique_id}`.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700283 }</pre>
284</div>
285
286<div class="method">
287 <code class="details" id="delete">delete(name, x__xgafv=None)</code>
288 <pre>Deletes a specific Redis instance. Instance stops serving and data is
289deleted.
290
291Args:
292 name: string, Required. Redis instance resource name using the form:
293 `projects/{project_id}/locations/{location_id}/instances/{instance_id}`
294where `location_id` refers to a GCP region. (required)
295 x__xgafv: string, V1 error format.
296 Allowed values
297 1 - v1 error format
298 2 - v2 error format
299
300Returns:
301 An object of the form:
302
303 { # This resource represents a long-running operation that is the result of a
304 # network API call.
Bu Sun Kim65020912020-05-20 12:08:20 -0700305 &quot;response&quot;: { # The normal response of the operation in case of success. If the original
306 # method returns no data on success, such as `Delete`, the response is
307 # `google.protobuf.Empty`. If the original method is standard
308 # `Get`/`Create`/`Update`, the response should be the resource. For other
309 # methods, the response should have the type `XxxResponse`, where `Xxx`
310 # is the original method name. For example, if the original method name
311 # is `TakeSnapshot()`, the inferred response type is
312 # `TakeSnapshotResponse`.
313 &quot;a_key&quot;: &quot;&quot;, # Properties of the object. Contains field @type with type URL.
314 },
Bu Sun Kim65020912020-05-20 12:08:20 -0700315 &quot;metadata&quot;: { # {
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700316 #
317 # `createTime`: The time the operation was created.
318 #
319 # `endTime`: The time the operation finished running.
320 #
321 # `target`: Server-defined resource path for the target of the operation.
322 #
323 # `verb`: Name of the verb executed by the operation.
324 #
325 # `statusDetail`: Human-readable status of the operation, if any.
326 #
327 # `cancelRequested`: 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 of 1, corresponding to `Code.CANCELLED`.
328 #
329 # `apiVersion`: API version used to start the operation.
330 #
331 # }
Bu Sun Kim65020912020-05-20 12:08:20 -0700332 &quot;a_key&quot;: &quot;&quot;, # Properties of the object. Contains field @type with type URL.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700333 },
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700334 &quot;done&quot;: True or False, # If the value is `false`, it means the operation is still in progress.
335 # If `true`, the operation is completed, and either `error` or `response` is
336 # available.
337 &quot;error&quot;: { # The `Status` type defines a logical error model that is suitable for # The error result of the operation in case of failure or cancellation.
338 # different programming environments, including REST APIs and RPC APIs. It is
339 # used by [gRPC](https://github.com/grpc). Each `Status` message contains
340 # three pieces of data: error code, error message, and error details.
341 #
342 # You can find out more about this error model and how to work with it in the
343 # [API Design Guide](https://cloud.google.com/apis/design/errors).
344 &quot;message&quot;: &quot;A String&quot;, # A developer-facing error message, which should be in English. Any
345 # user-facing error message should be localized and sent in the
346 # google.rpc.Status.details field, or localized by the client.
347 &quot;code&quot;: 42, # The status code, which should be an enum value of google.rpc.Code.
348 &quot;details&quot;: [ # A list of messages that carry the error details. There is a common set of
349 # message types for APIs to use.
350 {
351 &quot;a_key&quot;: &quot;&quot;, # Properties of the object. Contains field @type with type URL.
352 },
353 ],
354 },
355 &quot;name&quot;: &quot;A String&quot;, # The server-assigned name, which is only unique within the same service that
356 # originally returns it. If you use the default HTTP mapping, the
357 # `name` should be a resource name ending with `operations/{unique_id}`.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700358 }</pre>
359</div>
360
361<div class="method">
Dan O'Mearadd494642020-05-01 07:42:23 -0700362 <code class="details" id="export">export(name, body=None, x__xgafv=None)</code>
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700363 <pre>Export Redis instance data into a Redis RDB format file in Cloud Storage.
364
365Redis will continue serving during this operation.
366
367The returned operation is automatically deleted after a few hours, so
368there is no need to call DeleteOperation.
369
370Args:
371 name: string, Required. Redis instance resource name using the form:
372 `projects/{project_id}/locations/{location_id}/instances/{instance_id}`
373where `location_id` refers to a GCP region. (required)
Dan O'Mearadd494642020-05-01 07:42:23 -0700374 body: object, The request body.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700375 The object takes the form of:
376
377{ # Request for Export.
Bu Sun Kim65020912020-05-20 12:08:20 -0700378 &quot;outputConfig&quot;: { # The output content # Required. Specify data to be exported.
379 &quot;gcsDestination&quot;: { # The Cloud Storage location for the output content # Google Cloud Storage destination for output content.
380 &quot;uri&quot;: &quot;A String&quot;, # Required. Data destination URI (e.g.
381 # &#x27;gs://my_bucket/my_object&#x27;). Existing files will be overwritten.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700382 },
383 },
384 }
385
386 x__xgafv: string, V1 error format.
387 Allowed values
388 1 - v1 error format
389 2 - v2 error format
390
391Returns:
392 An object of the form:
393
394 { # This resource represents a long-running operation that is the result of a
395 # network API call.
Bu Sun Kim65020912020-05-20 12:08:20 -0700396 &quot;response&quot;: { # The normal response of the operation in case of success. If the original
397 # method returns no data on success, such as `Delete`, the response is
398 # `google.protobuf.Empty`. If the original method is standard
399 # `Get`/`Create`/`Update`, the response should be the resource. For other
400 # methods, the response should have the type `XxxResponse`, where `Xxx`
401 # is the original method name. For example, if the original method name
402 # is `TakeSnapshot()`, the inferred response type is
403 # `TakeSnapshotResponse`.
404 &quot;a_key&quot;: &quot;&quot;, # Properties of the object. Contains field @type with type URL.
405 },
Bu Sun Kim65020912020-05-20 12:08:20 -0700406 &quot;metadata&quot;: { # {
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700407 #
408 # `createTime`: The time the operation was created.
409 #
410 # `endTime`: The time the operation finished running.
411 #
412 # `target`: Server-defined resource path for the target of the operation.
413 #
414 # `verb`: Name of the verb executed by the operation.
415 #
416 # `statusDetail`: Human-readable status of the operation, if any.
417 #
418 # `cancelRequested`: 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 of 1, corresponding to `Code.CANCELLED`.
419 #
420 # `apiVersion`: API version used to start the operation.
421 #
422 # }
Bu Sun Kim65020912020-05-20 12:08:20 -0700423 &quot;a_key&quot;: &quot;&quot;, # Properties of the object. Contains field @type with type URL.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700424 },
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700425 &quot;done&quot;: True or False, # If the value is `false`, it means the operation is still in progress.
426 # If `true`, the operation is completed, and either `error` or `response` is
427 # available.
428 &quot;error&quot;: { # The `Status` type defines a logical error model that is suitable for # The error result of the operation in case of failure or cancellation.
429 # different programming environments, including REST APIs and RPC APIs. It is
430 # used by [gRPC](https://github.com/grpc). Each `Status` message contains
431 # three pieces of data: error code, error message, and error details.
432 #
433 # You can find out more about this error model and how to work with it in the
434 # [API Design Guide](https://cloud.google.com/apis/design/errors).
435 &quot;message&quot;: &quot;A String&quot;, # A developer-facing error message, which should be in English. Any
436 # user-facing error message should be localized and sent in the
437 # google.rpc.Status.details field, or localized by the client.
438 &quot;code&quot;: 42, # The status code, which should be an enum value of google.rpc.Code.
439 &quot;details&quot;: [ # A list of messages that carry the error details. There is a common set of
440 # message types for APIs to use.
441 {
442 &quot;a_key&quot;: &quot;&quot;, # Properties of the object. Contains field @type with type URL.
443 },
444 ],
445 },
446 &quot;name&quot;: &quot;A String&quot;, # The server-assigned name, which is only unique within the same service that
447 # originally returns it. If you use the default HTTP mapping, the
448 # `name` should be a resource name ending with `operations/{unique_id}`.
Dan O'Mearadd494642020-05-01 07:42:23 -0700449 }</pre>
450</div>
451
452<div class="method">
453 <code class="details" id="failover">failover(name, body=None, x__xgafv=None)</code>
454 <pre>Initiates a failover of the master node to current replica node for a
455specific STANDARD tier Cloud Memorystore for Redis instance.
456
457Args:
458 name: string, Required. Redis instance resource name using the form:
459 `projects/{project_id}/locations/{location_id}/instances/{instance_id}`
460where `location_id` refers to a GCP region. (required)
461 body: object, The request body.
462 The object takes the form of:
463
464{ # Request for Failover.
Bu Sun Kim65020912020-05-20 12:08:20 -0700465 &quot;dataProtectionMode&quot;: &quot;A String&quot;, # Optional. Available data protection modes that the user can choose. If it&#x27;s
Dan O'Mearadd494642020-05-01 07:42:23 -0700466 # unspecified, data protection mode will be LIMITED_DATA_LOSS by default.
467 }
468
469 x__xgafv: string, V1 error format.
470 Allowed values
471 1 - v1 error format
472 2 - v2 error format
473
474Returns:
475 An object of the form:
476
477 { # This resource represents a long-running operation that is the result of a
478 # network API call.
Bu Sun Kim65020912020-05-20 12:08:20 -0700479 &quot;response&quot;: { # The normal response of the operation in case of success. If the original
480 # method returns no data on success, such as `Delete`, the response is
481 # `google.protobuf.Empty`. If the original method is standard
482 # `Get`/`Create`/`Update`, the response should be the resource. For other
483 # methods, the response should have the type `XxxResponse`, where `Xxx`
484 # is the original method name. For example, if the original method name
485 # is `TakeSnapshot()`, the inferred response type is
486 # `TakeSnapshotResponse`.
487 &quot;a_key&quot;: &quot;&quot;, # Properties of the object. Contains field @type with type URL.
488 },
Bu Sun Kim65020912020-05-20 12:08:20 -0700489 &quot;metadata&quot;: { # {
Dan O'Mearadd494642020-05-01 07:42:23 -0700490 #
491 # `createTime`: The time the operation was created.
492 #
493 # `endTime`: The time the operation finished running.
494 #
495 # `target`: Server-defined resource path for the target of the operation.
496 #
497 # `verb`: Name of the verb executed by the operation.
498 #
499 # `statusDetail`: Human-readable status of the operation, if any.
500 #
501 # `cancelRequested`: 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 of 1, corresponding to `Code.CANCELLED`.
502 #
503 # `apiVersion`: API version used to start the operation.
504 #
505 # }
Bu Sun Kim65020912020-05-20 12:08:20 -0700506 &quot;a_key&quot;: &quot;&quot;, # Properties of the object. Contains field @type with type URL.
Dan O'Mearadd494642020-05-01 07:42:23 -0700507 },
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700508 &quot;done&quot;: True or False, # If the value is `false`, it means the operation is still in progress.
509 # If `true`, the operation is completed, and either `error` or `response` is
510 # available.
511 &quot;error&quot;: { # The `Status` type defines a logical error model that is suitable for # The error result of the operation in case of failure or cancellation.
512 # different programming environments, including REST APIs and RPC APIs. It is
513 # used by [gRPC](https://github.com/grpc). Each `Status` message contains
514 # three pieces of data: error code, error message, and error details.
515 #
516 # You can find out more about this error model and how to work with it in the
517 # [API Design Guide](https://cloud.google.com/apis/design/errors).
518 &quot;message&quot;: &quot;A String&quot;, # A developer-facing error message, which should be in English. Any
519 # user-facing error message should be localized and sent in the
520 # google.rpc.Status.details field, or localized by the client.
521 &quot;code&quot;: 42, # The status code, which should be an enum value of google.rpc.Code.
522 &quot;details&quot;: [ # A list of messages that carry the error details. There is a common set of
523 # message types for APIs to use.
524 {
525 &quot;a_key&quot;: &quot;&quot;, # Properties of the object. Contains field @type with type URL.
526 },
527 ],
528 },
529 &quot;name&quot;: &quot;A String&quot;, # The server-assigned name, which is only unique within the same service that
530 # originally returns it. If you use the default HTTP mapping, the
531 # `name` should be a resource name ending with `operations/{unique_id}`.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700532 }</pre>
533</div>
534
535<div class="method">
536 <code class="details" id="get">get(name, x__xgafv=None)</code>
537 <pre>Gets the details of a specific Redis instance.
538
539Args:
540 name: string, Required. Redis instance resource name using the form:
541 `projects/{project_id}/locations/{location_id}/instances/{instance_id}`
542where `location_id` refers to a GCP region. (required)
543 x__xgafv: string, V1 error format.
544 Allowed values
545 1 - v1 error format
546 2 - v2 error format
547
548Returns:
549 An object of the form:
550
551 { # A Google Cloud Redis instance.
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -0700552 &quot;persistenceIamIdentity&quot;: &quot;A String&quot;, # Output only. Cloud IAM identity used by import / export operations to
553 # transfer data to/from Cloud Storage. Format is
554 # &quot;serviceAccount:&lt;service_account_email&gt;&quot;. The value may change over time
555 # for a given instance so should be checked before each import/export
556 # operation.
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700557 &quot;reservedIpRange&quot;: &quot;A String&quot;, # Optional. The CIDR range of internal addresses that are reserved for this
558 # instance. If not provided, the service will choose an unused /29 block,
559 # for example, 10.0.0.0/29 or 192.168.0.0/29. Ranges must be unique
560 # and non-overlapping with existing subnets in an authorized network.
561 &quot;locationId&quot;: &quot;A String&quot;, # Optional. The zone where the instance will be provisioned. If not provided,
562 # the service will choose a zone for the instance. For STANDARD_HA tier,
563 # instances will be created across two zones for protection against zonal
564 # failures. If alternative_location_id is also provided, it must be
565 # different from location_id.
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -0700566 &quot;redisConfigs&quot;: { # Optional. Redis configuration parameters, according to
567 # http://redis.io/topics/config. Currently, the only supported parameters
568 # are:
569 #
570 # Redis version 3.2 and newer:
571 #
572 # * maxmemory-policy
573 # * notify-keyspace-events
574 #
575 # Redis version 4.0 and newer:
576 #
577 # * activedefrag
578 # * lfu-decay-time
579 # * lfu-log-factor
580 # * maxmemory-gb
581 #
582 # Redis version 5.0 and newer:
583 #
584 # * stream-node-max-bytes
585 # * stream-node-max-entries
586 &quot;a_key&quot;: &quot;A String&quot;,
587 },
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700588 &quot;state&quot;: &quot;A String&quot;, # Output only. The current state of this instance.
589 &quot;authorizedNetwork&quot;: &quot;A String&quot;, # Optional. The full name of the Google Compute Engine
590 # [network](https://cloud.google.com/vpc/docs/vpc) to which the
591 # instance is connected. If left unspecified, the `default` network
592 # will be used.
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -0700593 &quot;port&quot;: 42, # Output only. The port number of the exposed Redis endpoint.
594 &quot;host&quot;: &quot;A String&quot;, # Output only. Hostname or IP address of the exposed Redis endpoint used by
595 # clients to connect to the service.
596 &quot;redisVersion&quot;: &quot;A String&quot;, # Optional. The version of Redis software.
597 # If not provided, latest supported version will be used. Currently, the
598 # supported values are:
599 #
600 # * `REDIS_3_2` for Redis 3.2 compatibility
601 # * `REDIS_4_0` for Redis 4.0 compatibility (default)
602 # * `REDIS_5_0` for Redis 5.0 compatibility
603 &quot;tier&quot;: &quot;A String&quot;, # Required. The service tier of the instance.
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700604 &quot;createTime&quot;: &quot;A String&quot;, # Output only. The time the instance was created.
605 &quot;statusMessage&quot;: &quot;A String&quot;, # Output only. Additional information about the current status of this
606 # instance, if available.
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -0700607 &quot;displayName&quot;: &quot;A String&quot;, # An arbitrary and optional user-provided name for the instance.
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700608 &quot;alternativeLocationId&quot;: &quot;A String&quot;, # Optional. Only applicable to STANDARD_HA tier which protects the instance
609 # against zonal failures by provisioning it across two zones. If provided, it
610 # must be a different zone from the one provided in location_id.
611 &quot;name&quot;: &quot;A String&quot;, # Required. Unique name of the resource in this scope including project and
612 # location using the form:
613 # `projects/{project_id}/locations/{location_id}/instances/{instance_id}`
614 #
615 # Note: Redis instances are managed and addressed at regional level so
616 # location_id here refers to a GCP region; however, users may choose which
617 # specific zone (or collection of zones for cross-zone instances) an instance
618 # should be provisioned in. Refer to location_id and
619 # alternative_location_id fields for more details.
620 &quot;labels&quot;: { # Resource labels to represent user provided metadata
621 &quot;a_key&quot;: &quot;A String&quot;,
622 },
623 &quot;memorySizeGb&quot;: 42, # Required. Redis memory size in GiB.
624 &quot;connectMode&quot;: &quot;A String&quot;, # Optional. The network connect mode of the Redis instance.
625 # If not provided, the connect mode defaults to DIRECT_PEERING.
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -0700626 &quot;currentLocationId&quot;: &quot;A String&quot;, # Output only. The current zone where the Redis endpoint is placed. For Basic
627 # Tier instances, this will always be the same as the location_id
628 # provided by the user at creation time. For Standard Tier instances,
629 # this can be either location_id or alternative_location_id and can
630 # change after a failover event.
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -0700631 }</pre>
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700632</div>
633
634<div class="method">
Dan O'Mearadd494642020-05-01 07:42:23 -0700635 <code class="details" id="import_">import_(name, body=None, x__xgafv=None)</code>
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700636 <pre>Import a Redis RDB snapshot file from Cloud Storage into a Redis instance.
637
638Redis may stop serving during this operation. Instance state will be
639IMPORTING for entire operation. When complete, the instance will contain
640only data from the imported file.
641
642The returned operation is automatically deleted after a few hours, so
643there is no need to call DeleteOperation.
644
645Args:
646 name: string, Required. Redis instance resource name using the form:
647 `projects/{project_id}/locations/{location_id}/instances/{instance_id}`
648where `location_id` refers to a GCP region. (required)
Dan O'Mearadd494642020-05-01 07:42:23 -0700649 body: object, The request body.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700650 The object takes the form of:
651
652{ # Request for Import.
Bu Sun Kim65020912020-05-20 12:08:20 -0700653 &quot;inputConfig&quot;: { # The input content # Required. Specify data to be imported.
654 &quot;gcsSource&quot;: { # The Cloud Storage location for the input content # Google Cloud Storage location where input content is located.
655 &quot;uri&quot;: &quot;A String&quot;, # Required. Source data URI. (e.g. &#x27;gs://my_bucket/my_object&#x27;).
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700656 },
657 },
658 }
659
660 x__xgafv: string, V1 error format.
661 Allowed values
662 1 - v1 error format
663 2 - v2 error format
664
665Returns:
666 An object of the form:
667
668 { # This resource represents a long-running operation that is the result of a
669 # network API call.
Bu Sun Kim65020912020-05-20 12:08:20 -0700670 &quot;response&quot;: { # The normal response of the operation in case of success. If the original
671 # method returns no data on success, such as `Delete`, the response is
672 # `google.protobuf.Empty`. If the original method is standard
673 # `Get`/`Create`/`Update`, the response should be the resource. For other
674 # methods, the response should have the type `XxxResponse`, where `Xxx`
675 # is the original method name. For example, if the original method name
676 # is `TakeSnapshot()`, the inferred response type is
677 # `TakeSnapshotResponse`.
678 &quot;a_key&quot;: &quot;&quot;, # Properties of the object. Contains field @type with type URL.
679 },
Bu Sun Kim65020912020-05-20 12:08:20 -0700680 &quot;metadata&quot;: { # {
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700681 #
682 # `createTime`: The time the operation was created.
683 #
684 # `endTime`: The time the operation finished running.
685 #
686 # `target`: Server-defined resource path for the target of the operation.
687 #
688 # `verb`: Name of the verb executed by the operation.
689 #
690 # `statusDetail`: Human-readable status of the operation, if any.
691 #
692 # `cancelRequested`: 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 of 1, corresponding to `Code.CANCELLED`.
693 #
694 # `apiVersion`: API version used to start the operation.
695 #
696 # }
Bu Sun Kim65020912020-05-20 12:08:20 -0700697 &quot;a_key&quot;: &quot;&quot;, # Properties of the object. Contains field @type with type URL.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700698 },
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700699 &quot;done&quot;: True or False, # If the value is `false`, it means the operation is still in progress.
700 # If `true`, the operation is completed, and either `error` or `response` is
701 # available.
702 &quot;error&quot;: { # The `Status` type defines a logical error model that is suitable for # The error result of the operation in case of failure or cancellation.
703 # different programming environments, including REST APIs and RPC APIs. It is
704 # used by [gRPC](https://github.com/grpc). Each `Status` message contains
705 # three pieces of data: error code, error message, and error details.
706 #
707 # You can find out more about this error model and how to work with it in the
708 # [API Design Guide](https://cloud.google.com/apis/design/errors).
709 &quot;message&quot;: &quot;A String&quot;, # A developer-facing error message, which should be in English. Any
710 # user-facing error message should be localized and sent in the
711 # google.rpc.Status.details field, or localized by the client.
712 &quot;code&quot;: 42, # The status code, which should be an enum value of google.rpc.Code.
713 &quot;details&quot;: [ # A list of messages that carry the error details. There is a common set of
714 # message types for APIs to use.
715 {
716 &quot;a_key&quot;: &quot;&quot;, # Properties of the object. Contains field @type with type URL.
717 },
718 ],
719 },
720 &quot;name&quot;: &quot;A String&quot;, # The server-assigned name, which is only unique within the same service that
721 # originally returns it. If you use the default HTTP mapping, the
722 # `name` should be a resource name ending with `operations/{unique_id}`.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700723 }</pre>
724</div>
725
726<div class="method">
Bu Sun Kim65020912020-05-20 12:08:20 -0700727 <code class="details" id="list">list(parent, pageToken=None, pageSize=None, x__xgafv=None)</code>
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700728 <pre>Lists all Redis instances owned by a project in either the specified
729location (region) or all locations.
730
731The location should have the following format:
Dan O'Mearadd494642020-05-01 07:42:23 -0700732
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700733* `projects/{project_id}/locations/{location_id}`
734
735If `location_id` is specified as `-` (wildcard), then all regions
736available to the project are queried, and the results are aggregated.
737
738Args:
739 parent: string, Required. The resource name of the instance location using the form:
740 `projects/{project_id}/locations/{location_id}`
741where `location_id` refers to a GCP region. (required)
Dan O'Mearadd494642020-05-01 07:42:23 -0700742 pageToken: string, The `next_page_token` value returned from a previous
743ListInstances request, if any.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700744 pageSize: integer, The maximum number of items to return.
745
746If not specified, a default value of 1000 will be used by the service.
747Regardless of the page_size value, the response may include a partial list
Bu Sun Kim65020912020-05-20 12:08:20 -0700748and a caller should only rely on response&#x27;s
Dan O'Mearadd494642020-05-01 07:42:23 -0700749`next_page_token`
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700750to determine if there are more instances left to be queried.
Bu Sun Kim65020912020-05-20 12:08:20 -0700751 x__xgafv: string, V1 error format.
752 Allowed values
753 1 - v1 error format
754 2 - v2 error format
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700755
756Returns:
757 An object of the form:
758
759 { # Response for ListInstances.
Bu Sun Kim65020912020-05-20 12:08:20 -0700760 &quot;instances&quot;: [ # A list of Redis instances in the project in the specified location,
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700761 # or across all locations.
762 #
Bu Sun Kim65020912020-05-20 12:08:20 -0700763 # If the `location_id` in the parent field of the request is &quot;-&quot;, all regions
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700764 # available to the project are queried, and the results aggregated.
765 # If in such an aggregated query a location is unavailable, a dummy Redis
Dan O'Mearadd494642020-05-01 07:42:23 -0700766 # entry is included in the response with the `name` field set to a value of
767 # the form `projects/{project_id}/locations/{location_id}/instances/`- and
Bu Sun Kim65020912020-05-20 12:08:20 -0700768 # the `status` field set to ERROR and `status_message` field set to &quot;location
769 # not available for ListInstances&quot;.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700770 { # A Google Cloud Redis instance.
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -0700771 &quot;persistenceIamIdentity&quot;: &quot;A String&quot;, # Output only. Cloud IAM identity used by import / export operations to
772 # transfer data to/from Cloud Storage. Format is
773 # &quot;serviceAccount:&lt;service_account_email&gt;&quot;. The value may change over time
774 # for a given instance so should be checked before each import/export
775 # operation.
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700776 &quot;reservedIpRange&quot;: &quot;A String&quot;, # Optional. The CIDR range of internal addresses that are reserved for this
777 # instance. If not provided, the service will choose an unused /29 block,
778 # for example, 10.0.0.0/29 or 192.168.0.0/29. Ranges must be unique
779 # and non-overlapping with existing subnets in an authorized network.
780 &quot;locationId&quot;: &quot;A String&quot;, # Optional. The zone where the instance will be provisioned. If not provided,
781 # the service will choose a zone for the instance. For STANDARD_HA tier,
782 # instances will be created across two zones for protection against zonal
783 # failures. If alternative_location_id is also provided, it must be
784 # different from location_id.
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -0700785 &quot;redisConfigs&quot;: { # Optional. Redis configuration parameters, according to
786 # http://redis.io/topics/config. Currently, the only supported parameters
787 # are:
788 #
789 # Redis version 3.2 and newer:
790 #
791 # * maxmemory-policy
792 # * notify-keyspace-events
793 #
794 # Redis version 4.0 and newer:
795 #
796 # * activedefrag
797 # * lfu-decay-time
798 # * lfu-log-factor
799 # * maxmemory-gb
800 #
801 # Redis version 5.0 and newer:
802 #
803 # * stream-node-max-bytes
804 # * stream-node-max-entries
805 &quot;a_key&quot;: &quot;A String&quot;,
806 },
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700807 &quot;state&quot;: &quot;A String&quot;, # Output only. The current state of this instance.
808 &quot;authorizedNetwork&quot;: &quot;A String&quot;, # Optional. The full name of the Google Compute Engine
809 # [network](https://cloud.google.com/vpc/docs/vpc) to which the
810 # instance is connected. If left unspecified, the `default` network
811 # will be used.
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -0700812 &quot;port&quot;: 42, # Output only. The port number of the exposed Redis endpoint.
813 &quot;host&quot;: &quot;A String&quot;, # Output only. Hostname or IP address of the exposed Redis endpoint used by
814 # clients to connect to the service.
815 &quot;redisVersion&quot;: &quot;A String&quot;, # Optional. The version of Redis software.
816 # If not provided, latest supported version will be used. Currently, the
817 # supported values are:
818 #
819 # * `REDIS_3_2` for Redis 3.2 compatibility
820 # * `REDIS_4_0` for Redis 4.0 compatibility (default)
821 # * `REDIS_5_0` for Redis 5.0 compatibility
822 &quot;tier&quot;: &quot;A String&quot;, # Required. The service tier of the instance.
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700823 &quot;createTime&quot;: &quot;A String&quot;, # Output only. The time the instance was created.
824 &quot;statusMessage&quot;: &quot;A String&quot;, # Output only. Additional information about the current status of this
825 # instance, if available.
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -0700826 &quot;displayName&quot;: &quot;A String&quot;, # An arbitrary and optional user-provided name for the instance.
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700827 &quot;alternativeLocationId&quot;: &quot;A String&quot;, # Optional. Only applicable to STANDARD_HA tier which protects the instance
828 # against zonal failures by provisioning it across two zones. If provided, it
829 # must be a different zone from the one provided in location_id.
830 &quot;name&quot;: &quot;A String&quot;, # Required. Unique name of the resource in this scope including project and
831 # location using the form:
832 # `projects/{project_id}/locations/{location_id}/instances/{instance_id}`
833 #
834 # Note: Redis instances are managed and addressed at regional level so
835 # location_id here refers to a GCP region; however, users may choose which
836 # specific zone (or collection of zones for cross-zone instances) an instance
837 # should be provisioned in. Refer to location_id and
838 # alternative_location_id fields for more details.
839 &quot;labels&quot;: { # Resource labels to represent user provided metadata
840 &quot;a_key&quot;: &quot;A String&quot;,
841 },
842 &quot;memorySizeGb&quot;: 42, # Required. Redis memory size in GiB.
843 &quot;connectMode&quot;: &quot;A String&quot;, # Optional. The network connect mode of the Redis instance.
844 # If not provided, the connect mode defaults to DIRECT_PEERING.
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -0700845 &quot;currentLocationId&quot;: &quot;A String&quot;, # Output only. The current zone where the Redis endpoint is placed. For Basic
846 # Tier instances, this will always be the same as the location_id
847 # provided by the user at creation time. For Standard Tier instances,
848 # this can be either location_id or alternative_location_id and can
849 # change after a failover event.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700850 },
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -0700851 ],
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -0700852 &quot;unreachable&quot;: [ # Locations that could not be reached.
853 &quot;A String&quot;,
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700854 ],
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700855 &quot;nextPageToken&quot;: &quot;A String&quot;, # Token to retrieve the next page of results, or empty if there are no more
856 # results in the list.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700857 }</pre>
858</div>
859
860<div class="method">
861 <code class="details" id="list_next">list_next(previous_request, previous_response)</code>
862 <pre>Retrieves the next page of results.
863
864Args:
865 previous_request: The request for the previous page. (required)
866 previous_response: The response from the request for the previous page. (required)
867
868Returns:
Bu Sun Kim65020912020-05-20 12:08:20 -0700869 A request object that you can call &#x27;execute()&#x27; on to request the next
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700870 page. Returns None if there are no more items in the collection.
871 </pre>
872</div>
873
874<div class="method">
Dan O'Mearadd494642020-05-01 07:42:23 -0700875 <code class="details" id="patch">patch(name, body=None, updateMask=None, x__xgafv=None)</code>
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700876 <pre>Updates the metadata and configuration of a specific Redis instance.
877
878Completed longrunning.Operation will contain the new instance object
879in the response field. The returned operation is automatically deleted
880after a few hours, so there is no need to call DeleteOperation.
881
882Args:
883 name: string, Required. Unique name of the resource in this scope including project and
884location using the form:
885 `projects/{project_id}/locations/{location_id}/instances/{instance_id}`
886
887Note: Redis instances are managed and addressed at regional level so
888location_id here refers to a GCP region; however, users may choose which
889specific zone (or collection of zones for cross-zone instances) an instance
Dan O'Mearadd494642020-05-01 07:42:23 -0700890should be provisioned in. Refer to location_id and
891alternative_location_id fields for more details. (required)
892 body: object, The request body.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700893 The object takes the form of:
894
895{ # A Google Cloud Redis instance.
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -0700896 &quot;persistenceIamIdentity&quot;: &quot;A String&quot;, # Output only. Cloud IAM identity used by import / export operations to
897 # transfer data to/from Cloud Storage. Format is
898 # &quot;serviceAccount:&lt;service_account_email&gt;&quot;. The value may change over time
899 # for a given instance so should be checked before each import/export
900 # operation.
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700901 &quot;reservedIpRange&quot;: &quot;A String&quot;, # Optional. The CIDR range of internal addresses that are reserved for this
902 # instance. If not provided, the service will choose an unused /29 block,
903 # for example, 10.0.0.0/29 or 192.168.0.0/29. Ranges must be unique
904 # and non-overlapping with existing subnets in an authorized network.
905 &quot;locationId&quot;: &quot;A String&quot;, # Optional. The zone where the instance will be provisioned. If not provided,
906 # the service will choose a zone for the instance. For STANDARD_HA tier,
907 # instances will be created across two zones for protection against zonal
908 # failures. If alternative_location_id is also provided, it must be
909 # different from location_id.
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -0700910 &quot;redisConfigs&quot;: { # Optional. Redis configuration parameters, according to
911 # http://redis.io/topics/config. Currently, the only supported parameters
912 # are:
913 #
914 # Redis version 3.2 and newer:
915 #
916 # * maxmemory-policy
917 # * notify-keyspace-events
918 #
919 # Redis version 4.0 and newer:
920 #
921 # * activedefrag
922 # * lfu-decay-time
923 # * lfu-log-factor
924 # * maxmemory-gb
925 #
926 # Redis version 5.0 and newer:
927 #
928 # * stream-node-max-bytes
929 # * stream-node-max-entries
930 &quot;a_key&quot;: &quot;A String&quot;,
931 },
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700932 &quot;state&quot;: &quot;A String&quot;, # Output only. The current state of this instance.
933 &quot;authorizedNetwork&quot;: &quot;A String&quot;, # Optional. The full name of the Google Compute Engine
934 # [network](https://cloud.google.com/vpc/docs/vpc) to which the
935 # instance is connected. If left unspecified, the `default` network
936 # will be used.
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -0700937 &quot;port&quot;: 42, # Output only. The port number of the exposed Redis endpoint.
938 &quot;host&quot;: &quot;A String&quot;, # Output only. Hostname or IP address of the exposed Redis endpoint used by
939 # clients to connect to the service.
940 &quot;redisVersion&quot;: &quot;A String&quot;, # Optional. The version of Redis software.
941 # If not provided, latest supported version will be used. Currently, the
942 # supported values are:
943 #
944 # * `REDIS_3_2` for Redis 3.2 compatibility
945 # * `REDIS_4_0` for Redis 4.0 compatibility (default)
946 # * `REDIS_5_0` for Redis 5.0 compatibility
947 &quot;tier&quot;: &quot;A String&quot;, # Required. The service tier of the instance.
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700948 &quot;createTime&quot;: &quot;A String&quot;, # Output only. The time the instance was created.
949 &quot;statusMessage&quot;: &quot;A String&quot;, # Output only. Additional information about the current status of this
950 # instance, if available.
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -0700951 &quot;displayName&quot;: &quot;A String&quot;, # An arbitrary and optional user-provided name for the instance.
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700952 &quot;alternativeLocationId&quot;: &quot;A String&quot;, # Optional. Only applicable to STANDARD_HA tier which protects the instance
953 # against zonal failures by provisioning it across two zones. If provided, it
954 # must be a different zone from the one provided in location_id.
955 &quot;name&quot;: &quot;A String&quot;, # Required. Unique name of the resource in this scope including project and
956 # location using the form:
957 # `projects/{project_id}/locations/{location_id}/instances/{instance_id}`
958 #
959 # Note: Redis instances are managed and addressed at regional level so
960 # location_id here refers to a GCP region; however, users may choose which
961 # specific zone (or collection of zones for cross-zone instances) an instance
962 # should be provisioned in. Refer to location_id and
963 # alternative_location_id fields for more details.
964 &quot;labels&quot;: { # Resource labels to represent user provided metadata
965 &quot;a_key&quot;: &quot;A String&quot;,
966 },
967 &quot;memorySizeGb&quot;: 42, # Required. Redis memory size in GiB.
968 &quot;connectMode&quot;: &quot;A String&quot;, # Optional. The network connect mode of the Redis instance.
969 # If not provided, the connect mode defaults to DIRECT_PEERING.
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -0700970 &quot;currentLocationId&quot;: &quot;A String&quot;, # Output only. The current zone where the Redis endpoint is placed. For Basic
971 # Tier instances, this will always be the same as the location_id
972 # provided by the user at creation time. For Standard Tier instances,
973 # this can be either location_id or alternative_location_id and can
974 # change after a failover event.
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -0700975 }
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700976
977 updateMask: string, Required. Mask of fields to update. At least one path must be supplied in
978this field. The elements of the repeated paths field may only include these
979fields from Instance:
980
981 * `displayName`
982 * `labels`
983 * `memorySizeGb`
984 * `redisConfig`
985 x__xgafv: string, V1 error format.
986 Allowed values
987 1 - v1 error format
988 2 - v2 error format
989
990Returns:
991 An object of the form:
992
993 { # This resource represents a long-running operation that is the result of a
994 # network API call.
Bu Sun Kim65020912020-05-20 12:08:20 -0700995 &quot;response&quot;: { # The normal response of the operation in case of success. If the original
996 # method returns no data on success, such as `Delete`, the response is
997 # `google.protobuf.Empty`. If the original method is standard
998 # `Get`/`Create`/`Update`, the response should be the resource. For other
999 # methods, the response should have the type `XxxResponse`, where `Xxx`
1000 # is the original method name. For example, if the original method name
1001 # is `TakeSnapshot()`, the inferred response type is
1002 # `TakeSnapshotResponse`.
1003 &quot;a_key&quot;: &quot;&quot;, # Properties of the object. Contains field @type with type URL.
1004 },
Bu Sun Kim65020912020-05-20 12:08:20 -07001005 &quot;metadata&quot;: { # {
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001006 #
1007 # `createTime`: The time the operation was created.
1008 #
1009 # `endTime`: The time the operation finished running.
1010 #
1011 # `target`: Server-defined resource path for the target of the operation.
1012 #
1013 # `verb`: Name of the verb executed by the operation.
1014 #
1015 # `statusDetail`: Human-readable status of the operation, if any.
1016 #
1017 # `cancelRequested`: 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 of 1, corresponding to `Code.CANCELLED`.
1018 #
1019 # `apiVersion`: API version used to start the operation.
1020 #
1021 # }
Bu Sun Kim65020912020-05-20 12:08:20 -07001022 &quot;a_key&quot;: &quot;&quot;, # Properties of the object. Contains field @type with type URL.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001023 },
Bu Sun Kimd059ad82020-07-22 17:02:09 -07001024 &quot;done&quot;: True or False, # If the value is `false`, it means the operation is still in progress.
1025 # If `true`, the operation is completed, and either `error` or `response` is
1026 # available.
1027 &quot;error&quot;: { # The `Status` type defines a logical error model that is suitable for # The error result of the operation in case of failure or cancellation.
1028 # different programming environments, including REST APIs and RPC APIs. It is
1029 # used by [gRPC](https://github.com/grpc). Each `Status` message contains
1030 # three pieces of data: error code, error message, and error details.
1031 #
1032 # You can find out more about this error model and how to work with it in the
1033 # [API Design Guide](https://cloud.google.com/apis/design/errors).
1034 &quot;message&quot;: &quot;A String&quot;, # A developer-facing error message, which should be in English. Any
1035 # user-facing error message should be localized and sent in the
1036 # google.rpc.Status.details field, or localized by the client.
1037 &quot;code&quot;: 42, # The status code, which should be an enum value of google.rpc.Code.
1038 &quot;details&quot;: [ # A list of messages that carry the error details. There is a common set of
1039 # message types for APIs to use.
1040 {
1041 &quot;a_key&quot;: &quot;&quot;, # Properties of the object. Contains field @type with type URL.
1042 },
1043 ],
1044 },
1045 &quot;name&quot;: &quot;A String&quot;, # The server-assigned name, which is only unique within the same service that
1046 # originally returns it. If you use the default HTTP mapping, the
1047 # `name` should be a resource name ending with `operations/{unique_id}`.
Dan O'Mearadd494642020-05-01 07:42:23 -07001048 }</pre>
1049</div>
1050
1051<div class="method">
1052 <code class="details" id="upgrade">upgrade(name, body=None, x__xgafv=None)</code>
1053 <pre>Upgrades Redis instance to the newer Redis version specified in the
1054request.
1055
1056Args:
1057 name: string, Required. Redis instance resource name using the form:
1058 `projects/{project_id}/locations/{location_id}/instances/{instance_id}`
1059where `location_id` refers to a GCP region. (required)
1060 body: object, The request body.
1061 The object takes the form of:
1062
1063{ # Request for UpgradeInstance.
Bu Sun Kim65020912020-05-20 12:08:20 -07001064 &quot;redisVersion&quot;: &quot;A String&quot;, # Required. Specifies the target version of Redis software to upgrade to.
Dan O'Mearadd494642020-05-01 07:42:23 -07001065 }
1066
1067 x__xgafv: string, V1 error format.
1068 Allowed values
1069 1 - v1 error format
1070 2 - v2 error format
1071
1072Returns:
1073 An object of the form:
1074
1075 { # This resource represents a long-running operation that is the result of a
1076 # network API call.
Bu Sun Kim65020912020-05-20 12:08:20 -07001077 &quot;response&quot;: { # The normal response of the operation in case of success. If the original
1078 # method returns no data on success, such as `Delete`, the response is
1079 # `google.protobuf.Empty`. If the original method is standard
1080 # `Get`/`Create`/`Update`, the response should be the resource. For other
1081 # methods, the response should have the type `XxxResponse`, where `Xxx`
1082 # is the original method name. For example, if the original method name
1083 # is `TakeSnapshot()`, the inferred response type is
1084 # `TakeSnapshotResponse`.
1085 &quot;a_key&quot;: &quot;&quot;, # Properties of the object. Contains field @type with type URL.
1086 },
Bu Sun Kim65020912020-05-20 12:08:20 -07001087 &quot;metadata&quot;: { # {
Dan O'Mearadd494642020-05-01 07:42:23 -07001088 #
1089 # `createTime`: The time the operation was created.
1090 #
1091 # `endTime`: The time the operation finished running.
1092 #
1093 # `target`: Server-defined resource path for the target of the operation.
1094 #
1095 # `verb`: Name of the verb executed by the operation.
1096 #
1097 # `statusDetail`: Human-readable status of the operation, if any.
1098 #
1099 # `cancelRequested`: 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 of 1, corresponding to `Code.CANCELLED`.
1100 #
1101 # `apiVersion`: API version used to start the operation.
1102 #
1103 # }
Bu Sun Kim65020912020-05-20 12:08:20 -07001104 &quot;a_key&quot;: &quot;&quot;, # Properties of the object. Contains field @type with type URL.
Dan O'Mearadd494642020-05-01 07:42:23 -07001105 },
Bu Sun Kimd059ad82020-07-22 17:02:09 -07001106 &quot;done&quot;: True or False, # If the value is `false`, it means the operation is still in progress.
1107 # If `true`, the operation is completed, and either `error` or `response` is
1108 # available.
1109 &quot;error&quot;: { # The `Status` type defines a logical error model that is suitable for # The error result of the operation in case of failure or cancellation.
1110 # different programming environments, including REST APIs and RPC APIs. It is
1111 # used by [gRPC](https://github.com/grpc). Each `Status` message contains
1112 # three pieces of data: error code, error message, and error details.
1113 #
1114 # You can find out more about this error model and how to work with it in the
1115 # [API Design Guide](https://cloud.google.com/apis/design/errors).
1116 &quot;message&quot;: &quot;A String&quot;, # A developer-facing error message, which should be in English. Any
1117 # user-facing error message should be localized and sent in the
1118 # google.rpc.Status.details field, or localized by the client.
1119 &quot;code&quot;: 42, # The status code, which should be an enum value of google.rpc.Code.
1120 &quot;details&quot;: [ # A list of messages that carry the error details. There is a common set of
1121 # message types for APIs to use.
1122 {
1123 &quot;a_key&quot;: &quot;&quot;, # Properties of the object. Contains field @type with type URL.
1124 },
1125 ],
1126 },
1127 &quot;name&quot;: &quot;A String&quot;, # The server-assigned name, which is only unique within the same service that
1128 # originally returns it. If you use the default HTTP mapping, the
1129 # `name` should be a resource name ending with `operations/{unique_id}`.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001130 }</pre>
1131</div>
1132
1133</body></html>