blob: 012f2ecfec160b0db0971cf5a0414ff1773b0336 [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_v1.html">Google Cloud Memorystore for Redis API</a> . <a href="redis_v1.projects.html">projects</a> . <a href="redis_v1.projects.locations.html">locations</a> . <a href="redis_v1.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>
Bu Sun Kim715bd7f2019-06-14 16:50:42 -070088<p class="firstline">Initiates a failover of the master node to current replica node for a</p>
89<p class="toc_element">
90 <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 Kim715bd7f2019-06-14 16:50:42 -0700113[default network](/compute/docs/networks-and-firewalls#networks).
114
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 Kim65020912020-05-20 12:08:20 -0700131 &quot;displayName&quot;: &quot;A String&quot;, # An arbitrary and optional user-provided name for the instance.
132 &quot;locationId&quot;: &quot;A String&quot;, # Optional. The zone where the instance will be provisioned. If not provided,
133 # the service will choose a zone for the instance. For STANDARD_HA tier,
134 # instances will be created across two zones for protection against zonal
135 # failures. If alternative_location_id is also provided, it must be
136 # different from location_id.
137 &quot;reservedIpRange&quot;: &quot;A String&quot;, # Optional. The CIDR range of internal addresses that are reserved for this
138 # instance. If not provided, the service will choose an unused /29 block,
139 # for example, 10.0.0.0/29 or 192.168.0.0/29. Ranges must be unique
140 # and non-overlapping with existing subnets in an authorized network.
141 &quot;currentLocationId&quot;: &quot;A String&quot;, # Output only. The current zone where the Redis endpoint is placed. For Basic
142 # Tier instances, this will always be the same as the location_id
143 # provided by the user at creation time. For Standard Tier instances,
144 # this can be either location_id or alternative_location_id and can
145 # change after a failover event.
146 &quot;alternativeLocationId&quot;: &quot;A String&quot;, # Optional. Only applicable to STANDARD_HA tier which protects the instance
147 # against zonal failures by provisioning it across two zones. If provided, it
148 # must be a different zone from the one provided in location_id.
149 &quot;createTime&quot;: &quot;A String&quot;, # Output only. The time the instance was created.
150 &quot;labels&quot;: { # Resource labels to represent user provided metadata
151 &quot;a_key&quot;: &quot;A String&quot;,
152 },
153 &quot;statusMessage&quot;: &quot;A String&quot;, # Output only. Additional information about the current status of this
154 # instance, if available.
155 &quot;authorizedNetwork&quot;: &quot;A String&quot;, # Optional. The full name of the Google Compute Engine
156 # [network](/compute/docs/networks-and-firewalls#networks) to which the
157 # instance is connected. If left unspecified, the `default` network
158 # will be used.
159 &quot;state&quot;: &quot;A String&quot;, # Output only. The current state of this instance.
160 &quot;name&quot;: &quot;A String&quot;, # Required. Unique name of the resource in this scope including project and
161 # location using the form:
162 # `projects/{project_id}/locations/{location_id}/instances/{instance_id}`
163 #
164 # Note: Redis instances are managed and addressed at regional level so
165 # location_id here refers to a GCP region; however, users may choose which
166 # specific zone (or collection of zones for cross-zone instances) an instance
167 # should be provisioned in. Refer to location_id and
168 # alternative_location_id fields for more details.
169 &quot;connectMode&quot;: &quot;A String&quot;, # Optional. The network connect mode of the Redis instance.
170 # If not provided, the connect mode defaults to DIRECT_PEERING.
171 &quot;persistenceIamIdentity&quot;: &quot;A String&quot;, # Output only. Cloud IAM identity used by import / export operations to
172 # transfer data to/from Cloud Storage. Format is
173 # &quot;serviceAccount:&lt;service_account_email&gt;&quot;. The value may change over time
174 # for a given instance so should be checked before each import/export
175 # operation.
176 &quot;redisConfigs&quot;: { # Optional. Redis configuration parameters, according to
177 # http://redis.io/topics/config. Currently, the only supported parameters
178 # are:
179 #
180 # Redis version 3.2 and newer:
181 #
182 # * maxmemory-policy
183 # * notify-keyspace-events
184 #
185 # Redis version 4.0 and newer:
186 #
187 # * activedefrag
188 # * lfu-decay-time
189 # * lfu-log-factor
190 # * maxmemory-gb
191 #
192 # Redis version 5.0 and newer:
193 #
194 # * stream-node-max-bytes
195 # * stream-node-max-entries
196 &quot;a_key&quot;: &quot;A String&quot;,
197 },
198 &quot;port&quot;: 42, # Output only. The port number of the exposed Redis endpoint.
199 &quot;host&quot;: &quot;A String&quot;, # Output only. Hostname or IP address of the exposed Redis endpoint used by
200 # clients to connect to the service.
201 &quot;redisVersion&quot;: &quot;A String&quot;, # Optional. The version of Redis software.
202 # If not provided, latest supported version will be used. Currently, the
203 # supported values are:
204 #
205 # * `REDIS_3_2` for Redis 3.2 compatibility
206 # * `REDIS_4_0` for Redis 4.0 compatibility (default)
207 # * `REDIS_5_0` for Redis 5.0 compatibility
208 &quot;tier&quot;: &quot;A String&quot;, # Required. The service tier of the instance.
209 &quot;memorySizeGb&quot;: 42, # Required. Redis memory size in GiB.
210 }
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;name&quot;: &quot;A String&quot;, # The server-assigned name, which is only unique within the same service that
231 # originally returns it. If you use the default HTTP mapping, the
232 # `name` should be a resource name ending with `operations/{unique_id}`.
233 &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.
234 # different programming environments, including REST APIs and RPC APIs. It is
235 # used by [gRPC](https://github.com/grpc). Each `Status` message contains
236 # three pieces of data: error code, error message, and error details.
237 #
238 # You can find out more about this error model and how to work with it in the
239 # [API Design Guide](https://cloud.google.com/apis/design/errors).
240 &quot;details&quot;: [ # A list of messages that carry the error details. There is a common set of
241 # message types for APIs to use.
242 {
243 &quot;a_key&quot;: &quot;&quot;, # Properties of the object. Contains field @type with type URL.
244 },
245 ],
246 &quot;code&quot;: 42, # The status code, which should be an enum value of google.rpc.Code.
247 &quot;message&quot;: &quot;A String&quot;, # A developer-facing error message, which should be in English. Any
248 # user-facing error message should be localized and sent in the
249 # google.rpc.Status.details field, or localized by the client.
Dan O'Mearadd494642020-05-01 07:42:23 -0700250 },
Bu Sun Kim65020912020-05-20 12:08:20 -0700251 &quot;metadata&quot;: { # {
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700252 #
253 # `createTime`: The time the operation was created.
254 #
255 # `endTime`: The time the operation finished running.
256 #
257 # `target`: Server-defined resource path for the target of the operation.
258 #
259 # `verb`: Name of the verb executed by the operation.
260 #
261 # `statusDetail`: Human-readable status of the operation, if any.
262 #
263 # `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`.
264 #
265 # `apiVersion`: API version used to start the operation.
266 #
267 # }
Bu Sun Kim65020912020-05-20 12:08:20 -0700268 &quot;a_key&quot;: &quot;&quot;, # Properties of the object. Contains field @type with type URL.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700269 },
Bu Sun Kim65020912020-05-20 12:08:20 -0700270 &quot;done&quot;: True or False, # If the value is `false`, it means the operation is still in progress.
Dan O'Mearadd494642020-05-01 07:42:23 -0700271 # If `true`, the operation is completed, and either `error` or `response` is
272 # available.
Bu Sun Kim65020912020-05-20 12:08:20 -0700273 &quot;response&quot;: { # The normal response of the operation in case of success. If the original
274 # method returns no data on success, such as `Delete`, the response is
275 # `google.protobuf.Empty`. If the original method is standard
276 # `Get`/`Create`/`Update`, the response should be the resource. For other
277 # methods, the response should have the type `XxxResponse`, where `Xxx`
278 # is the original method name. For example, if the original method name
279 # is `TakeSnapshot()`, the inferred response type is
280 # `TakeSnapshotResponse`.
281 &quot;a_key&quot;: &quot;&quot;, # Properties of the object. Contains field @type with type URL.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700282 },
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;name&quot;: &quot;A String&quot;, # The server-assigned name, which is only unique within the same service that
306 # originally returns it. If you use the default HTTP mapping, the
307 # `name` should be a resource name ending with `operations/{unique_id}`.
308 &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.
309 # different programming environments, including REST APIs and RPC APIs. It is
310 # used by [gRPC](https://github.com/grpc). Each `Status` message contains
311 # three pieces of data: error code, error message, and error details.
312 #
313 # You can find out more about this error model and how to work with it in the
314 # [API Design Guide](https://cloud.google.com/apis/design/errors).
315 &quot;details&quot;: [ # A list of messages that carry the error details. There is a common set of
316 # message types for APIs to use.
317 {
318 &quot;a_key&quot;: &quot;&quot;, # Properties of the object. Contains field @type with type URL.
319 },
320 ],
321 &quot;code&quot;: 42, # The status code, which should be an enum value of google.rpc.Code.
322 &quot;message&quot;: &quot;A String&quot;, # A developer-facing error message, which should be in English. Any
323 # user-facing error message should be localized and sent in the
324 # google.rpc.Status.details field, or localized by the client.
Dan O'Mearadd494642020-05-01 07:42:23 -0700325 },
Bu Sun Kim65020912020-05-20 12:08:20 -0700326 &quot;metadata&quot;: { # {
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700327 #
328 # `createTime`: The time the operation was created.
329 #
330 # `endTime`: The time the operation finished running.
331 #
332 # `target`: Server-defined resource path for the target of the operation.
333 #
334 # `verb`: Name of the verb executed by the operation.
335 #
336 # `statusDetail`: Human-readable status of the operation, if any.
337 #
338 # `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`.
339 #
340 # `apiVersion`: API version used to start the operation.
341 #
342 # }
Bu Sun Kim65020912020-05-20 12:08:20 -0700343 &quot;a_key&quot;: &quot;&quot;, # Properties of the object. Contains field @type with type URL.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700344 },
Bu Sun Kim65020912020-05-20 12:08:20 -0700345 &quot;done&quot;: True or False, # If the value is `false`, it means the operation is still in progress.
Dan O'Mearadd494642020-05-01 07:42:23 -0700346 # If `true`, the operation is completed, and either `error` or `response` is
347 # available.
Bu Sun Kim65020912020-05-20 12:08:20 -0700348 &quot;response&quot;: { # The normal response of the operation in case of success. If the original
349 # method returns no data on success, such as `Delete`, the response is
350 # `google.protobuf.Empty`. If the original method is standard
351 # `Get`/`Create`/`Update`, the response should be the resource. For other
352 # methods, the response should have the type `XxxResponse`, where `Xxx`
353 # is the original method name. For example, if the original method name
354 # is `TakeSnapshot()`, the inferred response type is
355 # `TakeSnapshotResponse`.
356 &quot;a_key&quot;: &quot;&quot;, # Properties of the object. Contains field @type with type URL.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700357 },
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;name&quot;: &quot;A String&quot;, # The server-assigned name, which is only unique within the same service that
397 # originally returns it. If you use the default HTTP mapping, the
398 # `name` should be a resource name ending with `operations/{unique_id}`.
399 &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.
400 # different programming environments, including REST APIs and RPC APIs. It is
401 # used by [gRPC](https://github.com/grpc). Each `Status` message contains
402 # three pieces of data: error code, error message, and error details.
403 #
404 # You can find out more about this error model and how to work with it in the
405 # [API Design Guide](https://cloud.google.com/apis/design/errors).
406 &quot;details&quot;: [ # A list of messages that carry the error details. There is a common set of
407 # message types for APIs to use.
408 {
409 &quot;a_key&quot;: &quot;&quot;, # Properties of the object. Contains field @type with type URL.
410 },
411 ],
412 &quot;code&quot;: 42, # The status code, which should be an enum value of google.rpc.Code.
413 &quot;message&quot;: &quot;A String&quot;, # A developer-facing error message, which should be in English. Any
414 # user-facing error message should be localized and sent in the
415 # google.rpc.Status.details field, or localized by the client.
Dan O'Mearadd494642020-05-01 07:42:23 -0700416 },
Bu Sun Kim65020912020-05-20 12:08:20 -0700417 &quot;metadata&quot;: { # {
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700418 #
419 # `createTime`: The time the operation was created.
420 #
421 # `endTime`: The time the operation finished running.
422 #
423 # `target`: Server-defined resource path for the target of the operation.
424 #
425 # `verb`: Name of the verb executed by the operation.
426 #
427 # `statusDetail`: Human-readable status of the operation, if any.
428 #
429 # `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`.
430 #
431 # `apiVersion`: API version used to start the operation.
432 #
433 # }
Bu Sun Kim65020912020-05-20 12:08:20 -0700434 &quot;a_key&quot;: &quot;&quot;, # Properties of the object. Contains field @type with type URL.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700435 },
Bu Sun Kim65020912020-05-20 12:08:20 -0700436 &quot;done&quot;: True or False, # If the value is `false`, it means the operation is still in progress.
Dan O'Mearadd494642020-05-01 07:42:23 -0700437 # If `true`, the operation is completed, and either `error` or `response` is
438 # available.
Bu Sun Kim65020912020-05-20 12:08:20 -0700439 &quot;response&quot;: { # The normal response of the operation in case of success. If the original
440 # method returns no data on success, such as `Delete`, the response is
441 # `google.protobuf.Empty`. If the original method is standard
442 # `Get`/`Create`/`Update`, the response should be the resource. For other
443 # methods, the response should have the type `XxxResponse`, where `Xxx`
444 # is the original method name. For example, if the original method name
445 # is `TakeSnapshot()`, the inferred response type is
446 # `TakeSnapshotResponse`.
447 &quot;a_key&quot;: &quot;&quot;, # Properties of the object. Contains field @type with type URL.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700448 },
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700449 }</pre>
450</div>
451
452<div class="method">
Dan O'Mearadd494642020-05-01 07:42:23 -0700453 <code class="details" id="failover">failover(name, body=None, x__xgafv=None)</code>
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700454 <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)
Dan O'Mearadd494642020-05-01 07:42:23 -0700461 body: object, The request body.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700462 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
Bu Sun Kim715bd7f2019-06-14 16:50:42 -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;name&quot;: &quot;A String&quot;, # The server-assigned name, which is only unique within the same service that
480 # originally returns it. If you use the default HTTP mapping, the
481 # `name` should be a resource name ending with `operations/{unique_id}`.
482 &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.
483 # different programming environments, including REST APIs and RPC APIs. It is
484 # used by [gRPC](https://github.com/grpc). Each `Status` message contains
485 # three pieces of data: error code, error message, and error details.
486 #
487 # You can find out more about this error model and how to work with it in the
488 # [API Design Guide](https://cloud.google.com/apis/design/errors).
489 &quot;details&quot;: [ # A list of messages that carry the error details. There is a common set of
490 # message types for APIs to use.
491 {
492 &quot;a_key&quot;: &quot;&quot;, # Properties of the object. Contains field @type with type URL.
493 },
494 ],
495 &quot;code&quot;: 42, # The status code, which should be an enum value of google.rpc.Code.
496 &quot;message&quot;: &quot;A String&quot;, # A developer-facing error message, which should be in English. Any
497 # user-facing error message should be localized and sent in the
498 # google.rpc.Status.details field, or localized by the client.
Dan O'Mearadd494642020-05-01 07:42:23 -0700499 },
Bu Sun Kim65020912020-05-20 12:08:20 -0700500 &quot;metadata&quot;: { # {
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700501 #
502 # `createTime`: The time the operation was created.
503 #
504 # `endTime`: The time the operation finished running.
505 #
506 # `target`: Server-defined resource path for the target of the operation.
507 #
508 # `verb`: Name of the verb executed by the operation.
509 #
510 # `statusDetail`: Human-readable status of the operation, if any.
511 #
512 # `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`.
513 #
514 # `apiVersion`: API version used to start the operation.
515 #
516 # }
Bu Sun Kim65020912020-05-20 12:08:20 -0700517 &quot;a_key&quot;: &quot;&quot;, # Properties of the object. Contains field @type with type URL.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700518 },
Bu Sun Kim65020912020-05-20 12:08:20 -0700519 &quot;done&quot;: True or False, # If the value is `false`, it means the operation is still in progress.
Dan O'Mearadd494642020-05-01 07:42:23 -0700520 # If `true`, the operation is completed, and either `error` or `response` is
521 # available.
Bu Sun Kim65020912020-05-20 12:08:20 -0700522 &quot;response&quot;: { # The normal response of the operation in case of success. If the original
523 # method returns no data on success, such as `Delete`, the response is
524 # `google.protobuf.Empty`. If the original method is standard
525 # `Get`/`Create`/`Update`, the response should be the resource. For other
526 # methods, the response should have the type `XxxResponse`, where `Xxx`
527 # is the original method name. For example, if the original method name
528 # is `TakeSnapshot()`, the inferred response type is
529 # `TakeSnapshotResponse`.
530 &quot;a_key&quot;: &quot;&quot;, # Properties of the object. Contains field @type with type URL.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700531 },
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 Kim65020912020-05-20 12:08:20 -0700552 &quot;displayName&quot;: &quot;A String&quot;, # An arbitrary and optional user-provided name for the instance.
553 &quot;locationId&quot;: &quot;A String&quot;, # Optional. The zone where the instance will be provisioned. If not provided,
554 # the service will choose a zone for the instance. For STANDARD_HA tier,
555 # instances will be created across two zones for protection against zonal
556 # failures. If alternative_location_id is also provided, it must be
557 # different from location_id.
558 &quot;reservedIpRange&quot;: &quot;A String&quot;, # Optional. The CIDR range of internal addresses that are reserved for this
559 # instance. If not provided, the service will choose an unused /29 block,
560 # for example, 10.0.0.0/29 or 192.168.0.0/29. Ranges must be unique
561 # and non-overlapping with existing subnets in an authorized network.
562 &quot;currentLocationId&quot;: &quot;A String&quot;, # Output only. The current zone where the Redis endpoint is placed. For Basic
563 # Tier instances, this will always be the same as the location_id
564 # provided by the user at creation time. For Standard Tier instances,
565 # this can be either location_id or alternative_location_id and can
566 # change after a failover event.
567 &quot;alternativeLocationId&quot;: &quot;A String&quot;, # Optional. Only applicable to STANDARD_HA tier which protects the instance
568 # against zonal failures by provisioning it across two zones. If provided, it
569 # must be a different zone from the one provided in location_id.
570 &quot;createTime&quot;: &quot;A String&quot;, # Output only. The time the instance was created.
571 &quot;labels&quot;: { # Resource labels to represent user provided metadata
572 &quot;a_key&quot;: &quot;A String&quot;,
573 },
574 &quot;statusMessage&quot;: &quot;A String&quot;, # Output only. Additional information about the current status of this
575 # instance, if available.
576 &quot;authorizedNetwork&quot;: &quot;A String&quot;, # Optional. The full name of the Google Compute Engine
577 # [network](/compute/docs/networks-and-firewalls#networks) to which the
578 # instance is connected. If left unspecified, the `default` network
579 # will be used.
580 &quot;state&quot;: &quot;A String&quot;, # Output only. The current state of this instance.
581 &quot;name&quot;: &quot;A String&quot;, # Required. Unique name of the resource in this scope including project and
582 # location using the form:
583 # `projects/{project_id}/locations/{location_id}/instances/{instance_id}`
584 #
585 # Note: Redis instances are managed and addressed at regional level so
586 # location_id here refers to a GCP region; however, users may choose which
587 # specific zone (or collection of zones for cross-zone instances) an instance
588 # should be provisioned in. Refer to location_id and
589 # alternative_location_id fields for more details.
590 &quot;connectMode&quot;: &quot;A String&quot;, # Optional. The network connect mode of the Redis instance.
591 # If not provided, the connect mode defaults to DIRECT_PEERING.
592 &quot;persistenceIamIdentity&quot;: &quot;A String&quot;, # Output only. Cloud IAM identity used by import / export operations to
593 # transfer data to/from Cloud Storage. Format is
594 # &quot;serviceAccount:&lt;service_account_email&gt;&quot;. The value may change over time
595 # for a given instance so should be checked before each import/export
596 # operation.
597 &quot;redisConfigs&quot;: { # Optional. Redis configuration parameters, according to
598 # http://redis.io/topics/config. Currently, the only supported parameters
599 # are:
600 #
601 # Redis version 3.2 and newer:
602 #
603 # * maxmemory-policy
604 # * notify-keyspace-events
605 #
606 # Redis version 4.0 and newer:
607 #
608 # * activedefrag
609 # * lfu-decay-time
610 # * lfu-log-factor
611 # * maxmemory-gb
612 #
613 # Redis version 5.0 and newer:
614 #
615 # * stream-node-max-bytes
616 # * stream-node-max-entries
617 &quot;a_key&quot;: &quot;A String&quot;,
618 },
619 &quot;port&quot;: 42, # Output only. The port number of the exposed Redis endpoint.
620 &quot;host&quot;: &quot;A String&quot;, # Output only. Hostname or IP address of the exposed Redis endpoint used by
621 # clients to connect to the service.
622 &quot;redisVersion&quot;: &quot;A String&quot;, # Optional. The version of Redis software.
623 # If not provided, latest supported version will be used. Currently, the
624 # supported values are:
625 #
626 # * `REDIS_3_2` for Redis 3.2 compatibility
627 # * `REDIS_4_0` for Redis 4.0 compatibility (default)
628 # * `REDIS_5_0` for Redis 5.0 compatibility
629 &quot;tier&quot;: &quot;A String&quot;, # Required. The service tier of the instance.
630 &quot;memorySizeGb&quot;: 42, # Required. Redis memory size in GiB.
631 }</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;name&quot;: &quot;A String&quot;, # The server-assigned name, which is only unique within the same service that
671 # originally returns it. If you use the default HTTP mapping, the
672 # `name` should be a resource name ending with `operations/{unique_id}`.
673 &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.
674 # different programming environments, including REST APIs and RPC APIs. It is
675 # used by [gRPC](https://github.com/grpc). Each `Status` message contains
676 # three pieces of data: error code, error message, and error details.
677 #
678 # You can find out more about this error model and how to work with it in the
679 # [API Design Guide](https://cloud.google.com/apis/design/errors).
680 &quot;details&quot;: [ # A list of messages that carry the error details. There is a common set of
681 # message types for APIs to use.
682 {
683 &quot;a_key&quot;: &quot;&quot;, # Properties of the object. Contains field @type with type URL.
684 },
685 ],
686 &quot;code&quot;: 42, # The status code, which should be an enum value of google.rpc.Code.
687 &quot;message&quot;: &quot;A String&quot;, # A developer-facing error message, which should be in English. Any
688 # user-facing error message should be localized and sent in the
689 # google.rpc.Status.details field, or localized by the client.
Dan O'Mearadd494642020-05-01 07:42:23 -0700690 },
Bu Sun Kim65020912020-05-20 12:08:20 -0700691 &quot;metadata&quot;: { # {
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700692 #
693 # `createTime`: The time the operation was created.
694 #
695 # `endTime`: The time the operation finished running.
696 #
697 # `target`: Server-defined resource path for the target of the operation.
698 #
699 # `verb`: Name of the verb executed by the operation.
700 #
701 # `statusDetail`: Human-readable status of the operation, if any.
702 #
703 # `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`.
704 #
705 # `apiVersion`: API version used to start the operation.
706 #
707 # }
Bu Sun Kim65020912020-05-20 12:08:20 -0700708 &quot;a_key&quot;: &quot;&quot;, # Properties of the object. Contains field @type with type URL.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700709 },
Bu Sun Kim65020912020-05-20 12:08:20 -0700710 &quot;done&quot;: True or False, # If the value is `false`, it means the operation is still in progress.
Dan O'Mearadd494642020-05-01 07:42:23 -0700711 # If `true`, the operation is completed, and either `error` or `response` is
712 # available.
Bu Sun Kim65020912020-05-20 12:08:20 -0700713 &quot;response&quot;: { # The normal response of the operation in case of success. If the original
714 # method returns no data on success, such as `Delete`, the response is
715 # `google.protobuf.Empty`. If the original method is standard
716 # `Get`/`Create`/`Update`, the response should be the resource. For other
717 # methods, the response should have the type `XxxResponse`, where `Xxx`
718 # is the original method name. For example, if the original method name
719 # is `TakeSnapshot()`, the inferred response type is
720 # `TakeSnapshotResponse`.
721 &quot;a_key&quot;: &quot;&quot;, # Properties of the object. Contains field @type with type URL.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700722 },
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)
Bu Sun Kim65020912020-05-20 12:08:20 -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 Kim715bd7f2019-06-14 16:50:42 -0700751 x__xgafv: string, V1 error format.
752 Allowed values
753 1 - v1 error format
754 2 - v2 error format
755
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 Kim65020912020-05-20 12:08:20 -0700771 &quot;displayName&quot;: &quot;A String&quot;, # An arbitrary and optional user-provided name for the instance.
772 &quot;locationId&quot;: &quot;A String&quot;, # Optional. The zone where the instance will be provisioned. If not provided,
773 # the service will choose a zone for the instance. For STANDARD_HA tier,
774 # instances will be created across two zones for protection against zonal
775 # failures. If alternative_location_id is also provided, it must be
776 # different from location_id.
777 &quot;reservedIpRange&quot;: &quot;A String&quot;, # Optional. The CIDR range of internal addresses that are reserved for this
778 # instance. If not provided, the service will choose an unused /29 block,
779 # for example, 10.0.0.0/29 or 192.168.0.0/29. Ranges must be unique
780 # and non-overlapping with existing subnets in an authorized network.
781 &quot;currentLocationId&quot;: &quot;A String&quot;, # Output only. The current zone where the Redis endpoint is placed. For Basic
782 # Tier instances, this will always be the same as the location_id
783 # provided by the user at creation time. For Standard Tier instances,
784 # this can be either location_id or alternative_location_id and can
785 # change after a failover event.
786 &quot;alternativeLocationId&quot;: &quot;A String&quot;, # Optional. Only applicable to STANDARD_HA tier which protects the instance
787 # against zonal failures by provisioning it across two zones. If provided, it
788 # must be a different zone from the one provided in location_id.
789 &quot;createTime&quot;: &quot;A String&quot;, # Output only. The time the instance was created.
790 &quot;labels&quot;: { # Resource labels to represent user provided metadata
791 &quot;a_key&quot;: &quot;A String&quot;,
792 },
793 &quot;statusMessage&quot;: &quot;A String&quot;, # Output only. Additional information about the current status of this
794 # instance, if available.
795 &quot;authorizedNetwork&quot;: &quot;A String&quot;, # Optional. The full name of the Google Compute Engine
796 # [network](/compute/docs/networks-and-firewalls#networks) to which the
797 # instance is connected. If left unspecified, the `default` network
798 # will be used.
799 &quot;state&quot;: &quot;A String&quot;, # Output only. The current state of this instance.
800 &quot;name&quot;: &quot;A String&quot;, # Required. Unique name of the resource in this scope including project and
801 # location using the form:
802 # `projects/{project_id}/locations/{location_id}/instances/{instance_id}`
803 #
804 # Note: Redis instances are managed and addressed at regional level so
805 # location_id here refers to a GCP region; however, users may choose which
806 # specific zone (or collection of zones for cross-zone instances) an instance
807 # should be provisioned in. Refer to location_id and
808 # alternative_location_id fields for more details.
809 &quot;connectMode&quot;: &quot;A String&quot;, # Optional. The network connect mode of the Redis instance.
810 # If not provided, the connect mode defaults to DIRECT_PEERING.
811 &quot;persistenceIamIdentity&quot;: &quot;A String&quot;, # Output only. Cloud IAM identity used by import / export operations to
812 # transfer data to/from Cloud Storage. Format is
813 # &quot;serviceAccount:&lt;service_account_email&gt;&quot;. The value may change over time
814 # for a given instance so should be checked before each import/export
815 # operation.
816 &quot;redisConfigs&quot;: { # Optional. Redis configuration parameters, according to
817 # http://redis.io/topics/config. Currently, the only supported parameters
818 # are:
819 #
820 # Redis version 3.2 and newer:
821 #
822 # * maxmemory-policy
823 # * notify-keyspace-events
824 #
825 # Redis version 4.0 and newer:
826 #
827 # * activedefrag
828 # * lfu-decay-time
829 # * lfu-log-factor
830 # * maxmemory-gb
831 #
832 # Redis version 5.0 and newer:
833 #
834 # * stream-node-max-bytes
835 # * stream-node-max-entries
836 &quot;a_key&quot;: &quot;A String&quot;,
837 },
838 &quot;port&quot;: 42, # Output only. The port number of the exposed Redis endpoint.
839 &quot;host&quot;: &quot;A String&quot;, # Output only. Hostname or IP address of the exposed Redis endpoint used by
840 # clients to connect to the service.
841 &quot;redisVersion&quot;: &quot;A String&quot;, # Optional. The version of Redis software.
842 # If not provided, latest supported version will be used. Currently, the
843 # supported values are:
844 #
845 # * `REDIS_3_2` for Redis 3.2 compatibility
846 # * `REDIS_4_0` for Redis 4.0 compatibility (default)
847 # * `REDIS_5_0` for Redis 5.0 compatibility
848 &quot;tier&quot;: &quot;A String&quot;, # Required. The service tier of the instance.
849 &quot;memorySizeGb&quot;: 42, # Required. Redis memory size in GiB.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700850 },
Bu Sun Kim65020912020-05-20 12:08:20 -0700851 ],
852 &quot;nextPageToken&quot;: &quot;A String&quot;, # Token to retrieve the next page of results, or empty if there are no more
853 # results in the list.
854 &quot;unreachable&quot;: [ # Locations that could not be reached.
855 &quot;A String&quot;,
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700856 ],
857 }</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 Kim65020912020-05-20 12:08:20 -0700896 &quot;displayName&quot;: &quot;A String&quot;, # An arbitrary and optional user-provided name for the instance.
897 &quot;locationId&quot;: &quot;A String&quot;, # Optional. The zone where the instance will be provisioned. If not provided,
898 # the service will choose a zone for the instance. For STANDARD_HA tier,
899 # instances will be created across two zones for protection against zonal
900 # failures. If alternative_location_id is also provided, it must be
901 # different from location_id.
902 &quot;reservedIpRange&quot;: &quot;A String&quot;, # Optional. The CIDR range of internal addresses that are reserved for this
903 # instance. If not provided, the service will choose an unused /29 block,
904 # for example, 10.0.0.0/29 or 192.168.0.0/29. Ranges must be unique
905 # and non-overlapping with existing subnets in an authorized network.
906 &quot;currentLocationId&quot;: &quot;A String&quot;, # Output only. The current zone where the Redis endpoint is placed. For Basic
907 # Tier instances, this will always be the same as the location_id
908 # provided by the user at creation time. For Standard Tier instances,
909 # this can be either location_id or alternative_location_id and can
910 # change after a failover event.
911 &quot;alternativeLocationId&quot;: &quot;A String&quot;, # Optional. Only applicable to STANDARD_HA tier which protects the instance
912 # against zonal failures by provisioning it across two zones. If provided, it
913 # must be a different zone from the one provided in location_id.
914 &quot;createTime&quot;: &quot;A String&quot;, # Output only. The time the instance was created.
915 &quot;labels&quot;: { # Resource labels to represent user provided metadata
916 &quot;a_key&quot;: &quot;A String&quot;,
917 },
918 &quot;statusMessage&quot;: &quot;A String&quot;, # Output only. Additional information about the current status of this
919 # instance, if available.
920 &quot;authorizedNetwork&quot;: &quot;A String&quot;, # Optional. The full name of the Google Compute Engine
921 # [network](/compute/docs/networks-and-firewalls#networks) to which the
922 # instance is connected. If left unspecified, the `default` network
923 # will be used.
924 &quot;state&quot;: &quot;A String&quot;, # Output only. The current state of this instance.
925 &quot;name&quot;: &quot;A String&quot;, # Required. Unique name of the resource in this scope including project and
926 # location using the form:
927 # `projects/{project_id}/locations/{location_id}/instances/{instance_id}`
928 #
929 # Note: Redis instances are managed and addressed at regional level so
930 # location_id here refers to a GCP region; however, users may choose which
931 # specific zone (or collection of zones for cross-zone instances) an instance
932 # should be provisioned in. Refer to location_id and
933 # alternative_location_id fields for more details.
934 &quot;connectMode&quot;: &quot;A String&quot;, # Optional. The network connect mode of the Redis instance.
935 # If not provided, the connect mode defaults to DIRECT_PEERING.
936 &quot;persistenceIamIdentity&quot;: &quot;A String&quot;, # Output only. Cloud IAM identity used by import / export operations to
937 # transfer data to/from Cloud Storage. Format is
938 # &quot;serviceAccount:&lt;service_account_email&gt;&quot;. The value may change over time
939 # for a given instance so should be checked before each import/export
940 # operation.
941 &quot;redisConfigs&quot;: { # Optional. Redis configuration parameters, according to
942 # http://redis.io/topics/config. Currently, the only supported parameters
943 # are:
944 #
945 # Redis version 3.2 and newer:
946 #
947 # * maxmemory-policy
948 # * notify-keyspace-events
949 #
950 # Redis version 4.0 and newer:
951 #
952 # * activedefrag
953 # * lfu-decay-time
954 # * lfu-log-factor
955 # * maxmemory-gb
956 #
957 # Redis version 5.0 and newer:
958 #
959 # * stream-node-max-bytes
960 # * stream-node-max-entries
961 &quot;a_key&quot;: &quot;A String&quot;,
962 },
963 &quot;port&quot;: 42, # Output only. The port number of the exposed Redis endpoint.
964 &quot;host&quot;: &quot;A String&quot;, # Output only. Hostname or IP address of the exposed Redis endpoint used by
965 # clients to connect to the service.
966 &quot;redisVersion&quot;: &quot;A String&quot;, # Optional. The version of Redis software.
967 # If not provided, latest supported version will be used. Currently, the
968 # supported values are:
969 #
970 # * `REDIS_3_2` for Redis 3.2 compatibility
971 # * `REDIS_4_0` for Redis 4.0 compatibility (default)
972 # * `REDIS_5_0` for Redis 5.0 compatibility
973 &quot;tier&quot;: &quot;A String&quot;, # Required. The service tier of the instance.
974 &quot;memorySizeGb&quot;: 42, # Required. Redis memory size in GiB.
975 }
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;name&quot;: &quot;A String&quot;, # The server-assigned name, which is only unique within the same service that
996 # originally returns it. If you use the default HTTP mapping, the
997 # `name` should be a resource name ending with `operations/{unique_id}`.
998 &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.
999 # different programming environments, including REST APIs and RPC APIs. It is
1000 # used by [gRPC](https://github.com/grpc). Each `Status` message contains
1001 # three pieces of data: error code, error message, and error details.
1002 #
1003 # You can find out more about this error model and how to work with it in the
1004 # [API Design Guide](https://cloud.google.com/apis/design/errors).
1005 &quot;details&quot;: [ # A list of messages that carry the error details. There is a common set of
1006 # message types for APIs to use.
1007 {
1008 &quot;a_key&quot;: &quot;&quot;, # Properties of the object. Contains field @type with type URL.
1009 },
1010 ],
1011 &quot;code&quot;: 42, # The status code, which should be an enum value of google.rpc.Code.
1012 &quot;message&quot;: &quot;A String&quot;, # A developer-facing error message, which should be in English. Any
1013 # user-facing error message should be localized and sent in the
1014 # google.rpc.Status.details field, or localized by the client.
Dan O'Mearadd494642020-05-01 07:42:23 -07001015 },
Bu Sun Kim65020912020-05-20 12:08:20 -07001016 &quot;metadata&quot;: { # {
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001017 #
1018 # `createTime`: The time the operation was created.
1019 #
1020 # `endTime`: The time the operation finished running.
1021 #
1022 # `target`: Server-defined resource path for the target of the operation.
1023 #
1024 # `verb`: Name of the verb executed by the operation.
1025 #
1026 # `statusDetail`: Human-readable status of the operation, if any.
1027 #
1028 # `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`.
1029 #
1030 # `apiVersion`: API version used to start the operation.
1031 #
1032 # }
Bu Sun Kim65020912020-05-20 12:08:20 -07001033 &quot;a_key&quot;: &quot;&quot;, # Properties of the object. Contains field @type with type URL.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001034 },
Bu Sun Kim65020912020-05-20 12:08:20 -07001035 &quot;done&quot;: True or False, # If the value is `false`, it means the operation is still in progress.
Dan O'Mearadd494642020-05-01 07:42:23 -07001036 # If `true`, the operation is completed, and either `error` or `response` is
1037 # available.
Bu Sun Kim65020912020-05-20 12:08:20 -07001038 &quot;response&quot;: { # The normal response of the operation in case of success. If the original
1039 # method returns no data on success, such as `Delete`, the response is
1040 # `google.protobuf.Empty`. If the original method is standard
1041 # `Get`/`Create`/`Update`, the response should be the resource. For other
1042 # methods, the response should have the type `XxxResponse`, where `Xxx`
1043 # is the original method name. For example, if the original method name
1044 # is `TakeSnapshot()`, the inferred response type is
1045 # `TakeSnapshotResponse`.
1046 &quot;a_key&quot;: &quot;&quot;, # Properties of the object. Contains field @type with type URL.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001047 },
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;name&quot;: &quot;A String&quot;, # The server-assigned name, which is only unique within the same service that
1078 # originally returns it. If you use the default HTTP mapping, the
1079 # `name` should be a resource name ending with `operations/{unique_id}`.
1080 &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.
1081 # different programming environments, including REST APIs and RPC APIs. It is
1082 # used by [gRPC](https://github.com/grpc). Each `Status` message contains
1083 # three pieces of data: error code, error message, and error details.
1084 #
1085 # You can find out more about this error model and how to work with it in the
1086 # [API Design Guide](https://cloud.google.com/apis/design/errors).
1087 &quot;details&quot;: [ # A list of messages that carry the error details. There is a common set of
1088 # message types for APIs to use.
1089 {
1090 &quot;a_key&quot;: &quot;&quot;, # Properties of the object. Contains field @type with type URL.
1091 },
1092 ],
1093 &quot;code&quot;: 42, # The status code, which should be an enum value of google.rpc.Code.
1094 &quot;message&quot;: &quot;A String&quot;, # A developer-facing error message, which should be in English. Any
1095 # user-facing error message should be localized and sent in the
1096 # google.rpc.Status.details field, or localized by the client.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001097 },
Bu Sun Kim65020912020-05-20 12:08:20 -07001098 &quot;metadata&quot;: { # {
Dan O'Mearadd494642020-05-01 07:42:23 -07001099 #
1100 # `createTime`: The time the operation was created.
1101 #
1102 # `endTime`: The time the operation finished running.
1103 #
1104 # `target`: Server-defined resource path for the target of the operation.
1105 #
1106 # `verb`: Name of the verb executed by the operation.
1107 #
1108 # `statusDetail`: Human-readable status of the operation, if any.
1109 #
1110 # `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`.
1111 #
1112 # `apiVersion`: API version used to start the operation.
1113 #
1114 # }
Bu Sun Kim65020912020-05-20 12:08:20 -07001115 &quot;a_key&quot;: &quot;&quot;, # Properties of the object. Contains field @type with type URL.
Dan O'Mearadd494642020-05-01 07:42:23 -07001116 },
Bu Sun Kim65020912020-05-20 12:08:20 -07001117 &quot;done&quot;: True or False, # If the value is `false`, it means the operation is still in progress.
Dan O'Mearadd494642020-05-01 07:42:23 -07001118 # If `true`, the operation is completed, and either `error` or `response` is
1119 # available.
Bu Sun Kim65020912020-05-20 12:08:20 -07001120 &quot;response&quot;: { # The normal response of the operation in case of success. If the original
1121 # method returns no data on success, such as `Delete`, the response is
1122 # `google.protobuf.Empty`. If the original method is standard
1123 # `Get`/`Create`/`Update`, the response should be the resource. For other
1124 # methods, the response should have the type `XxxResponse`, where `Xxx`
1125 # is the original method name. For example, if the original method name
1126 # is `TakeSnapshot()`, the inferred response type is
1127 # `TakeSnapshotResponse`.
1128 &quot;a_key&quot;: &quot;&quot;, # Properties of the object. Contains field @type with type URL.
Dan O'Mearadd494642020-05-01 07:42:23 -07001129 },
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001130 }</pre>
1131</div>
1132
1133</body></html>