blob: fc8d6a4bd4b3fc5c51aebd8775141ed7e5b7d207 [file] [log] [blame]
Jon Wayne Parrott692617a2017-01-06 09:58:29 -08001<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="compute_v1.html">Compute Engine API</a> . <a href="compute_v1.regionBackendServices.html">regionBackendServices</a></h1>
76<h2>Instance Methods</h2>
77<p class="toc_element">
Dmitry Frenkel3e17f892020-10-06 16:46:05 -070078 <code><a href="#close">close()</a></code></p>
79<p class="firstline">Close httplib2 connections.</p>
80<p class="toc_element">
Bu Sun Kim715bd7f2019-06-14 16:50:42 -070081 <code><a href="#delete">delete(project, region, backendService, requestId=None)</a></code></p>
Jon Wayne Parrott692617a2017-01-06 09:58:29 -080082<p class="firstline">Deletes the specified regional BackendService resource.</p>
83<p class="toc_element">
84 <code><a href="#get">get(project, region, backendService)</a></code></p>
85<p class="firstline">Returns the specified regional BackendService resource.</p>
86<p class="toc_element">
Dan O'Mearadd494642020-05-01 07:42:23 -070087 <code><a href="#getHealth">getHealth(project, region, backendService, body=None)</a></code></p>
Jon Wayne Parrott692617a2017-01-06 09:58:29 -080088<p class="firstline">Gets the most recent health check results for this regional BackendService.</p>
89<p class="toc_element">
Dan O'Mearadd494642020-05-01 07:42:23 -070090 <code><a href="#insert">insert(project, region, body=None, requestId=None)</a></code></p>
Bu Sun Kimd059ad82020-07-22 17:02:09 -070091<p class="firstline">Creates a regional BackendService resource in the specified project using the data included in the request. For more information, see Backend services overview.</p>
Jon Wayne Parrott692617a2017-01-06 09:58:29 -080092<p class="toc_element">
Dmitry Frenkel3e17f892020-10-06 16:46:05 -070093 <code><a href="#list">list(project, region, filter=None, maxResults=None, orderBy=None, pageToken=None, returnPartialSuccess=None)</a></code></p>
Jon Wayne Parrott692617a2017-01-06 09:58:29 -080094<p class="firstline">Retrieves the list of regional BackendService resources available to the specified project in the given region.</p>
95<p class="toc_element">
96 <code><a href="#list_next">list_next(previous_request, previous_response)</a></code></p>
97<p class="firstline">Retrieves the next page of results.</p>
98<p class="toc_element">
Dan O'Mearadd494642020-05-01 07:42:23 -070099 <code><a href="#patch">patch(project, region, backendService, body=None, requestId=None)</a></code></p>
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700100<p class="firstline">Updates the specified regional BackendService resource with the data included in the request. For more information, see Understanding backend services This method supports PATCH semantics and uses the JSON merge patch format and processing rules.</p>
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800101<p class="toc_element">
Dan O'Mearadd494642020-05-01 07:42:23 -0700102 <code><a href="#update">update(project, region, backendService, body=None, requestId=None)</a></code></p>
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700103<p class="firstline">Updates the specified regional BackendService resource with the data included in the request. For more information, see Backend services overview.</p>
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800104<h3>Method Details</h3>
105<div class="method">
Dmitry Frenkel3e17f892020-10-06 16:46:05 -0700106 <code class="details" id="close">close()</code>
107 <pre>Close httplib2 connections.</pre>
108</div>
109
110<div class="method">
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700111 <code class="details" id="delete">delete(project, region, backendService, requestId=None)</code>
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800112 <pre>Deletes the specified regional BackendService resource.
113
114Args:
115 project: string, Project ID for this request. (required)
116 region: string, Name of the region scoping this request. (required)
117 backendService: string, Name of the BackendService resource to delete. (required)
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700118 requestId: string, An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed.
119
120For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments.
121
122The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000).
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800123
124Returns:
125 An object of the form:
126
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700127 { # Represents an Operation resource.
128 #
Dan O'Mearadd494642020-05-01 07:42:23 -0700129 # Google Compute Engine has three Operation resources:
130 #
131 # * [Global](/compute/docs/reference/rest/{$api_version}/globalOperations) * [Regional](/compute/docs/reference/rest/{$api_version}/regionOperations) * [Zonal](/compute/docs/reference/rest/{$api_version}/zoneOperations)
132 #
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700133 # You can use an operation resource to manage asynchronous API requests. For more information, read Handling API responses.
134 #
135 # Operations can be global, regional or zonal.
Dan O'Mearadd494642020-05-01 07:42:23 -0700136 # - For global operations, use the `globalOperations` resource.
137 # - For regional operations, use the `regionOperations` resource.
138 # - For zonal operations, use the `zonalOperations` resource.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700139 #
Dan O'Mearadd494642020-05-01 07:42:23 -0700140 # For more information, read Global, Regional, and Zonal Resources. (== resource_for {$api_version}.globalOperations ==) (== resource_for {$api_version}.regionOperations ==) (== resource_for {$api_version}.zoneOperations ==)
Bu Sun Kim65020912020-05-20 12:08:20 -0700141 &quot;clientOperationId&quot;: &quot;A String&quot;, # [Output Only] The value of `requestId` if you provided it in the request. Not present otherwise.
142 &quot;creationTimestamp&quot;: &quot;A String&quot;, # [Deprecated] This field is deprecated.
143 &quot;description&quot;: &quot;A String&quot;, # [Output Only] A textual description of the operation, which is set when the operation is created.
144 &quot;endTime&quot;: &quot;A String&quot;, # [Output Only] The time that this operation was completed. This value is in RFC3339 text format.
145 &quot;error&quot;: { # [Output Only] If errors are generated during processing of the operation, this field will be populated.
146 &quot;errors&quot;: [ # [Output Only] The array of errors encountered while processing this operation.
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800147 {
Bu Sun Kim65020912020-05-20 12:08:20 -0700148 &quot;code&quot;: &quot;A String&quot;, # [Output Only] The error type identifier for this error.
149 &quot;location&quot;: &quot;A String&quot;, # [Output Only] Indicates the field in the request that caused the error. This property is optional.
150 &quot;message&quot;: &quot;A String&quot;, # [Output Only] An optional, human-readable error message.
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800151 },
152 ],
153 },
Bu Sun Kim65020912020-05-20 12:08:20 -0700154 &quot;httpErrorMessage&quot;: &quot;A String&quot;, # [Output Only] If the operation fails, this field contains the HTTP error message that was returned, such as `NOT FOUND`.
155 &quot;httpErrorStatusCode&quot;: 42, # [Output Only] If the operation fails, this field contains the HTTP error status code that was returned. For example, a `404` means the resource was not found.
156 &quot;id&quot;: &quot;A String&quot;, # [Output Only] The unique identifier for the operation. This identifier is defined by the server.
157 &quot;insertTime&quot;: &quot;A String&quot;, # [Output Only] The time that this operation was requested. This value is in RFC3339 text format.
158 &quot;kind&quot;: &quot;compute#operation&quot;, # [Output Only] Type of the resource. Always `compute#operation` for Operation resources.
159 &quot;name&quot;: &quot;A String&quot;, # [Output Only] Name of the operation.
160 &quot;operationType&quot;: &quot;A String&quot;, # [Output Only] The type of operation, such as `insert`, `update`, or `delete`, and so on.
161 &quot;progress&quot;: 42, # [Output Only] An optional progress indicator that ranges from 0 to 100. There is no requirement that this be linear or support any granularity of operations. This should not be used to guess when the operation will be complete. This number should monotonically increase as the operation progresses.
162 &quot;region&quot;: &quot;A String&quot;, # [Output Only] The URL of the region where the operation resides. Only applicable when performing regional operations.
163 &quot;selfLink&quot;: &quot;A String&quot;, # [Output Only] Server-defined URL for the resource.
164 &quot;startTime&quot;: &quot;A String&quot;, # [Output Only] The time that this operation was started by the server. This value is in RFC3339 text format.
165 &quot;status&quot;: &quot;A String&quot;, # [Output Only] The status of the operation, which can be one of the following: `PENDING`, `RUNNING`, or `DONE`.
166 &quot;statusMessage&quot;: &quot;A String&quot;, # [Output Only] An optional textual description of the current status of the operation.
167 &quot;targetId&quot;: &quot;A String&quot;, # [Output Only] The unique target ID, which identifies a specific incarnation of the target resource.
168 &quot;targetLink&quot;: &quot;A String&quot;, # [Output Only] The URL of the resource that the operation modifies. For operations related to creating a snapshot, this points to the persistent disk that the snapshot was created from.
169 &quot;user&quot;: &quot;A String&quot;, # [Output Only] User who requested the operation, for example: `user@example.com`.
170 &quot;warnings&quot;: [ # [Output Only] If warning messages are generated during processing of the operation, this field will be populated.
171 {
172 &quot;code&quot;: &quot;A String&quot;, # [Output Only] A warning code, if applicable. For example, Compute Engine returns NO_RESULTS_ON_PAGE if there are no results in the response.
173 &quot;data&quot;: [ # [Output Only] Metadata about this warning in key: value format. For example:
174 # &quot;data&quot;: [ { &quot;key&quot;: &quot;scope&quot;, &quot;value&quot;: &quot;zones/us-east1-d&quot; }
175 {
176 &quot;key&quot;: &quot;A String&quot;, # [Output Only] A key that provides more detail on the warning being returned. For example, for warnings where there are no results in a list request for a particular zone, this key might be scope and the key value might be the zone name. Other examples might be a key indicating a deprecated resource and a suggested replacement, or a warning about invalid network settings (for example, if an instance attempts to perform IP forwarding but is not enabled for IP forwarding).
177 &quot;value&quot;: &quot;A String&quot;, # [Output Only] A warning data value corresponding to the key.
178 },
179 ],
180 &quot;message&quot;: &quot;A String&quot;, # [Output Only] A human-readable description of the warning code.
181 },
182 ],
183 &quot;zone&quot;: &quot;A String&quot;, # [Output Only] The URL of the zone where the operation resides. Only applicable when performing per-zone operations.
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800184 }</pre>
185</div>
186
187<div class="method">
188 <code class="details" id="get">get(project, region, backendService)</code>
189 <pre>Returns the specified regional BackendService resource.
190
191Args:
192 project: string, Project ID for this request. (required)
193 region: string, Name of the region scoping this request. (required)
194 backendService: string, Name of the BackendService resource to return. (required)
195
196Returns:
197 An object of the form:
198
Dan O'Mearadd494642020-05-01 07:42:23 -0700199 { # Represents a Backend Service resource.
Bu Sun Kim65020912020-05-20 12:08:20 -0700200 #
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700201 # A backend service defines how Google Cloud load balancers distribute traffic. The backend service configuration contains a set of values, such as the protocol used to connect to backends, various distribution and session settings, health checks, and timeouts. These settings provide fine-grained control over how your load balancer behaves. Most of the settings have default values that allow for easy configuration if you need to get started quickly.
Bu Sun Kim65020912020-05-20 12:08:20 -0700202 #
Dan O'Mearadd494642020-05-01 07:42:23 -0700203 # Backend services in Google Compute Engine can be either regionally or globally scoped.
Bu Sun Kim65020912020-05-20 12:08:20 -0700204 #
Dan O'Mearadd494642020-05-01 07:42:23 -0700205 # * [Global](/compute/docs/reference/rest/{$api_version}/backendServices) * [Regional](/compute/docs/reference/rest/{$api_version}/regionBackendServices)
Bu Sun Kim65020912020-05-20 12:08:20 -0700206 #
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700207 # For more information, see Backend Services.
Bu Sun Kim65020912020-05-20 12:08:20 -0700208 #
Dan O'Mearadd494642020-05-01 07:42:23 -0700209 # (== resource_for {$api_version}.backendService ==)
Dmitry Frenkel3e17f892020-10-06 16:46:05 -0700210 &quot;affinityCookieTtlSec&quot;: 42, # Lifetime of cookies in seconds. Only applicable if the loadBalancingScheme is EXTERNAL, INTERNAL_SELF_MANAGED, or INTERNAL_MANAGED, the protocol is HTTP or HTTPS, and the sessionAffinity is GENERATED_COOKIE, or HTTP_COOKIE.
211 #
212 # If set to 0, the cookie is non-persistent and lasts only until the end of the browser session (or equivalent). The maximum allowed value is one day (86,400).
213 #
214 # Not supported when the backend service is referenced by a URL map that is bound to target gRPC proxy that has validateForProxyless field set to true.
Bu Sun Kim65020912020-05-20 12:08:20 -0700215 &quot;backends&quot;: [ # The list of backends that serve this BackendService.
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800216 { # Message containing information of one individual backend.
Bu Sun Kim65020912020-05-20 12:08:20 -0700217 &quot;balancingMode&quot;: &quot;A String&quot;, # Specifies the balancing mode for the backend.
Dan O'Mearadd494642020-05-01 07:42:23 -0700218 #
219 # When choosing a balancing mode, you need to consider the loadBalancingScheme, and protocol for the backend service, as well as the type of backend (instance group or NEG).
220 #
221 #
222 # - If the load balancing mode is CONNECTION, then the load is spread based on how many concurrent connections the backend can handle.
223 # You can use the CONNECTION balancing mode if the protocol for the backend service is SSL, TCP, or UDP.
224 #
225 # If the loadBalancingScheme for the backend service is EXTERNAL (SSL Proxy and TCP Proxy load balancers), you must also specify exactly one of the following parameters: maxConnections (except for regional managed instance groups), maxConnectionsPerInstance, or maxConnectionsPerEndpoint.
226 #
227 # If the loadBalancingScheme for the backend service is INTERNAL (internal TCP/UDP load balancers), you cannot specify any additional parameters.
228 #
229 # - If the load balancing mode is RATE, the load is spread based on the rate of HTTP requests per second (RPS).
230 # You can use the RATE balancing mode if the protocol for the backend service is HTTP or HTTPS. You must specify exactly one of the following parameters: maxRate (except for regional managed instance groups), maxRatePerInstance, or maxRatePerEndpoint.
231 #
232 # - If the load balancing mode is UTILIZATION, the load is spread based on the backend utilization of instances in an instance group.
233 # You can use the UTILIZATION balancing mode if the loadBalancingScheme of the backend service is EXTERNAL, INTERNAL_SELF_MANAGED, or INTERNAL_MANAGED and the backends are instance groups. There are no restrictions on the backend service protocol.
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700234 &quot;capacityScaler&quot;: 3.14, # A multiplier applied to the group&#x27;s maximum servicing capacity (based on UTILIZATION, RATE or CONNECTION). Default value is 1, which means the group will serve up to 100% of its configured capacity (depending on balancingMode). A setting of 0 means the group is completely drained, offering 0% of its available capacity. Valid range is 0.0 and [0.1,1.0]. You cannot configure a setting larger than 0 and smaller than 0.1. You cannot configure a setting of 0 when there is only one backend attached to the backend service.
Bu Sun Kim65020912020-05-20 12:08:20 -0700235 #
236 # This cannot be used for internal load balancing.
237 &quot;description&quot;: &quot;A String&quot;, # An optional description of this resource. Provide this property when you create the resource.
238 &quot;failover&quot;: True or False, # This field designates whether this is a failover backend. More than one failover backend can be configured for a given BackendService.
239 &quot;group&quot;: &quot;A String&quot;, # The fully-qualified URL of an instance group or network endpoint group (NEG) resource. The type of backend that a backend service supports depends on the backend service&#x27;s loadBalancingScheme.
240 #
241 #
242 # - When the loadBalancingScheme for the backend service is EXTERNAL, INTERNAL_SELF_MANAGED, or INTERNAL_MANAGED, the backend can be either an instance group or a NEG. The backends on the backend service must be either all instance groups or all NEGs. You cannot mix instance group and NEG backends on the same backend service.
243 #
244 #
245 # - When the loadBalancingScheme for the backend service is INTERNAL, the backend must be an instance group in the same region as the backend service. NEGs are not supported.
246 #
247 # You must use the fully-qualified URL (starting with https://www.googleapis.com/) to specify the instance group or NEG. Partial URLs are not supported.
248 &quot;maxConnections&quot;: 42, # Defines a target maximum number of simultaneous connections that the backend can handle. Valid for network endpoint group and instance group backends (except for regional managed instance groups). If the backend&#x27;s balancingMode is UTILIZATION, this is an optional parameter. If the backend&#x27;s balancingMode is CONNECTION, and backend is attached to a backend service whose loadBalancingScheme is EXTERNAL, you must specify either this parameter, maxConnectionsPerInstance, or maxConnectionsPerEndpoint.
249 #
250 # Not available if the backend&#x27;s balancingMode is RATE. If the loadBalancingScheme is INTERNAL, then maxConnections is not supported, even though the backend requires a balancing mode of CONNECTION.
251 &quot;maxConnectionsPerEndpoint&quot;: 42, # Defines a target maximum number of simultaneous connections for an endpoint of a NEG. This is multiplied by the number of endpoints in the NEG to implicitly calculate a maximum number of target maximum simultaneous connections for the NEG. If the backend&#x27;s balancingMode is CONNECTION, and the backend is attached to a backend service whose loadBalancingScheme is EXTERNAL, you must specify either this parameter, maxConnections, or maxConnectionsPerInstance.
252 #
253 # Not available if the backend&#x27;s balancingMode is RATE. Internal TCP/UDP load balancing does not support setting maxConnectionsPerEndpoint even though its backends require a balancing mode of CONNECTION.
254 &quot;maxConnectionsPerInstance&quot;: 42, # Defines a target maximum number of simultaneous connections for a single VM in a backend instance group. This is multiplied by the number of instances in the instance group to implicitly calculate a target maximum number of simultaneous connections for the whole instance group. If the backend&#x27;s balancingMode is UTILIZATION, this is an optional parameter. If the backend&#x27;s balancingMode is CONNECTION, and backend is attached to a backend service whose loadBalancingScheme is EXTERNAL, you must specify either this parameter, maxConnections, or maxConnectionsPerEndpoint.
255 #
256 # Not available if the backend&#x27;s balancingMode is RATE. Internal TCP/UDP load balancing does not support setting maxConnectionsPerInstance even though its backends require a balancing mode of CONNECTION.
257 &quot;maxRate&quot;: 42, # Defines a maximum number of HTTP requests per second (RPS) that the backend can handle. Valid for network endpoint group and instance group backends (except for regional managed instance groups). Must not be defined if the backend is a managed instance group that uses autoscaling based on load balancing.
258 #
259 # If the backend&#x27;s balancingMode is UTILIZATION, this is an optional parameter. If the backend&#x27;s balancingMode is RATE, you must specify maxRate, maxRatePerInstance, or maxRatePerEndpoint.
260 #
261 # Not available if the backend&#x27;s balancingMode is CONNECTION.
262 &quot;maxRatePerEndpoint&quot;: 3.14, # Defines a maximum target for requests per second (RPS) for an endpoint of a NEG. This is multiplied by the number of endpoints in the NEG to implicitly calculate a target maximum rate for the NEG.
263 #
264 # If the backend&#x27;s balancingMode is RATE, you must specify either this parameter, maxRate (except for regional managed instance groups), or maxRatePerInstance.
265 #
266 # Not available if the backend&#x27;s balancingMode is CONNECTION.
267 &quot;maxRatePerInstance&quot;: 3.14, # Defines a maximum target for requests per second (RPS) for a single VM in a backend instance group. This is multiplied by the number of instances in the instance group to implicitly calculate a target maximum rate for the whole instance group.
268 #
269 # If the backend&#x27;s balancingMode is UTILIZATION, this is an optional parameter. If the backend&#x27;s balancingMode is RATE, you must specify either this parameter, maxRate (except for regional managed instance groups), or maxRatePerEndpoint.
270 #
271 # Not available if the backend&#x27;s balancingMode is CONNECTION.
272 &quot;maxUtilization&quot;: 3.14, # Defines the maximum average backend utilization of a backend VM in an instance group. The valid range is [0.0, 1.0]. This is an optional parameter if the backend&#x27;s balancingMode is UTILIZATION.
273 #
274 # This parameter can be used in conjunction with maxRate, maxRatePerInstance, maxConnections (except for regional managed instance groups), or maxConnectionsPerInstance.
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800275 },
276 ],
Bu Sun Kim65020912020-05-20 12:08:20 -0700277 &quot;cdnPolicy&quot;: { # Message containing Cloud CDN configuration for a backend service. # Cloud CDN configuration for this BackendService.
278 &quot;cacheKeyPolicy&quot;: { # Message containing what to include in the cache key for a request for Cloud CDN. # The CacheKeyPolicy for this CdnPolicy.
279 &quot;includeHost&quot;: True or False, # If true, requests to different hosts will be cached separately.
280 &quot;includeProtocol&quot;: True or False, # If true, http and https requests will be cached separately.
281 &quot;includeQueryString&quot;: True or False, # If true, include query string parameters in the cache key according to query_string_whitelist and query_string_blacklist. If neither is set, the entire query string will be included. If false, the query string will be excluded from the cache key entirely.
282 &quot;queryStringBlacklist&quot;: [ # Names of query string parameters to exclude in cache keys. All other parameters will be included. Either specify query_string_whitelist or query_string_blacklist, not both. &#x27;&amp;&#x27; and &#x27;=&#x27; will be percent encoded and not treated as delimiters.
283 &quot;A String&quot;,
284 ],
285 &quot;queryStringWhitelist&quot;: [ # Names of query string parameters to include in cache keys. All other parameters will be excluded. Either specify query_string_whitelist or query_string_blacklist, not both. &#x27;&amp;&#x27; and &#x27;=&#x27; will be percent encoded and not treated as delimiters.
286 &quot;A String&quot;,
287 ],
288 },
289 &quot;signedUrlCacheMaxAgeSec&quot;: &quot;A String&quot;, # Maximum number of seconds the response to a signed URL request will be considered fresh. After this time period, the response will be revalidated before being served. Defaults to 1hr (3600s). When serving responses to signed URL requests, Cloud CDN will internally behave as though all responses from this backend had a &quot;Cache-Control: public, max-age=[TTL]&quot; header, regardless of any existing Cache-Control header. The actual headers served in responses will not be altered.
290 &quot;signedUrlKeyNames&quot;: [ # [Output Only] Names of the keys for signing request URLs.
291 &quot;A String&quot;,
292 ],
Sai Cheemalapati4ba8c232017-06-06 18:46:08 -0400293 },
Bu Sun Kim65020912020-05-20 12:08:20 -0700294 &quot;circuitBreakers&quot;: { # Settings controlling the volume of connections to a backend service. # Settings controlling the volume of connections to a backend service. If not set, this feature is considered disabled.
295 #
296 # This field is applicable to either:
297 # - A regional backend service with the service_protocol set to HTTP, HTTPS, or HTTP2, and load_balancing_scheme set to INTERNAL_MANAGED.
298 # - A global backend service with the load_balancing_scheme set to INTERNAL_SELF_MANAGED.
Dmitry Frenkel3e17f892020-10-06 16:46:05 -0700299 #
300 # Not supported when the backend service is referenced by a URL map that is bound to target gRPC proxy that has validateForProxyless field set to true.
Bu Sun Kim65020912020-05-20 12:08:20 -0700301 &quot;maxConnections&quot;: 42, # The maximum number of connections to the backend service. If not specified, there is no limit.
302 &quot;maxPendingRequests&quot;: 42, # The maximum number of pending requests allowed to the backend service. If not specified, there is no limit.
303 &quot;maxRequests&quot;: 42, # The maximum number of parallel requests that allowed to the backend service. If not specified, there is no limit.
304 &quot;maxRequestsPerConnection&quot;: 42, # Maximum requests for a single connection to the backend service. This parameter is respected by both the HTTP/1.1 and HTTP/2 implementations. If not specified, there is no limit. Setting this parameter to 1 will effectively disable keep alive.
305 &quot;maxRetries&quot;: 42, # The maximum number of parallel retries allowed to the backend cluster. If not specified, the default is 1.
306 },
307 &quot;connectionDraining&quot;: { # Message containing connection draining configuration.
308 &quot;drainingTimeoutSec&quot;: 42, # The amount of time in seconds to allow existing connections to persist while on unhealthy backend VMs. Only applicable if the protocol is not UDP. The valid range is [0, 3600].
309 },
310 &quot;consistentHash&quot;: { # This message defines settings for a consistent hash style load balancer. # Consistent Hash-based load balancing can be used to provide soft session affinity based on HTTP headers, cookies or other properties. This load balancing policy is applicable only for HTTP connections. The affinity to a particular destination host will be lost when one or more hosts are added/removed from the destination service. This field specifies parameters that control consistent hashing. This field is only applicable when localityLbPolicy is set to MAGLEV or RING_HASH.
311 #
312 # This field is applicable to either:
313 # - A regional backend service with the service_protocol set to HTTP, HTTPS, or HTTP2, and load_balancing_scheme set to INTERNAL_MANAGED.
314 # - A global backend service with the load_balancing_scheme set to INTERNAL_SELF_MANAGED.
Dmitry Frenkel3e17f892020-10-06 16:46:05 -0700315 #
316 # Not supported when the backend service is referenced by a URL map that is bound to target gRPC proxy that has validateForProxyless field set to true.
Bu Sun Kim65020912020-05-20 12:08:20 -0700317 &quot;httpCookie&quot;: { # The information about the HTTP Cookie on which the hash function is based for load balancing policies that use a consistent hash. # Hash is based on HTTP Cookie. This field describes a HTTP cookie that will be used as the hash key for the consistent hash load balancer. If the cookie is not present, it will be generated. This field is applicable if the sessionAffinity is set to HTTP_COOKIE.
318 &quot;name&quot;: &quot;A String&quot;, # Name of the cookie.
319 &quot;path&quot;: &quot;A String&quot;, # Path to set for the cookie.
320 &quot;ttl&quot;: { # A Duration represents a fixed-length span of time represented as a count of seconds and fractions of seconds at nanosecond resolution. It is independent of any calendar and concepts like &quot;day&quot; or &quot;month&quot;. Range is approximately 10,000 years. # Lifetime of the cookie.
321 &quot;nanos&quot;: 42, # Span of time that&#x27;s a fraction of a second at nanosecond resolution. Durations less than one second are represented with a 0 `seconds` field and a positive `nanos` field. Must be from 0 to 999,999,999 inclusive.
322 &quot;seconds&quot;: &quot;A String&quot;, # Span of time at a resolution of a second. Must be from 0 to 315,576,000,000 inclusive. Note: these bounds are computed from: 60 sec/min * 60 min/hr * 24 hr/day * 365.25 days/year * 10000 years
323 },
324 },
325 &quot;httpHeaderName&quot;: &quot;A String&quot;, # The hash based on the value of the specified header field. This field is applicable if the sessionAffinity is set to HEADER_FIELD.
326 &quot;minimumRingSize&quot;: &quot;A String&quot;, # The minimum number of virtual nodes to use for the hash ring. Defaults to 1024. Larger ring sizes result in more granular load distributions. If the number of hosts in the load balancing pool is larger than the ring size, each host will be assigned a single virtual node.
327 },
328 &quot;creationTimestamp&quot;: &quot;A String&quot;, # [Output Only] Creation timestamp in RFC3339 text format.
329 &quot;customRequestHeaders&quot;: [ # Headers that the HTTP/S load balancer should add to proxied requests.
330 &quot;A String&quot;,
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700331 ],
Bu Sun Kim65020912020-05-20 12:08:20 -0700332 &quot;description&quot;: &quot;A String&quot;, # An optional description of this resource. Provide this property when you create the resource.
333 &quot;enableCDN&quot;: True or False, # If true, enables Cloud CDN for the backend service. Only applicable if the loadBalancingScheme is EXTERNAL and the protocol is HTTP or HTTPS.
334 &quot;failoverPolicy&quot;: { # Applicable only to Failover for Internal TCP/UDP Load Balancing. On failover or failback, this field indicates whether connection draining will be honored. GCP has a fixed connection draining timeout of 10 minutes. A setting of true terminates existing TCP connections to the active pool during failover and failback, immediately draining traffic. A setting of false allows existing TCP connections to persist, even on VMs no longer in the active pool, for up to the duration of the connection draining timeout (10 minutes). # Applicable only to Failover for Internal TCP/UDP Load Balancing. Requires at least one backend instance group to be defined as a backup (failover) backend.
335 &quot;disableConnectionDrainOnFailover&quot;: True or False, # This can be set to true only if the protocol is TCP.
336 #
337 # The default is false.
338 &quot;dropTrafficIfUnhealthy&quot;: True or False, # Applicable only to Failover for Internal TCP/UDP Load Balancing. If set to true, connections to the load balancer are dropped when all primary and all backup backend VMs are unhealthy. If set to false, connections are distributed among all primary VMs when all primary and all backup backend VMs are unhealthy.
339 #
340 # The default is false.
341 &quot;failoverRatio&quot;: 3.14, # Applicable only to Failover for Internal TCP/UDP Load Balancing. The value of the field must be in the range [0, 1]. If the value is 0, the load balancer performs a failover when the number of healthy primary VMs equals zero. For all other values, the load balancer performs a failover when the total number of healthy primary VMs is less than this ratio.
342 },
343 &quot;fingerprint&quot;: &quot;A String&quot;, # Fingerprint of this resource. A hash of the contents stored in this object. This field is used in optimistic locking. This field will be ignored when inserting a BackendService. An up-to-date fingerprint must be provided in order to update the BackendService, otherwise the request will fail with error 412 conditionNotMet.
344 #
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700345 # To see the latest fingerprint, make a get() request to retrieve a BackendService.
Dmitry Frenkel3e17f892020-10-06 16:46:05 -0700346 &quot;healthChecks&quot;: [ # The list of URLs to the healthChecks, httpHealthChecks (legacy), or httpsHealthChecks (legacy) resource for health checking this backend service. Not all backend services support legacy health checks. See Load balancer guide. Currently, at most one health check can be specified for each backend service. Backend services with instance group or zonal NEG backends must have a health check. Backend services with internet or serverless NEG backends must not have a health check.
Bu Sun Kim65020912020-05-20 12:08:20 -0700347 &quot;A String&quot;,
348 ],
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700349 &quot;iap&quot;: { # Identity-Aware Proxy # The configurations for Identity-Aware Proxy on this resource.
350 &quot;enabled&quot;: True or False, # Whether the serving infrastructure will authenticate and authorize all incoming requests. If true, the oauth2ClientId and oauth2ClientSecret fields must be non-empty.
351 &quot;oauth2ClientId&quot;: &quot;A String&quot;, # OAuth2 client ID to use for the authentication flow.
352 &quot;oauth2ClientSecret&quot;: &quot;A String&quot;, # OAuth2 client secret to use for the authentication flow. For security reasons, this value cannot be retrieved via the API. Instead, the SHA-256 hash of the value is returned in the oauth2ClientSecretSha256 field.
Bu Sun Kim65020912020-05-20 12:08:20 -0700353 &quot;oauth2ClientSecretSha256&quot;: &quot;A String&quot;, # [Output Only] SHA256 hash value for the field oauth2_client_secret above.
Dan O'Mearadd494642020-05-01 07:42:23 -0700354 },
Bu Sun Kim65020912020-05-20 12:08:20 -0700355 &quot;id&quot;: &quot;A String&quot;, # [Output Only] The unique identifier for the resource. This identifier is defined by the server.
356 &quot;kind&quot;: &quot;compute#backendService&quot;, # [Output Only] Type of resource. Always compute#backendService for backend services.
357 &quot;loadBalancingScheme&quot;: &quot;A String&quot;, # Specifies the load balancer type. Choose EXTERNAL for load balancers that receive traffic from external clients. Choose INTERNAL for Internal TCP/UDP Load Balancing. Choose INTERNAL_MANAGED for Internal HTTP(S) Load Balancing. Choose INTERNAL_SELF_MANAGED for Traffic Director. A backend service created for one type of load balancing cannot be used with another. For more information, refer to Choosing a load balancer.
358 &quot;localityLbPolicy&quot;: &quot;A String&quot;, # The load balancing algorithm used within the scope of the locality. The possible values are:
359 # - ROUND_ROBIN: This is a simple policy in which each healthy backend is selected in round robin order. This is the default.
360 # - LEAST_REQUEST: An O(1) algorithm which selects two random healthy hosts and picks the host which has fewer active requests.
361 # - RING_HASH: The ring/modulo hash load balancer implements consistent hashing to backends. The algorithm has the property that the addition/removal of a host from a set of N hosts only affects 1/N of the requests.
362 # - RANDOM: The load balancer selects a random healthy host.
363 # - ORIGINAL_DESTINATION: Backend host is selected based on the client connection metadata, i.e., connections are opened to the same address as the destination address of the incoming connection before the connection was redirected to the load balancer.
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700364 # - MAGLEV: used as a drop in replacement for the ring hash load balancer. Maglev is not as stable as ring hash but has faster table lookup build times and host selection times. For more information about Maglev, see https://ai.google/research/pubs/pub44824
Bu Sun Kim65020912020-05-20 12:08:20 -0700365 #
366 # This field is applicable to either:
367 # - A regional backend service with the service_protocol set to HTTP, HTTPS, or HTTP2, and load_balancing_scheme set to INTERNAL_MANAGED.
368 # - A global backend service with the load_balancing_scheme set to INTERNAL_SELF_MANAGED.
369 #
Dmitry Frenkel3e17f892020-10-06 16:46:05 -0700370 # If sessionAffinity is not NONE, and this field is not set to MAGLEV or RING_HASH, session affinity settings will not take effect.
371 #
372 # Only the default ROUND_ROBIN policy is supported when the backend service is referenced by a URL map that is bound to target gRPC proxy that has validateForProxyless field set to true.
Bu Sun Kim65020912020-05-20 12:08:20 -0700373 &quot;logConfig&quot;: { # The available logging options for the load balancer traffic served by this backend service. # This field denotes the logging options for the load balancer traffic served by this backend service. If logging is enabled, logs will be exported to Stackdriver.
374 &quot;enable&quot;: True or False, # This field denotes whether to enable logging for the load balancer traffic served by this backend service.
375 &quot;sampleRate&quot;: 3.14, # This field can only be specified if logging is enabled for this backend service. The value of the field must be in [0, 1]. This configures the sampling rate of requests to the load balancer where 1.0 means all logged requests are reported and 0.0 means no logged requests are reported. The default value is 1.0.
Dan O'Mearadd494642020-05-01 07:42:23 -0700376 },
Bu Sun Kim65020912020-05-20 12:08:20 -0700377 &quot;name&quot;: &quot;A String&quot;, # Name of the resource. Provided by the client when the resource is created. The name must be 1-63 characters long, and comply with RFC1035. Specifically, the name must be 1-63 characters long and match the regular expression `[a-z]([-a-z0-9]*[a-z0-9])?` which means the first character must be a lowercase letter, and all following characters must be a dash, lowercase letter, or digit, except the last character, which cannot be a dash.
378 &quot;network&quot;: &quot;A String&quot;, # The URL of the network to which this backend service belongs. This field can only be spcified when the load balancing scheme is set to INTERNAL.
379 &quot;outlierDetection&quot;: { # Settings controlling the eviction of unhealthy hosts from the load balancing pool for the backend service. # Settings controlling the eviction of unhealthy hosts from the load balancing pool for the backend service. If not set, this feature is considered disabled.
380 #
381 # This field is applicable to either:
382 # - A regional backend service with the service_protocol set to HTTP, HTTPS, or HTTP2, and load_balancing_scheme set to INTERNAL_MANAGED.
383 # - A global backend service with the load_balancing_scheme set to INTERNAL_SELF_MANAGED.
Dmitry Frenkel3e17f892020-10-06 16:46:05 -0700384 #
385 # Not supported when the backend service is referenced by a URL map that is bound to target gRPC proxy that has validateForProxyless field set to true.
Bu Sun Kim65020912020-05-20 12:08:20 -0700386 &quot;baseEjectionTime&quot;: { # A Duration represents a fixed-length span of time represented as a count of seconds and fractions of seconds at nanosecond resolution. It is independent of any calendar and concepts like &quot;day&quot; or &quot;month&quot;. Range is approximately 10,000 years. # The base time that a host is ejected for. The real ejection time is equal to the base ejection time multiplied by the number of times the host has been ejected. Defaults to 30000ms or 30s.
387 &quot;nanos&quot;: 42, # Span of time that&#x27;s a fraction of a second at nanosecond resolution. Durations less than one second are represented with a 0 `seconds` field and a positive `nanos` field. Must be from 0 to 999,999,999 inclusive.
388 &quot;seconds&quot;: &quot;A String&quot;, # Span of time at a resolution of a second. Must be from 0 to 315,576,000,000 inclusive. Note: these bounds are computed from: 60 sec/min * 60 min/hr * 24 hr/day * 365.25 days/year * 10000 years
389 },
390 &quot;consecutiveErrors&quot;: 42, # Number of errors before a host is ejected from the connection pool. When the backend host is accessed over HTTP, a 5xx return code qualifies as an error. Defaults to 5.
391 &quot;consecutiveGatewayFailure&quot;: 42, # The number of consecutive gateway failures (502, 503, 504 status or connection errors that are mapped to one of those status codes) before a consecutive gateway failure ejection occurs. Defaults to 3.
392 &quot;enforcingConsecutiveErrors&quot;: 42, # The percentage chance that a host will be actually ejected when an outlier status is detected through consecutive 5xx. This setting can be used to disable ejection or to ramp it up slowly. Defaults to 0.
393 &quot;enforcingConsecutiveGatewayFailure&quot;: 42, # The percentage chance that a host will be actually ejected when an outlier status is detected through consecutive gateway failures. This setting can be used to disable ejection or to ramp it up slowly. Defaults to 100.
394 &quot;enforcingSuccessRate&quot;: 42, # The percentage chance that a host will be actually ejected when an outlier status is detected through success rate statistics. This setting can be used to disable ejection or to ramp it up slowly. Defaults to 100.
395 &quot;interval&quot;: { # A Duration represents a fixed-length span of time represented as a count of seconds and fractions of seconds at nanosecond resolution. It is independent of any calendar and concepts like &quot;day&quot; or &quot;month&quot;. Range is approximately 10,000 years. # Time interval between ejection analysis sweeps. This can result in both new ejections as well as hosts being returned to service. Defaults to 1 second.
396 &quot;nanos&quot;: 42, # Span of time that&#x27;s a fraction of a second at nanosecond resolution. Durations less than one second are represented with a 0 `seconds` field and a positive `nanos` field. Must be from 0 to 999,999,999 inclusive.
397 &quot;seconds&quot;: &quot;A String&quot;, # Span of time at a resolution of a second. Must be from 0 to 315,576,000,000 inclusive. Note: these bounds are computed from: 60 sec/min * 60 min/hr * 24 hr/day * 365.25 days/year * 10000 years
398 },
399 &quot;maxEjectionPercent&quot;: 42, # Maximum percentage of hosts in the load balancing pool for the backend service that can be ejected. Defaults to 50%.
400 &quot;successRateMinimumHosts&quot;: 42, # The number of hosts in a cluster that must have enough request volume to detect success rate outliers. If the number of hosts is less than this setting, outlier detection via success rate statistics is not performed for any host in the cluster. Defaults to 5.
401 &quot;successRateRequestVolume&quot;: 42, # The minimum number of total requests that must be collected in one interval (as defined by the interval duration above) to include this host in success rate based outlier detection. If the volume is lower than this setting, outlier detection via success rate statistics is not performed for that host. Defaults to 100.
402 &quot;successRateStdevFactor&quot;: 42, # This factor is used to determine the ejection threshold for success rate outlier ejection. The ejection threshold is the difference between the mean success rate, and the product of this factor and the standard deviation of the mean success rate: mean - (stdev * success_rate_stdev_factor). This factor is divided by a thousand to get a double. That is, if the desired factor is 1.9, the runtime value should be 1900. Defaults to 1900.
403 },
404 &quot;port&quot;: 42, # Deprecated in favor of portName. The TCP port to connect on the backend. The default value is 80.
405 #
406 # This cannot be used if the loadBalancingScheme is INTERNAL (Internal TCP/UDP Load Balancing).
407 &quot;portName&quot;: &quot;A String&quot;, # A named port on a backend instance group representing the port for communication to the backend VMs in that group. Required when the loadBalancingScheme is EXTERNAL, INTERNAL_MANAGED, or INTERNAL_SELF_MANAGED and the backends are instance groups. The named port must be defined on each backend instance group. This parameter has no meaning if the backends are NEGs.
408 #
409 #
410 #
411 # Must be omitted when the loadBalancingScheme is INTERNAL (Internal TCP/UDP Load Balancing).
412 &quot;protocol&quot;: &quot;A String&quot;, # The protocol this BackendService uses to communicate with backends.
413 #
Dmitry Frenkel3e17f892020-10-06 16:46:05 -0700414 # Possible values are HTTP, HTTPS, HTTP2, TCP, SSL, UDP or GRPC. depending on the chosen load balancer or Traffic Director configuration. Refer to the documentation for the load balancer or for Traffic Director for more information.
415 #
416 # Must be set to GRPC when the backend service is referenced by a URL map that is bound to target gRPC proxy.
Bu Sun Kim65020912020-05-20 12:08:20 -0700417 &quot;region&quot;: &quot;A String&quot;, # [Output Only] URL of the region where the regional backend service resides. This field is not applicable to global backend services. You must specify this field as part of the HTTP request URL. It is not settable as a field in the request body.
418 &quot;securityPolicy&quot;: &quot;A String&quot;, # [Output Only] The resource URL for the security policy associated with this backend service.
Bu Sun Kim673ec5c2020-11-16 11:05:03 -0700419 &quot;securitySettings&quot;: { # The authentication and authorization settings for a BackendService. # This field specifies the security policy that applies to this backend service. This field is applicable to either:
420 # - A regional backend service with the service_protocol set to HTTP, HTTPS, or HTTP2, and load_balancing_scheme set to INTERNAL_MANAGED.
421 # - A global backend service with the load_balancing_scheme set to INTERNAL_SELF_MANAGED.
422 &quot;clientTlsPolicy&quot;: &quot;A String&quot;, # Optional. A URL referring to a networksecurity.ClientTlsPolicy resource that describes how clients should authenticate with this service&#x27;s backends.
423 # clientTlsPolicy only applies to a global BackendService with the loadBalancingScheme set to INTERNAL_SELF_MANAGED.
424 # If left blank, communications are not encrypted.
425 # Note: This field currently has no impact.
426 &quot;subjectAltNames&quot;: [ # Optional. A list of Subject Alternative Names (SANs) that the client verifies during a mutual TLS handshake with an server/endpoint for this BackendService. When the server presents its X.509 certificate to the client, the client inspects the certificate&#x27;s subjectAltName field. If the field contains one of the specified values, the communication continues. Otherwise, it fails. This additional check enables the client to verify that the server is authorized to run the requested service.
427 # Note that the contents of the server certificate&#x27;s subjectAltName field are configured by the Public Key Infrastructure which provisions server identities.
428 # Only applies to a global BackendService with loadBalancingScheme set to INTERNAL_SELF_MANAGED. Only applies when BackendService has an attached clientTlsPolicy with clientCertificate (mTLS mode).
429 # Note: This field currently has no impact.
430 &quot;A String&quot;,
431 ],
432 },
Bu Sun Kim65020912020-05-20 12:08:20 -0700433 &quot;selfLink&quot;: &quot;A String&quot;, # [Output Only] Server-defined URL for the resource.
434 &quot;sessionAffinity&quot;: &quot;A String&quot;, # Type of session affinity to use. The default is NONE. Session affinity is not applicable if the --protocol is UDP.
435 #
436 # When the loadBalancingScheme is EXTERNAL, possible values are NONE, CLIENT_IP, or GENERATED_COOKIE. You can use GENERATED_COOKIE if the protocol is HTTP or HTTPS.
437 #
438 # When the loadBalancingScheme is INTERNAL, possible values are NONE, CLIENT_IP, CLIENT_IP_PROTO, or CLIENT_IP_PORT_PROTO.
439 #
440 # When the loadBalancingScheme is INTERNAL_SELF_MANAGED, or INTERNAL_MANAGED, possible values are NONE, CLIENT_IP, GENERATED_COOKIE, HEADER_FIELD, or HTTP_COOKIE.
Dmitry Frenkel3e17f892020-10-06 16:46:05 -0700441 #
442 # Not supported when the backend service is referenced by a URL map that is bound to target gRPC proxy that has validateForProxyless field set to true.
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700443 &quot;timeoutSec&quot;: 42, # The backend service timeout has a different meaning depending on the type of load balancer. For more information see, Backend service settings The default is 30 seconds.
Bu Sun Kim65020912020-05-20 12:08:20 -0700444 }</pre>
445</div>
446
447<div class="method">
448 <code class="details" id="getHealth">getHealth(project, region, backendService, body=None)</code>
449 <pre>Gets the most recent health check results for this regional BackendService.
450
451Args:
452 project: string, A parameter (required)
453 region: string, Name of the region scoping this request. (required)
454 backendService: string, Name of the BackendService resource for which to get health. (required)
455 body: object, The request body.
456 The object takes the form of:
457
458{
459 &quot;group&quot;: &quot;A String&quot;, # A URI referencing one of the instance groups or network endpoint groups listed in the backend service.
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800460 }
461
Bu Sun Kim65020912020-05-20 12:08:20 -0700462
463Returns:
464 An object of the form:
465
466 {
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700467 &quot;annotations&quot;: { # Metadata defined as annotations on the network endpoint group.
468 &quot;a_key&quot;: &quot;A String&quot;,
469 },
Bu Sun Kim65020912020-05-20 12:08:20 -0700470 &quot;healthStatus&quot;: [ # Health state of the backend instances or endpoints in requested instance or network endpoint group, determined based on configured health checks.
471 {
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700472 &quot;annotations&quot;: { # Metadata defined as annotations for network endpoint.
473 &quot;a_key&quot;: &quot;A String&quot;,
474 },
Bu Sun Kim65020912020-05-20 12:08:20 -0700475 &quot;healthState&quot;: &quot;A String&quot;, # Health state of the instance.
476 &quot;instance&quot;: &quot;A String&quot;, # URL of the instance resource.
477 &quot;ipAddress&quot;: &quot;A String&quot;, # A forwarding rule IP address assigned to this instance.
478 &quot;port&quot;: 42, # The named port of the instance group, not necessarily the port that is health-checked.
479 },
480 ],
481 &quot;kind&quot;: &quot;compute#backendServiceGroupHealth&quot;, # [Output Only] Type of resource. Always compute#backendServiceGroupHealth for the health of backend services.
482 }</pre>
483</div>
484
485<div class="method">
486 <code class="details" id="insert">insert(project, region, body=None, requestId=None)</code>
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700487 <pre>Creates a regional BackendService resource in the specified project using the data included in the request. For more information, see Backend services overview.
Bu Sun Kim65020912020-05-20 12:08:20 -0700488
489Args:
490 project: string, Project ID for this request. (required)
491 region: string, Name of the region scoping this request. (required)
492 body: object, The request body.
493 The object takes the form of:
494
495{ # Represents a Backend Service resource.
496 #
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700497 # A backend service defines how Google Cloud load balancers distribute traffic. The backend service configuration contains a set of values, such as the protocol used to connect to backends, various distribution and session settings, health checks, and timeouts. These settings provide fine-grained control over how your load balancer behaves. Most of the settings have default values that allow for easy configuration if you need to get started quickly.
Bu Sun Kim65020912020-05-20 12:08:20 -0700498 #
499 # Backend services in Google Compute Engine can be either regionally or globally scoped.
500 #
501 # * [Global](/compute/docs/reference/rest/{$api_version}/backendServices) * [Regional](/compute/docs/reference/rest/{$api_version}/regionBackendServices)
502 #
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700503 # For more information, see Backend Services.
Bu Sun Kim65020912020-05-20 12:08:20 -0700504 #
505 # (== resource_for {$api_version}.backendService ==)
Dmitry Frenkel3e17f892020-10-06 16:46:05 -0700506 &quot;affinityCookieTtlSec&quot;: 42, # Lifetime of cookies in seconds. Only applicable if the loadBalancingScheme is EXTERNAL, INTERNAL_SELF_MANAGED, or INTERNAL_MANAGED, the protocol is HTTP or HTTPS, and the sessionAffinity is GENERATED_COOKIE, or HTTP_COOKIE.
507 #
508 # If set to 0, the cookie is non-persistent and lasts only until the end of the browser session (or equivalent). The maximum allowed value is one day (86,400).
509 #
510 # Not supported when the backend service is referenced by a URL map that is bound to target gRPC proxy that has validateForProxyless field set to true.
Bu Sun Kim65020912020-05-20 12:08:20 -0700511 &quot;backends&quot;: [ # The list of backends that serve this BackendService.
512 { # Message containing information of one individual backend.
513 &quot;balancingMode&quot;: &quot;A String&quot;, # Specifies the balancing mode for the backend.
514 #
515 # When choosing a balancing mode, you need to consider the loadBalancingScheme, and protocol for the backend service, as well as the type of backend (instance group or NEG).
516 #
517 #
518 # - If the load balancing mode is CONNECTION, then the load is spread based on how many concurrent connections the backend can handle.
519 # You can use the CONNECTION balancing mode if the protocol for the backend service is SSL, TCP, or UDP.
520 #
521 # If the loadBalancingScheme for the backend service is EXTERNAL (SSL Proxy and TCP Proxy load balancers), you must also specify exactly one of the following parameters: maxConnections (except for regional managed instance groups), maxConnectionsPerInstance, or maxConnectionsPerEndpoint.
522 #
523 # If the loadBalancingScheme for the backend service is INTERNAL (internal TCP/UDP load balancers), you cannot specify any additional parameters.
524 #
525 # - If the load balancing mode is RATE, the load is spread based on the rate of HTTP requests per second (RPS).
526 # You can use the RATE balancing mode if the protocol for the backend service is HTTP or HTTPS. You must specify exactly one of the following parameters: maxRate (except for regional managed instance groups), maxRatePerInstance, or maxRatePerEndpoint.
527 #
528 # - If the load balancing mode is UTILIZATION, the load is spread based on the backend utilization of instances in an instance group.
529 # You can use the UTILIZATION balancing mode if the loadBalancingScheme of the backend service is EXTERNAL, INTERNAL_SELF_MANAGED, or INTERNAL_MANAGED and the backends are instance groups. There are no restrictions on the backend service protocol.
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700530 &quot;capacityScaler&quot;: 3.14, # A multiplier applied to the group&#x27;s maximum servicing capacity (based on UTILIZATION, RATE or CONNECTION). Default value is 1, which means the group will serve up to 100% of its configured capacity (depending on balancingMode). A setting of 0 means the group is completely drained, offering 0% of its available capacity. Valid range is 0.0 and [0.1,1.0]. You cannot configure a setting larger than 0 and smaller than 0.1. You cannot configure a setting of 0 when there is only one backend attached to the backend service.
Bu Sun Kim65020912020-05-20 12:08:20 -0700531 #
532 # This cannot be used for internal load balancing.
533 &quot;description&quot;: &quot;A String&quot;, # An optional description of this resource. Provide this property when you create the resource.
534 &quot;failover&quot;: True or False, # This field designates whether this is a failover backend. More than one failover backend can be configured for a given BackendService.
535 &quot;group&quot;: &quot;A String&quot;, # The fully-qualified URL of an instance group or network endpoint group (NEG) resource. The type of backend that a backend service supports depends on the backend service&#x27;s loadBalancingScheme.
536 #
537 #
538 # - When the loadBalancingScheme for the backend service is EXTERNAL, INTERNAL_SELF_MANAGED, or INTERNAL_MANAGED, the backend can be either an instance group or a NEG. The backends on the backend service must be either all instance groups or all NEGs. You cannot mix instance group and NEG backends on the same backend service.
539 #
540 #
541 # - When the loadBalancingScheme for the backend service is INTERNAL, the backend must be an instance group in the same region as the backend service. NEGs are not supported.
542 #
543 # You must use the fully-qualified URL (starting with https://www.googleapis.com/) to specify the instance group or NEG. Partial URLs are not supported.
544 &quot;maxConnections&quot;: 42, # Defines a target maximum number of simultaneous connections that the backend can handle. Valid for network endpoint group and instance group backends (except for regional managed instance groups). If the backend&#x27;s balancingMode is UTILIZATION, this is an optional parameter. If the backend&#x27;s balancingMode is CONNECTION, and backend is attached to a backend service whose loadBalancingScheme is EXTERNAL, you must specify either this parameter, maxConnectionsPerInstance, or maxConnectionsPerEndpoint.
545 #
546 # Not available if the backend&#x27;s balancingMode is RATE. If the loadBalancingScheme is INTERNAL, then maxConnections is not supported, even though the backend requires a balancing mode of CONNECTION.
547 &quot;maxConnectionsPerEndpoint&quot;: 42, # Defines a target maximum number of simultaneous connections for an endpoint of a NEG. This is multiplied by the number of endpoints in the NEG to implicitly calculate a maximum number of target maximum simultaneous connections for the NEG. If the backend&#x27;s balancingMode is CONNECTION, and the backend is attached to a backend service whose loadBalancingScheme is EXTERNAL, you must specify either this parameter, maxConnections, or maxConnectionsPerInstance.
548 #
549 # Not available if the backend&#x27;s balancingMode is RATE. Internal TCP/UDP load balancing does not support setting maxConnectionsPerEndpoint even though its backends require a balancing mode of CONNECTION.
550 &quot;maxConnectionsPerInstance&quot;: 42, # Defines a target maximum number of simultaneous connections for a single VM in a backend instance group. This is multiplied by the number of instances in the instance group to implicitly calculate a target maximum number of simultaneous connections for the whole instance group. If the backend&#x27;s balancingMode is UTILIZATION, this is an optional parameter. If the backend&#x27;s balancingMode is CONNECTION, and backend is attached to a backend service whose loadBalancingScheme is EXTERNAL, you must specify either this parameter, maxConnections, or maxConnectionsPerEndpoint.
551 #
552 # Not available if the backend&#x27;s balancingMode is RATE. Internal TCP/UDP load balancing does not support setting maxConnectionsPerInstance even though its backends require a balancing mode of CONNECTION.
553 &quot;maxRate&quot;: 42, # Defines a maximum number of HTTP requests per second (RPS) that the backend can handle. Valid for network endpoint group and instance group backends (except for regional managed instance groups). Must not be defined if the backend is a managed instance group that uses autoscaling based on load balancing.
554 #
555 # If the backend&#x27;s balancingMode is UTILIZATION, this is an optional parameter. If the backend&#x27;s balancingMode is RATE, you must specify maxRate, maxRatePerInstance, or maxRatePerEndpoint.
556 #
557 # Not available if the backend&#x27;s balancingMode is CONNECTION.
558 &quot;maxRatePerEndpoint&quot;: 3.14, # Defines a maximum target for requests per second (RPS) for an endpoint of a NEG. This is multiplied by the number of endpoints in the NEG to implicitly calculate a target maximum rate for the NEG.
559 #
560 # If the backend&#x27;s balancingMode is RATE, you must specify either this parameter, maxRate (except for regional managed instance groups), or maxRatePerInstance.
561 #
562 # Not available if the backend&#x27;s balancingMode is CONNECTION.
563 &quot;maxRatePerInstance&quot;: 3.14, # Defines a maximum target for requests per second (RPS) for a single VM in a backend instance group. This is multiplied by the number of instances in the instance group to implicitly calculate a target maximum rate for the whole instance group.
564 #
565 # If the backend&#x27;s balancingMode is UTILIZATION, this is an optional parameter. If the backend&#x27;s balancingMode is RATE, you must specify either this parameter, maxRate (except for regional managed instance groups), or maxRatePerEndpoint.
566 #
567 # Not available if the backend&#x27;s balancingMode is CONNECTION.
568 &quot;maxUtilization&quot;: 3.14, # Defines the maximum average backend utilization of a backend VM in an instance group. The valid range is [0.0, 1.0]. This is an optional parameter if the backend&#x27;s balancingMode is UTILIZATION.
569 #
570 # This parameter can be used in conjunction with maxRate, maxRatePerInstance, maxConnections (except for regional managed instance groups), or maxConnectionsPerInstance.
571 },
572 ],
573 &quot;cdnPolicy&quot;: { # Message containing Cloud CDN configuration for a backend service. # Cloud CDN configuration for this BackendService.
574 &quot;cacheKeyPolicy&quot;: { # Message containing what to include in the cache key for a request for Cloud CDN. # The CacheKeyPolicy for this CdnPolicy.
575 &quot;includeHost&quot;: True or False, # If true, requests to different hosts will be cached separately.
576 &quot;includeProtocol&quot;: True or False, # If true, http and https requests will be cached separately.
577 &quot;includeQueryString&quot;: True or False, # If true, include query string parameters in the cache key according to query_string_whitelist and query_string_blacklist. If neither is set, the entire query string will be included. If false, the query string will be excluded from the cache key entirely.
578 &quot;queryStringBlacklist&quot;: [ # Names of query string parameters to exclude in cache keys. All other parameters will be included. Either specify query_string_whitelist or query_string_blacklist, not both. &#x27;&amp;&#x27; and &#x27;=&#x27; will be percent encoded and not treated as delimiters.
579 &quot;A String&quot;,
580 ],
581 &quot;queryStringWhitelist&quot;: [ # Names of query string parameters to include in cache keys. All other parameters will be excluded. Either specify query_string_whitelist or query_string_blacklist, not both. &#x27;&amp;&#x27; and &#x27;=&#x27; will be percent encoded and not treated as delimiters.
582 &quot;A String&quot;,
583 ],
584 },
585 &quot;signedUrlCacheMaxAgeSec&quot;: &quot;A String&quot;, # Maximum number of seconds the response to a signed URL request will be considered fresh. After this time period, the response will be revalidated before being served. Defaults to 1hr (3600s). When serving responses to signed URL requests, Cloud CDN will internally behave as though all responses from this backend had a &quot;Cache-Control: public, max-age=[TTL]&quot; header, regardless of any existing Cache-Control header. The actual headers served in responses will not be altered.
586 &quot;signedUrlKeyNames&quot;: [ # [Output Only] Names of the keys for signing request URLs.
587 &quot;A String&quot;,
588 ],
589 },
590 &quot;circuitBreakers&quot;: { # Settings controlling the volume of connections to a backend service. # Settings controlling the volume of connections to a backend service. If not set, this feature is considered disabled.
591 #
592 # This field is applicable to either:
593 # - A regional backend service with the service_protocol set to HTTP, HTTPS, or HTTP2, and load_balancing_scheme set to INTERNAL_MANAGED.
594 # - A global backend service with the load_balancing_scheme set to INTERNAL_SELF_MANAGED.
Dmitry Frenkel3e17f892020-10-06 16:46:05 -0700595 #
596 # Not supported when the backend service is referenced by a URL map that is bound to target gRPC proxy that has validateForProxyless field set to true.
Bu Sun Kim65020912020-05-20 12:08:20 -0700597 &quot;maxConnections&quot;: 42, # The maximum number of connections to the backend service. If not specified, there is no limit.
598 &quot;maxPendingRequests&quot;: 42, # The maximum number of pending requests allowed to the backend service. If not specified, there is no limit.
599 &quot;maxRequests&quot;: 42, # The maximum number of parallel requests that allowed to the backend service. If not specified, there is no limit.
600 &quot;maxRequestsPerConnection&quot;: 42, # Maximum requests for a single connection to the backend service. This parameter is respected by both the HTTP/1.1 and HTTP/2 implementations. If not specified, there is no limit. Setting this parameter to 1 will effectively disable keep alive.
601 &quot;maxRetries&quot;: 42, # The maximum number of parallel retries allowed to the backend cluster. If not specified, the default is 1.
602 },
603 &quot;connectionDraining&quot;: { # Message containing connection draining configuration.
604 &quot;drainingTimeoutSec&quot;: 42, # The amount of time in seconds to allow existing connections to persist while on unhealthy backend VMs. Only applicable if the protocol is not UDP. The valid range is [0, 3600].
605 },
606 &quot;consistentHash&quot;: { # This message defines settings for a consistent hash style load balancer. # Consistent Hash-based load balancing can be used to provide soft session affinity based on HTTP headers, cookies or other properties. This load balancing policy is applicable only for HTTP connections. The affinity to a particular destination host will be lost when one or more hosts are added/removed from the destination service. This field specifies parameters that control consistent hashing. This field is only applicable when localityLbPolicy is set to MAGLEV or RING_HASH.
607 #
608 # This field is applicable to either:
609 # - A regional backend service with the service_protocol set to HTTP, HTTPS, or HTTP2, and load_balancing_scheme set to INTERNAL_MANAGED.
610 # - A global backend service with the load_balancing_scheme set to INTERNAL_SELF_MANAGED.
Dmitry Frenkel3e17f892020-10-06 16:46:05 -0700611 #
612 # Not supported when the backend service is referenced by a URL map that is bound to target gRPC proxy that has validateForProxyless field set to true.
Bu Sun Kim65020912020-05-20 12:08:20 -0700613 &quot;httpCookie&quot;: { # The information about the HTTP Cookie on which the hash function is based for load balancing policies that use a consistent hash. # Hash is based on HTTP Cookie. This field describes a HTTP cookie that will be used as the hash key for the consistent hash load balancer. If the cookie is not present, it will be generated. This field is applicable if the sessionAffinity is set to HTTP_COOKIE.
614 &quot;name&quot;: &quot;A String&quot;, # Name of the cookie.
615 &quot;path&quot;: &quot;A String&quot;, # Path to set for the cookie.
616 &quot;ttl&quot;: { # A Duration represents a fixed-length span of time represented as a count of seconds and fractions of seconds at nanosecond resolution. It is independent of any calendar and concepts like &quot;day&quot; or &quot;month&quot;. Range is approximately 10,000 years. # Lifetime of the cookie.
617 &quot;nanos&quot;: 42, # Span of time that&#x27;s a fraction of a second at nanosecond resolution. Durations less than one second are represented with a 0 `seconds` field and a positive `nanos` field. Must be from 0 to 999,999,999 inclusive.
618 &quot;seconds&quot;: &quot;A String&quot;, # Span of time at a resolution of a second. Must be from 0 to 315,576,000,000 inclusive. Note: these bounds are computed from: 60 sec/min * 60 min/hr * 24 hr/day * 365.25 days/year * 10000 years
619 },
620 },
621 &quot;httpHeaderName&quot;: &quot;A String&quot;, # The hash based on the value of the specified header field. This field is applicable if the sessionAffinity is set to HEADER_FIELD.
622 &quot;minimumRingSize&quot;: &quot;A String&quot;, # The minimum number of virtual nodes to use for the hash ring. Defaults to 1024. Larger ring sizes result in more granular load distributions. If the number of hosts in the load balancing pool is larger than the ring size, each host will be assigned a single virtual node.
623 },
624 &quot;creationTimestamp&quot;: &quot;A String&quot;, # [Output Only] Creation timestamp in RFC3339 text format.
625 &quot;customRequestHeaders&quot;: [ # Headers that the HTTP/S load balancer should add to proxied requests.
626 &quot;A String&quot;,
627 ],
628 &quot;description&quot;: &quot;A String&quot;, # An optional description of this resource. Provide this property when you create the resource.
629 &quot;enableCDN&quot;: True or False, # If true, enables Cloud CDN for the backend service. Only applicable if the loadBalancingScheme is EXTERNAL and the protocol is HTTP or HTTPS.
630 &quot;failoverPolicy&quot;: { # Applicable only to Failover for Internal TCP/UDP Load Balancing. On failover or failback, this field indicates whether connection draining will be honored. GCP has a fixed connection draining timeout of 10 minutes. A setting of true terminates existing TCP connections to the active pool during failover and failback, immediately draining traffic. A setting of false allows existing TCP connections to persist, even on VMs no longer in the active pool, for up to the duration of the connection draining timeout (10 minutes). # Applicable only to Failover for Internal TCP/UDP Load Balancing. Requires at least one backend instance group to be defined as a backup (failover) backend.
631 &quot;disableConnectionDrainOnFailover&quot;: True or False, # This can be set to true only if the protocol is TCP.
632 #
633 # The default is false.
634 &quot;dropTrafficIfUnhealthy&quot;: True or False, # Applicable only to Failover for Internal TCP/UDP Load Balancing. If set to true, connections to the load balancer are dropped when all primary and all backup backend VMs are unhealthy. If set to false, connections are distributed among all primary VMs when all primary and all backup backend VMs are unhealthy.
635 #
636 # The default is false.
637 &quot;failoverRatio&quot;: 3.14, # Applicable only to Failover for Internal TCP/UDP Load Balancing. The value of the field must be in the range [0, 1]. If the value is 0, the load balancer performs a failover when the number of healthy primary VMs equals zero. For all other values, the load balancer performs a failover when the total number of healthy primary VMs is less than this ratio.
638 },
639 &quot;fingerprint&quot;: &quot;A String&quot;, # Fingerprint of this resource. A hash of the contents stored in this object. This field is used in optimistic locking. This field will be ignored when inserting a BackendService. An up-to-date fingerprint must be provided in order to update the BackendService, otherwise the request will fail with error 412 conditionNotMet.
640 #
641 # To see the latest fingerprint, make a get() request to retrieve a BackendService.
Dmitry Frenkel3e17f892020-10-06 16:46:05 -0700642 &quot;healthChecks&quot;: [ # The list of URLs to the healthChecks, httpHealthChecks (legacy), or httpsHealthChecks (legacy) resource for health checking this backend service. Not all backend services support legacy health checks. See Load balancer guide. Currently, at most one health check can be specified for each backend service. Backend services with instance group or zonal NEG backends must have a health check. Backend services with internet or serverless NEG backends must not have a health check.
Bu Sun Kim65020912020-05-20 12:08:20 -0700643 &quot;A String&quot;,
644 ],
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700645 &quot;iap&quot;: { # Identity-Aware Proxy # The configurations for Identity-Aware Proxy on this resource.
646 &quot;enabled&quot;: True or False, # Whether the serving infrastructure will authenticate and authorize all incoming requests. If true, the oauth2ClientId and oauth2ClientSecret fields must be non-empty.
647 &quot;oauth2ClientId&quot;: &quot;A String&quot;, # OAuth2 client ID to use for the authentication flow.
648 &quot;oauth2ClientSecret&quot;: &quot;A String&quot;, # OAuth2 client secret to use for the authentication flow. For security reasons, this value cannot be retrieved via the API. Instead, the SHA-256 hash of the value is returned in the oauth2ClientSecretSha256 field.
Bu Sun Kim65020912020-05-20 12:08:20 -0700649 &quot;oauth2ClientSecretSha256&quot;: &quot;A String&quot;, # [Output Only] SHA256 hash value for the field oauth2_client_secret above.
650 },
651 &quot;id&quot;: &quot;A String&quot;, # [Output Only] The unique identifier for the resource. This identifier is defined by the server.
652 &quot;kind&quot;: &quot;compute#backendService&quot;, # [Output Only] Type of resource. Always compute#backendService for backend services.
653 &quot;loadBalancingScheme&quot;: &quot;A String&quot;, # Specifies the load balancer type. Choose EXTERNAL for load balancers that receive traffic from external clients. Choose INTERNAL for Internal TCP/UDP Load Balancing. Choose INTERNAL_MANAGED for Internal HTTP(S) Load Balancing. Choose INTERNAL_SELF_MANAGED for Traffic Director. A backend service created for one type of load balancing cannot be used with another. For more information, refer to Choosing a load balancer.
654 &quot;localityLbPolicy&quot;: &quot;A String&quot;, # The load balancing algorithm used within the scope of the locality. The possible values are:
655 # - ROUND_ROBIN: This is a simple policy in which each healthy backend is selected in round robin order. This is the default.
656 # - LEAST_REQUEST: An O(1) algorithm which selects two random healthy hosts and picks the host which has fewer active requests.
657 # - RING_HASH: The ring/modulo hash load balancer implements consistent hashing to backends. The algorithm has the property that the addition/removal of a host from a set of N hosts only affects 1/N of the requests.
658 # - RANDOM: The load balancer selects a random healthy host.
659 # - ORIGINAL_DESTINATION: Backend host is selected based on the client connection metadata, i.e., connections are opened to the same address as the destination address of the incoming connection before the connection was redirected to the load balancer.
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700660 # - MAGLEV: used as a drop in replacement for the ring hash load balancer. Maglev is not as stable as ring hash but has faster table lookup build times and host selection times. For more information about Maglev, see https://ai.google/research/pubs/pub44824
Bu Sun Kim65020912020-05-20 12:08:20 -0700661 #
662 # This field is applicable to either:
663 # - A regional backend service with the service_protocol set to HTTP, HTTPS, or HTTP2, and load_balancing_scheme set to INTERNAL_MANAGED.
664 # - A global backend service with the load_balancing_scheme set to INTERNAL_SELF_MANAGED.
665 #
Dmitry Frenkel3e17f892020-10-06 16:46:05 -0700666 # If sessionAffinity is not NONE, and this field is not set to MAGLEV or RING_HASH, session affinity settings will not take effect.
667 #
668 # Only the default ROUND_ROBIN policy is supported when the backend service is referenced by a URL map that is bound to target gRPC proxy that has validateForProxyless field set to true.
Bu Sun Kim65020912020-05-20 12:08:20 -0700669 &quot;logConfig&quot;: { # The available logging options for the load balancer traffic served by this backend service. # This field denotes the logging options for the load balancer traffic served by this backend service. If logging is enabled, logs will be exported to Stackdriver.
670 &quot;enable&quot;: True or False, # This field denotes whether to enable logging for the load balancer traffic served by this backend service.
671 &quot;sampleRate&quot;: 3.14, # This field can only be specified if logging is enabled for this backend service. The value of the field must be in [0, 1]. This configures the sampling rate of requests to the load balancer where 1.0 means all logged requests are reported and 0.0 means no logged requests are reported. The default value is 1.0.
672 },
673 &quot;name&quot;: &quot;A String&quot;, # Name of the resource. Provided by the client when the resource is created. The name must be 1-63 characters long, and comply with RFC1035. Specifically, the name must be 1-63 characters long and match the regular expression `[a-z]([-a-z0-9]*[a-z0-9])?` which means the first character must be a lowercase letter, and all following characters must be a dash, lowercase letter, or digit, except the last character, which cannot be a dash.
674 &quot;network&quot;: &quot;A String&quot;, # The URL of the network to which this backend service belongs. This field can only be spcified when the load balancing scheme is set to INTERNAL.
675 &quot;outlierDetection&quot;: { # Settings controlling the eviction of unhealthy hosts from the load balancing pool for the backend service. # Settings controlling the eviction of unhealthy hosts from the load balancing pool for the backend service. If not set, this feature is considered disabled.
676 #
677 # This field is applicable to either:
678 # - A regional backend service with the service_protocol set to HTTP, HTTPS, or HTTP2, and load_balancing_scheme set to INTERNAL_MANAGED.
679 # - A global backend service with the load_balancing_scheme set to INTERNAL_SELF_MANAGED.
Dmitry Frenkel3e17f892020-10-06 16:46:05 -0700680 #
681 # Not supported when the backend service is referenced by a URL map that is bound to target gRPC proxy that has validateForProxyless field set to true.
Bu Sun Kim65020912020-05-20 12:08:20 -0700682 &quot;baseEjectionTime&quot;: { # A Duration represents a fixed-length span of time represented as a count of seconds and fractions of seconds at nanosecond resolution. It is independent of any calendar and concepts like &quot;day&quot; or &quot;month&quot;. Range is approximately 10,000 years. # The base time that a host is ejected for. The real ejection time is equal to the base ejection time multiplied by the number of times the host has been ejected. Defaults to 30000ms or 30s.
683 &quot;nanos&quot;: 42, # Span of time that&#x27;s a fraction of a second at nanosecond resolution. Durations less than one second are represented with a 0 `seconds` field and a positive `nanos` field. Must be from 0 to 999,999,999 inclusive.
684 &quot;seconds&quot;: &quot;A String&quot;, # Span of time at a resolution of a second. Must be from 0 to 315,576,000,000 inclusive. Note: these bounds are computed from: 60 sec/min * 60 min/hr * 24 hr/day * 365.25 days/year * 10000 years
685 },
686 &quot;consecutiveErrors&quot;: 42, # Number of errors before a host is ejected from the connection pool. When the backend host is accessed over HTTP, a 5xx return code qualifies as an error. Defaults to 5.
687 &quot;consecutiveGatewayFailure&quot;: 42, # The number of consecutive gateway failures (502, 503, 504 status or connection errors that are mapped to one of those status codes) before a consecutive gateway failure ejection occurs. Defaults to 3.
688 &quot;enforcingConsecutiveErrors&quot;: 42, # The percentage chance that a host will be actually ejected when an outlier status is detected through consecutive 5xx. This setting can be used to disable ejection or to ramp it up slowly. Defaults to 0.
689 &quot;enforcingConsecutiveGatewayFailure&quot;: 42, # The percentage chance that a host will be actually ejected when an outlier status is detected through consecutive gateway failures. This setting can be used to disable ejection or to ramp it up slowly. Defaults to 100.
690 &quot;enforcingSuccessRate&quot;: 42, # The percentage chance that a host will be actually ejected when an outlier status is detected through success rate statistics. This setting can be used to disable ejection or to ramp it up slowly. Defaults to 100.
691 &quot;interval&quot;: { # A Duration represents a fixed-length span of time represented as a count of seconds and fractions of seconds at nanosecond resolution. It is independent of any calendar and concepts like &quot;day&quot; or &quot;month&quot;. Range is approximately 10,000 years. # Time interval between ejection analysis sweeps. This can result in both new ejections as well as hosts being returned to service. Defaults to 1 second.
692 &quot;nanos&quot;: 42, # Span of time that&#x27;s a fraction of a second at nanosecond resolution. Durations less than one second are represented with a 0 `seconds` field and a positive `nanos` field. Must be from 0 to 999,999,999 inclusive.
693 &quot;seconds&quot;: &quot;A String&quot;, # Span of time at a resolution of a second. Must be from 0 to 315,576,000,000 inclusive. Note: these bounds are computed from: 60 sec/min * 60 min/hr * 24 hr/day * 365.25 days/year * 10000 years
694 },
695 &quot;maxEjectionPercent&quot;: 42, # Maximum percentage of hosts in the load balancing pool for the backend service that can be ejected. Defaults to 50%.
696 &quot;successRateMinimumHosts&quot;: 42, # The number of hosts in a cluster that must have enough request volume to detect success rate outliers. If the number of hosts is less than this setting, outlier detection via success rate statistics is not performed for any host in the cluster. Defaults to 5.
697 &quot;successRateRequestVolume&quot;: 42, # The minimum number of total requests that must be collected in one interval (as defined by the interval duration above) to include this host in success rate based outlier detection. If the volume is lower than this setting, outlier detection via success rate statistics is not performed for that host. Defaults to 100.
698 &quot;successRateStdevFactor&quot;: 42, # This factor is used to determine the ejection threshold for success rate outlier ejection. The ejection threshold is the difference between the mean success rate, and the product of this factor and the standard deviation of the mean success rate: mean - (stdev * success_rate_stdev_factor). This factor is divided by a thousand to get a double. That is, if the desired factor is 1.9, the runtime value should be 1900. Defaults to 1900.
699 },
700 &quot;port&quot;: 42, # Deprecated in favor of portName. The TCP port to connect on the backend. The default value is 80.
701 #
702 # This cannot be used if the loadBalancingScheme is INTERNAL (Internal TCP/UDP Load Balancing).
703 &quot;portName&quot;: &quot;A String&quot;, # A named port on a backend instance group representing the port for communication to the backend VMs in that group. Required when the loadBalancingScheme is EXTERNAL, INTERNAL_MANAGED, or INTERNAL_SELF_MANAGED and the backends are instance groups. The named port must be defined on each backend instance group. This parameter has no meaning if the backends are NEGs.
704 #
705 #
706 #
707 # Must be omitted when the loadBalancingScheme is INTERNAL (Internal TCP/UDP Load Balancing).
708 &quot;protocol&quot;: &quot;A String&quot;, # The protocol this BackendService uses to communicate with backends.
709 #
Dmitry Frenkel3e17f892020-10-06 16:46:05 -0700710 # Possible values are HTTP, HTTPS, HTTP2, TCP, SSL, UDP or GRPC. depending on the chosen load balancer or Traffic Director configuration. Refer to the documentation for the load balancer or for Traffic Director for more information.
711 #
712 # Must be set to GRPC when the backend service is referenced by a URL map that is bound to target gRPC proxy.
Bu Sun Kim65020912020-05-20 12:08:20 -0700713 &quot;region&quot;: &quot;A String&quot;, # [Output Only] URL of the region where the regional backend service resides. This field is not applicable to global backend services. You must specify this field as part of the HTTP request URL. It is not settable as a field in the request body.
714 &quot;securityPolicy&quot;: &quot;A String&quot;, # [Output Only] The resource URL for the security policy associated with this backend service.
Bu Sun Kim673ec5c2020-11-16 11:05:03 -0700715 &quot;securitySettings&quot;: { # The authentication and authorization settings for a BackendService. # This field specifies the security policy that applies to this backend service. This field is applicable to either:
716 # - A regional backend service with the service_protocol set to HTTP, HTTPS, or HTTP2, and load_balancing_scheme set to INTERNAL_MANAGED.
717 # - A global backend service with the load_balancing_scheme set to INTERNAL_SELF_MANAGED.
718 &quot;clientTlsPolicy&quot;: &quot;A String&quot;, # Optional. A URL referring to a networksecurity.ClientTlsPolicy resource that describes how clients should authenticate with this service&#x27;s backends.
719 # clientTlsPolicy only applies to a global BackendService with the loadBalancingScheme set to INTERNAL_SELF_MANAGED.
720 # If left blank, communications are not encrypted.
721 # Note: This field currently has no impact.
722 &quot;subjectAltNames&quot;: [ # Optional. A list of Subject Alternative Names (SANs) that the client verifies during a mutual TLS handshake with an server/endpoint for this BackendService. When the server presents its X.509 certificate to the client, the client inspects the certificate&#x27;s subjectAltName field. If the field contains one of the specified values, the communication continues. Otherwise, it fails. This additional check enables the client to verify that the server is authorized to run the requested service.
723 # Note that the contents of the server certificate&#x27;s subjectAltName field are configured by the Public Key Infrastructure which provisions server identities.
724 # Only applies to a global BackendService with loadBalancingScheme set to INTERNAL_SELF_MANAGED. Only applies when BackendService has an attached clientTlsPolicy with clientCertificate (mTLS mode).
725 # Note: This field currently has no impact.
726 &quot;A String&quot;,
727 ],
728 },
Bu Sun Kim65020912020-05-20 12:08:20 -0700729 &quot;selfLink&quot;: &quot;A String&quot;, # [Output Only] Server-defined URL for the resource.
730 &quot;sessionAffinity&quot;: &quot;A String&quot;, # Type of session affinity to use. The default is NONE. Session affinity is not applicable if the --protocol is UDP.
731 #
732 # When the loadBalancingScheme is EXTERNAL, possible values are NONE, CLIENT_IP, or GENERATED_COOKIE. You can use GENERATED_COOKIE if the protocol is HTTP or HTTPS.
733 #
734 # When the loadBalancingScheme is INTERNAL, possible values are NONE, CLIENT_IP, CLIENT_IP_PROTO, or CLIENT_IP_PORT_PROTO.
735 #
736 # When the loadBalancingScheme is INTERNAL_SELF_MANAGED, or INTERNAL_MANAGED, possible values are NONE, CLIENT_IP, GENERATED_COOKIE, HEADER_FIELD, or HTTP_COOKIE.
Dmitry Frenkel3e17f892020-10-06 16:46:05 -0700737 #
738 # Not supported when the backend service is referenced by a URL map that is bound to target gRPC proxy that has validateForProxyless field set to true.
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700739 &quot;timeoutSec&quot;: 42, # The backend service timeout has a different meaning depending on the type of load balancer. For more information see, Backend service settings The default is 30 seconds.
Bu Sun Kim65020912020-05-20 12:08:20 -0700740}
741
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700742 requestId: string, An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed.
743
744For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments.
745
746The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000).
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800747
748Returns:
749 An object of the form:
750
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700751 { # Represents an Operation resource.
752 #
Dan O'Mearadd494642020-05-01 07:42:23 -0700753 # Google Compute Engine has three Operation resources:
754 #
755 # * [Global](/compute/docs/reference/rest/{$api_version}/globalOperations) * [Regional](/compute/docs/reference/rest/{$api_version}/regionOperations) * [Zonal](/compute/docs/reference/rest/{$api_version}/zoneOperations)
756 #
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700757 # You can use an operation resource to manage asynchronous API requests. For more information, read Handling API responses.
758 #
759 # Operations can be global, regional or zonal.
Dan O'Mearadd494642020-05-01 07:42:23 -0700760 # - For global operations, use the `globalOperations` resource.
761 # - For regional operations, use the `regionOperations` resource.
762 # - For zonal operations, use the `zonalOperations` resource.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700763 #
Dan O'Mearadd494642020-05-01 07:42:23 -0700764 # For more information, read Global, Regional, and Zonal Resources. (== resource_for {$api_version}.globalOperations ==) (== resource_for {$api_version}.regionOperations ==) (== resource_for {$api_version}.zoneOperations ==)
Bu Sun Kim65020912020-05-20 12:08:20 -0700765 &quot;clientOperationId&quot;: &quot;A String&quot;, # [Output Only] The value of `requestId` if you provided it in the request. Not present otherwise.
766 &quot;creationTimestamp&quot;: &quot;A String&quot;, # [Deprecated] This field is deprecated.
767 &quot;description&quot;: &quot;A String&quot;, # [Output Only] A textual description of the operation, which is set when the operation is created.
768 &quot;endTime&quot;: &quot;A String&quot;, # [Output Only] The time that this operation was completed. This value is in RFC3339 text format.
769 &quot;error&quot;: { # [Output Only] If errors are generated during processing of the operation, this field will be populated.
770 &quot;errors&quot;: [ # [Output Only] The array of errors encountered while processing this operation.
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800771 {
Bu Sun Kim65020912020-05-20 12:08:20 -0700772 &quot;code&quot;: &quot;A String&quot;, # [Output Only] The error type identifier for this error.
773 &quot;location&quot;: &quot;A String&quot;, # [Output Only] Indicates the field in the request that caused the error. This property is optional.
774 &quot;message&quot;: &quot;A String&quot;, # [Output Only] An optional, human-readable error message.
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800775 },
776 ],
777 },
Bu Sun Kim65020912020-05-20 12:08:20 -0700778 &quot;httpErrorMessage&quot;: &quot;A String&quot;, # [Output Only] If the operation fails, this field contains the HTTP error message that was returned, such as `NOT FOUND`.
779 &quot;httpErrorStatusCode&quot;: 42, # [Output Only] If the operation fails, this field contains the HTTP error status code that was returned. For example, a `404` means the resource was not found.
780 &quot;id&quot;: &quot;A String&quot;, # [Output Only] The unique identifier for the operation. This identifier is defined by the server.
781 &quot;insertTime&quot;: &quot;A String&quot;, # [Output Only] The time that this operation was requested. This value is in RFC3339 text format.
782 &quot;kind&quot;: &quot;compute#operation&quot;, # [Output Only] Type of the resource. Always `compute#operation` for Operation resources.
783 &quot;name&quot;: &quot;A String&quot;, # [Output Only] Name of the operation.
784 &quot;operationType&quot;: &quot;A String&quot;, # [Output Only] The type of operation, such as `insert`, `update`, or `delete`, and so on.
785 &quot;progress&quot;: 42, # [Output Only] An optional progress indicator that ranges from 0 to 100. There is no requirement that this be linear or support any granularity of operations. This should not be used to guess when the operation will be complete. This number should monotonically increase as the operation progresses.
786 &quot;region&quot;: &quot;A String&quot;, # [Output Only] The URL of the region where the operation resides. Only applicable when performing regional operations.
787 &quot;selfLink&quot;: &quot;A String&quot;, # [Output Only] Server-defined URL for the resource.
788 &quot;startTime&quot;: &quot;A String&quot;, # [Output Only] The time that this operation was started by the server. This value is in RFC3339 text format.
789 &quot;status&quot;: &quot;A String&quot;, # [Output Only] The status of the operation, which can be one of the following: `PENDING`, `RUNNING`, or `DONE`.
790 &quot;statusMessage&quot;: &quot;A String&quot;, # [Output Only] An optional textual description of the current status of the operation.
791 &quot;targetId&quot;: &quot;A String&quot;, # [Output Only] The unique target ID, which identifies a specific incarnation of the target resource.
792 &quot;targetLink&quot;: &quot;A String&quot;, # [Output Only] The URL of the resource that the operation modifies. For operations related to creating a snapshot, this points to the persistent disk that the snapshot was created from.
793 &quot;user&quot;: &quot;A String&quot;, # [Output Only] User who requested the operation, for example: `user@example.com`.
794 &quot;warnings&quot;: [ # [Output Only] If warning messages are generated during processing of the operation, this field will be populated.
795 {
796 &quot;code&quot;: &quot;A String&quot;, # [Output Only] A warning code, if applicable. For example, Compute Engine returns NO_RESULTS_ON_PAGE if there are no results in the response.
797 &quot;data&quot;: [ # [Output Only] Metadata about this warning in key: value format. For example:
798 # &quot;data&quot;: [ { &quot;key&quot;: &quot;scope&quot;, &quot;value&quot;: &quot;zones/us-east1-d&quot; }
799 {
800 &quot;key&quot;: &quot;A String&quot;, # [Output Only] A key that provides more detail on the warning being returned. For example, for warnings where there are no results in a list request for a particular zone, this key might be scope and the key value might be the zone name. Other examples might be a key indicating a deprecated resource and a suggested replacement, or a warning about invalid network settings (for example, if an instance attempts to perform IP forwarding but is not enabled for IP forwarding).
801 &quot;value&quot;: &quot;A String&quot;, # [Output Only] A warning data value corresponding to the key.
802 },
803 ],
804 &quot;message&quot;: &quot;A String&quot;, # [Output Only] A human-readable description of the warning code.
805 },
806 ],
807 &quot;zone&quot;: &quot;A String&quot;, # [Output Only] The URL of the zone where the operation resides. Only applicable when performing per-zone operations.
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800808 }</pre>
809</div>
810
811<div class="method">
Dmitry Frenkel3e17f892020-10-06 16:46:05 -0700812 <code class="details" id="list">list(project, region, filter=None, maxResults=None, orderBy=None, pageToken=None, returnPartialSuccess=None)</code>
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800813 <pre>Retrieves the list of regional BackendService resources available to the specified project in the given region.
814
815Args:
816 project: string, Project ID for this request. (required)
817 region: string, Name of the region scoping this request. (required)
Dan O'Mearadd494642020-05-01 07:42:23 -0700818 filter: string, A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either `=`, `!=`, `&gt;`, or `&lt;`.
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800819
Dan O'Mearadd494642020-05-01 07:42:23 -0700820For example, if you are filtering Compute Engine instances, you can exclude instances named `example-instance` by specifying `name != example-instance`.
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800821
Dan O'Mearadd494642020-05-01 07:42:23 -0700822You can also filter nested fields. For example, you could specify `scheduling.automaticRestart = false` to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels.
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800823
Bu Sun Kim65020912020-05-20 12:08:20 -0700824To filter on multiple expressions, provide each separate expression within parentheses. For example: ``` (scheduling.automaticRestart = true) (cpuPlatform = &quot;Intel Skylake&quot;) ``` By default, each expression is an `AND` expression. However, you can include `AND` and `OR` expressions explicitly. For example: ``` (cpuPlatform = &quot;Intel Skylake&quot;) OR (cpuPlatform = &quot;Intel Broadwell&quot;) AND (scheduling.automaticRestart = true) ```
825 maxResults: integer, The maximum number of results per page that should be returned. If the number of available results is larger than `maxResults`, Compute Engine returns a `nextPageToken` that can be used to get the next page of results in subsequent list requests. Acceptable values are `0` to `500`, inclusive. (Default: `500`)
826 orderBy: string, Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name.
827
828You can also sort results in descending order based on the creation timestamp using `orderBy=&quot;creationTimestamp desc&quot;`. This sorts results based on the `creationTimestamp` field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first.
829
830Currently, only sorting by `name` or `creationTimestamp desc` is supported.
831 pageToken: string, Specifies a page token to use. Set `pageToken` to the `nextPageToken` returned by a previous list request to get the next page of results.
Dmitry Frenkel3e17f892020-10-06 16:46:05 -0700832 returnPartialSuccess: boolean, Opt-in for partial success behavior which provides partial results in case of failure. The default value is false and the logic is the same as today.
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800833
834Returns:
835 An object of the form:
836
837 { # Contains a list of BackendService resources.
Bu Sun Kim65020912020-05-20 12:08:20 -0700838 &quot;id&quot;: &quot;A String&quot;, # [Output Only] Unique identifier for the resource; defined by the server.
839 &quot;items&quot;: [ # A list of BackendService resources.
Dan O'Mearadd494642020-05-01 07:42:23 -0700840 { # Represents a Backend Service resource.
Bu Sun Kim65020912020-05-20 12:08:20 -0700841 #
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700842 # A backend service defines how Google Cloud load balancers distribute traffic. The backend service configuration contains a set of values, such as the protocol used to connect to backends, various distribution and session settings, health checks, and timeouts. These settings provide fine-grained control over how your load balancer behaves. Most of the settings have default values that allow for easy configuration if you need to get started quickly.
Bu Sun Kim65020912020-05-20 12:08:20 -0700843 #
844 # Backend services in Google Compute Engine can be either regionally or globally scoped.
845 #
846 # * [Global](/compute/docs/reference/rest/{$api_version}/backendServices) * [Regional](/compute/docs/reference/rest/{$api_version}/regionBackendServices)
847 #
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700848 # For more information, see Backend Services.
Bu Sun Kim65020912020-05-20 12:08:20 -0700849 #
850 # (== resource_for {$api_version}.backendService ==)
Dmitry Frenkel3e17f892020-10-06 16:46:05 -0700851 &quot;affinityCookieTtlSec&quot;: 42, # Lifetime of cookies in seconds. Only applicable if the loadBalancingScheme is EXTERNAL, INTERNAL_SELF_MANAGED, or INTERNAL_MANAGED, the protocol is HTTP or HTTPS, and the sessionAffinity is GENERATED_COOKIE, or HTTP_COOKIE.
852 #
853 # If set to 0, the cookie is non-persistent and lasts only until the end of the browser session (or equivalent). The maximum allowed value is one day (86,400).
854 #
855 # Not supported when the backend service is referenced by a URL map that is bound to target gRPC proxy that has validateForProxyless field set to true.
Bu Sun Kim65020912020-05-20 12:08:20 -0700856 &quot;backends&quot;: [ # The list of backends that serve this BackendService.
857 { # Message containing information of one individual backend.
858 &quot;balancingMode&quot;: &quot;A String&quot;, # Specifies the balancing mode for the backend.
859 #
860 # When choosing a balancing mode, you need to consider the loadBalancingScheme, and protocol for the backend service, as well as the type of backend (instance group or NEG).
861 #
862 #
863 # - If the load balancing mode is CONNECTION, then the load is spread based on how many concurrent connections the backend can handle.
864 # You can use the CONNECTION balancing mode if the protocol for the backend service is SSL, TCP, or UDP.
865 #
866 # If the loadBalancingScheme for the backend service is EXTERNAL (SSL Proxy and TCP Proxy load balancers), you must also specify exactly one of the following parameters: maxConnections (except for regional managed instance groups), maxConnectionsPerInstance, or maxConnectionsPerEndpoint.
867 #
868 # If the loadBalancingScheme for the backend service is INTERNAL (internal TCP/UDP load balancers), you cannot specify any additional parameters.
869 #
870 # - If the load balancing mode is RATE, the load is spread based on the rate of HTTP requests per second (RPS).
871 # You can use the RATE balancing mode if the protocol for the backend service is HTTP or HTTPS. You must specify exactly one of the following parameters: maxRate (except for regional managed instance groups), maxRatePerInstance, or maxRatePerEndpoint.
872 #
873 # - If the load balancing mode is UTILIZATION, the load is spread based on the backend utilization of instances in an instance group.
874 # You can use the UTILIZATION balancing mode if the loadBalancingScheme of the backend service is EXTERNAL, INTERNAL_SELF_MANAGED, or INTERNAL_MANAGED and the backends are instance groups. There are no restrictions on the backend service protocol.
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700875 &quot;capacityScaler&quot;: 3.14, # A multiplier applied to the group&#x27;s maximum servicing capacity (based on UTILIZATION, RATE or CONNECTION). Default value is 1, which means the group will serve up to 100% of its configured capacity (depending on balancingMode). A setting of 0 means the group is completely drained, offering 0% of its available capacity. Valid range is 0.0 and [0.1,1.0]. You cannot configure a setting larger than 0 and smaller than 0.1. You cannot configure a setting of 0 when there is only one backend attached to the backend service.
Bu Sun Kim65020912020-05-20 12:08:20 -0700876 #
877 # This cannot be used for internal load balancing.
878 &quot;description&quot;: &quot;A String&quot;, # An optional description of this resource. Provide this property when you create the resource.
879 &quot;failover&quot;: True or False, # This field designates whether this is a failover backend. More than one failover backend can be configured for a given BackendService.
880 &quot;group&quot;: &quot;A String&quot;, # The fully-qualified URL of an instance group or network endpoint group (NEG) resource. The type of backend that a backend service supports depends on the backend service&#x27;s loadBalancingScheme.
881 #
882 #
883 # - When the loadBalancingScheme for the backend service is EXTERNAL, INTERNAL_SELF_MANAGED, or INTERNAL_MANAGED, the backend can be either an instance group or a NEG. The backends on the backend service must be either all instance groups or all NEGs. You cannot mix instance group and NEG backends on the same backend service.
884 #
885 #
886 # - When the loadBalancingScheme for the backend service is INTERNAL, the backend must be an instance group in the same region as the backend service. NEGs are not supported.
887 #
888 # You must use the fully-qualified URL (starting with https://www.googleapis.com/) to specify the instance group or NEG. Partial URLs are not supported.
889 &quot;maxConnections&quot;: 42, # Defines a target maximum number of simultaneous connections that the backend can handle. Valid for network endpoint group and instance group backends (except for regional managed instance groups). If the backend&#x27;s balancingMode is UTILIZATION, this is an optional parameter. If the backend&#x27;s balancingMode is CONNECTION, and backend is attached to a backend service whose loadBalancingScheme is EXTERNAL, you must specify either this parameter, maxConnectionsPerInstance, or maxConnectionsPerEndpoint.
890 #
891 # Not available if the backend&#x27;s balancingMode is RATE. If the loadBalancingScheme is INTERNAL, then maxConnections is not supported, even though the backend requires a balancing mode of CONNECTION.
892 &quot;maxConnectionsPerEndpoint&quot;: 42, # Defines a target maximum number of simultaneous connections for an endpoint of a NEG. This is multiplied by the number of endpoints in the NEG to implicitly calculate a maximum number of target maximum simultaneous connections for the NEG. If the backend&#x27;s balancingMode is CONNECTION, and the backend is attached to a backend service whose loadBalancingScheme is EXTERNAL, you must specify either this parameter, maxConnections, or maxConnectionsPerInstance.
893 #
894 # Not available if the backend&#x27;s balancingMode is RATE. Internal TCP/UDP load balancing does not support setting maxConnectionsPerEndpoint even though its backends require a balancing mode of CONNECTION.
895 &quot;maxConnectionsPerInstance&quot;: 42, # Defines a target maximum number of simultaneous connections for a single VM in a backend instance group. This is multiplied by the number of instances in the instance group to implicitly calculate a target maximum number of simultaneous connections for the whole instance group. If the backend&#x27;s balancingMode is UTILIZATION, this is an optional parameter. If the backend&#x27;s balancingMode is CONNECTION, and backend is attached to a backend service whose loadBalancingScheme is EXTERNAL, you must specify either this parameter, maxConnections, or maxConnectionsPerEndpoint.
896 #
897 # Not available if the backend&#x27;s balancingMode is RATE. Internal TCP/UDP load balancing does not support setting maxConnectionsPerInstance even though its backends require a balancing mode of CONNECTION.
898 &quot;maxRate&quot;: 42, # Defines a maximum number of HTTP requests per second (RPS) that the backend can handle. Valid for network endpoint group and instance group backends (except for regional managed instance groups). Must not be defined if the backend is a managed instance group that uses autoscaling based on load balancing.
899 #
900 # If the backend&#x27;s balancingMode is UTILIZATION, this is an optional parameter. If the backend&#x27;s balancingMode is RATE, you must specify maxRate, maxRatePerInstance, or maxRatePerEndpoint.
901 #
902 # Not available if the backend&#x27;s balancingMode is CONNECTION.
903 &quot;maxRatePerEndpoint&quot;: 3.14, # Defines a maximum target for requests per second (RPS) for an endpoint of a NEG. This is multiplied by the number of endpoints in the NEG to implicitly calculate a target maximum rate for the NEG.
904 #
905 # If the backend&#x27;s balancingMode is RATE, you must specify either this parameter, maxRate (except for regional managed instance groups), or maxRatePerInstance.
906 #
907 # Not available if the backend&#x27;s balancingMode is CONNECTION.
908 &quot;maxRatePerInstance&quot;: 3.14, # Defines a maximum target for requests per second (RPS) for a single VM in a backend instance group. This is multiplied by the number of instances in the instance group to implicitly calculate a target maximum rate for the whole instance group.
909 #
910 # If the backend&#x27;s balancingMode is UTILIZATION, this is an optional parameter. If the backend&#x27;s balancingMode is RATE, you must specify either this parameter, maxRate (except for regional managed instance groups), or maxRatePerEndpoint.
911 #
912 # Not available if the backend&#x27;s balancingMode is CONNECTION.
913 &quot;maxUtilization&quot;: 3.14, # Defines the maximum average backend utilization of a backend VM in an instance group. The valid range is [0.0, 1.0]. This is an optional parameter if the backend&#x27;s balancingMode is UTILIZATION.
914 #
915 # This parameter can be used in conjunction with maxRate, maxRatePerInstance, maxConnections (except for regional managed instance groups), or maxConnectionsPerInstance.
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800916 },
Bu Sun Kim65020912020-05-20 12:08:20 -0700917 ],
918 &quot;cdnPolicy&quot;: { # Message containing Cloud CDN configuration for a backend service. # Cloud CDN configuration for this BackendService.
919 &quot;cacheKeyPolicy&quot;: { # Message containing what to include in the cache key for a request for Cloud CDN. # The CacheKeyPolicy for this CdnPolicy.
920 &quot;includeHost&quot;: True or False, # If true, requests to different hosts will be cached separately.
921 &quot;includeProtocol&quot;: True or False, # If true, http and https requests will be cached separately.
922 &quot;includeQueryString&quot;: True or False, # If true, include query string parameters in the cache key according to query_string_whitelist and query_string_blacklist. If neither is set, the entire query string will be included. If false, the query string will be excluded from the cache key entirely.
923 &quot;queryStringBlacklist&quot;: [ # Names of query string parameters to exclude in cache keys. All other parameters will be included. Either specify query_string_whitelist or query_string_blacklist, not both. &#x27;&amp;&#x27; and &#x27;=&#x27; will be percent encoded and not treated as delimiters.
924 &quot;A String&quot;,
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700925 ],
Bu Sun Kim65020912020-05-20 12:08:20 -0700926 &quot;queryStringWhitelist&quot;: [ # Names of query string parameters to include in cache keys. All other parameters will be excluded. Either specify query_string_whitelist or query_string_blacklist, not both. &#x27;&amp;&#x27; and &#x27;=&#x27; will be percent encoded and not treated as delimiters.
927 &quot;A String&quot;,
928 ],
Sai Cheemalapati4ba8c232017-06-06 18:46:08 -0400929 },
Bu Sun Kim65020912020-05-20 12:08:20 -0700930 &quot;signedUrlCacheMaxAgeSec&quot;: &quot;A String&quot;, # Maximum number of seconds the response to a signed URL request will be considered fresh. After this time period, the response will be revalidated before being served. Defaults to 1hr (3600s). When serving responses to signed URL requests, Cloud CDN will internally behave as though all responses from this backend had a &quot;Cache-Control: public, max-age=[TTL]&quot; header, regardless of any existing Cache-Control header. The actual headers served in responses will not be altered.
931 &quot;signedUrlKeyNames&quot;: [ # [Output Only] Names of the keys for signing request URLs.
932 &quot;A String&quot;,
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800933 ],
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800934 },
Bu Sun Kim65020912020-05-20 12:08:20 -0700935 &quot;circuitBreakers&quot;: { # Settings controlling the volume of connections to a backend service. # Settings controlling the volume of connections to a backend service. If not set, this feature is considered disabled.
936 #
937 # This field is applicable to either:
938 # - A regional backend service with the service_protocol set to HTTP, HTTPS, or HTTP2, and load_balancing_scheme set to INTERNAL_MANAGED.
939 # - A global backend service with the load_balancing_scheme set to INTERNAL_SELF_MANAGED.
Dmitry Frenkel3e17f892020-10-06 16:46:05 -0700940 #
941 # Not supported when the backend service is referenced by a URL map that is bound to target gRPC proxy that has validateForProxyless field set to true.
Bu Sun Kim65020912020-05-20 12:08:20 -0700942 &quot;maxConnections&quot;: 42, # The maximum number of connections to the backend service. If not specified, there is no limit.
943 &quot;maxPendingRequests&quot;: 42, # The maximum number of pending requests allowed to the backend service. If not specified, there is no limit.
944 &quot;maxRequests&quot;: 42, # The maximum number of parallel requests that allowed to the backend service. If not specified, there is no limit.
945 &quot;maxRequestsPerConnection&quot;: 42, # Maximum requests for a single connection to the backend service. This parameter is respected by both the HTTP/1.1 and HTTP/2 implementations. If not specified, there is no limit. Setting this parameter to 1 will effectively disable keep alive.
946 &quot;maxRetries&quot;: 42, # The maximum number of parallel retries allowed to the backend cluster. If not specified, the default is 1.
947 },
948 &quot;connectionDraining&quot;: { # Message containing connection draining configuration.
949 &quot;drainingTimeoutSec&quot;: 42, # The amount of time in seconds to allow existing connections to persist while on unhealthy backend VMs. Only applicable if the protocol is not UDP. The valid range is [0, 3600].
950 },
951 &quot;consistentHash&quot;: { # This message defines settings for a consistent hash style load balancer. # Consistent Hash-based load balancing can be used to provide soft session affinity based on HTTP headers, cookies or other properties. This load balancing policy is applicable only for HTTP connections. The affinity to a particular destination host will be lost when one or more hosts are added/removed from the destination service. This field specifies parameters that control consistent hashing. This field is only applicable when localityLbPolicy is set to MAGLEV or RING_HASH.
952 #
953 # This field is applicable to either:
954 # - A regional backend service with the service_protocol set to HTTP, HTTPS, or HTTP2, and load_balancing_scheme set to INTERNAL_MANAGED.
955 # - A global backend service with the load_balancing_scheme set to INTERNAL_SELF_MANAGED.
Dmitry Frenkel3e17f892020-10-06 16:46:05 -0700956 #
957 # Not supported when the backend service is referenced by a URL map that is bound to target gRPC proxy that has validateForProxyless field set to true.
Bu Sun Kim65020912020-05-20 12:08:20 -0700958 &quot;httpCookie&quot;: { # The information about the HTTP Cookie on which the hash function is based for load balancing policies that use a consistent hash. # Hash is based on HTTP Cookie. This field describes a HTTP cookie that will be used as the hash key for the consistent hash load balancer. If the cookie is not present, it will be generated. This field is applicable if the sessionAffinity is set to HTTP_COOKIE.
959 &quot;name&quot;: &quot;A String&quot;, # Name of the cookie.
960 &quot;path&quot;: &quot;A String&quot;, # Path to set for the cookie.
961 &quot;ttl&quot;: { # A Duration represents a fixed-length span of time represented as a count of seconds and fractions of seconds at nanosecond resolution. It is independent of any calendar and concepts like &quot;day&quot; or &quot;month&quot;. Range is approximately 10,000 years. # Lifetime of the cookie.
962 &quot;nanos&quot;: 42, # Span of time that&#x27;s a fraction of a second at nanosecond resolution. Durations less than one second are represented with a 0 `seconds` field and a positive `nanos` field. Must be from 0 to 999,999,999 inclusive.
963 &quot;seconds&quot;: &quot;A String&quot;, # Span of time at a resolution of a second. Must be from 0 to 315,576,000,000 inclusive. Note: these bounds are computed from: 60 sec/min * 60 min/hr * 24 hr/day * 365.25 days/year * 10000 years
964 },
965 },
966 &quot;httpHeaderName&quot;: &quot;A String&quot;, # The hash based on the value of the specified header field. This field is applicable if the sessionAffinity is set to HEADER_FIELD.
967 &quot;minimumRingSize&quot;: &quot;A String&quot;, # The minimum number of virtual nodes to use for the hash ring. Defaults to 1024. Larger ring sizes result in more granular load distributions. If the number of hosts in the load balancing pool is larger than the ring size, each host will be assigned a single virtual node.
968 },
969 &quot;creationTimestamp&quot;: &quot;A String&quot;, # [Output Only] Creation timestamp in RFC3339 text format.
970 &quot;customRequestHeaders&quot;: [ # Headers that the HTTP/S load balancer should add to proxied requests.
971 &quot;A String&quot;,
972 ],
973 &quot;description&quot;: &quot;A String&quot;, # An optional description of this resource. Provide this property when you create the resource.
974 &quot;enableCDN&quot;: True or False, # If true, enables Cloud CDN for the backend service. Only applicable if the loadBalancingScheme is EXTERNAL and the protocol is HTTP or HTTPS.
975 &quot;failoverPolicy&quot;: { # Applicable only to Failover for Internal TCP/UDP Load Balancing. On failover or failback, this field indicates whether connection draining will be honored. GCP has a fixed connection draining timeout of 10 minutes. A setting of true terminates existing TCP connections to the active pool during failover and failback, immediately draining traffic. A setting of false allows existing TCP connections to persist, even on VMs no longer in the active pool, for up to the duration of the connection draining timeout (10 minutes). # Applicable only to Failover for Internal TCP/UDP Load Balancing. Requires at least one backend instance group to be defined as a backup (failover) backend.
976 &quot;disableConnectionDrainOnFailover&quot;: True or False, # This can be set to true only if the protocol is TCP.
977 #
978 # The default is false.
979 &quot;dropTrafficIfUnhealthy&quot;: True or False, # Applicable only to Failover for Internal TCP/UDP Load Balancing. If set to true, connections to the load balancer are dropped when all primary and all backup backend VMs are unhealthy. If set to false, connections are distributed among all primary VMs when all primary and all backup backend VMs are unhealthy.
980 #
981 # The default is false.
982 &quot;failoverRatio&quot;: 3.14, # Applicable only to Failover for Internal TCP/UDP Load Balancing. The value of the field must be in the range [0, 1]. If the value is 0, the load balancer performs a failover when the number of healthy primary VMs equals zero. For all other values, the load balancer performs a failover when the total number of healthy primary VMs is less than this ratio.
983 },
984 &quot;fingerprint&quot;: &quot;A String&quot;, # Fingerprint of this resource. A hash of the contents stored in this object. This field is used in optimistic locking. This field will be ignored when inserting a BackendService. An up-to-date fingerprint must be provided in order to update the BackendService, otherwise the request will fail with error 412 conditionNotMet.
985 #
986 # To see the latest fingerprint, make a get() request to retrieve a BackendService.
Dmitry Frenkel3e17f892020-10-06 16:46:05 -0700987 &quot;healthChecks&quot;: [ # The list of URLs to the healthChecks, httpHealthChecks (legacy), or httpsHealthChecks (legacy) resource for health checking this backend service. Not all backend services support legacy health checks. See Load balancer guide. Currently, at most one health check can be specified for each backend service. Backend services with instance group or zonal NEG backends must have a health check. Backend services with internet or serverless NEG backends must not have a health check.
Bu Sun Kim65020912020-05-20 12:08:20 -0700988 &quot;A String&quot;,
989 ],
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700990 &quot;iap&quot;: { # Identity-Aware Proxy # The configurations for Identity-Aware Proxy on this resource.
991 &quot;enabled&quot;: True or False, # Whether the serving infrastructure will authenticate and authorize all incoming requests. If true, the oauth2ClientId and oauth2ClientSecret fields must be non-empty.
992 &quot;oauth2ClientId&quot;: &quot;A String&quot;, # OAuth2 client ID to use for the authentication flow.
993 &quot;oauth2ClientSecret&quot;: &quot;A String&quot;, # OAuth2 client secret to use for the authentication flow. For security reasons, this value cannot be retrieved via the API. Instead, the SHA-256 hash of the value is returned in the oauth2ClientSecretSha256 field.
Bu Sun Kim65020912020-05-20 12:08:20 -0700994 &quot;oauth2ClientSecretSha256&quot;: &quot;A String&quot;, # [Output Only] SHA256 hash value for the field oauth2_client_secret above.
995 },
996 &quot;id&quot;: &quot;A String&quot;, # [Output Only] The unique identifier for the resource. This identifier is defined by the server.
997 &quot;kind&quot;: &quot;compute#backendService&quot;, # [Output Only] Type of resource. Always compute#backendService for backend services.
998 &quot;loadBalancingScheme&quot;: &quot;A String&quot;, # Specifies the load balancer type. Choose EXTERNAL for load balancers that receive traffic from external clients. Choose INTERNAL for Internal TCP/UDP Load Balancing. Choose INTERNAL_MANAGED for Internal HTTP(S) Load Balancing. Choose INTERNAL_SELF_MANAGED for Traffic Director. A backend service created for one type of load balancing cannot be used with another. For more information, refer to Choosing a load balancer.
999 &quot;localityLbPolicy&quot;: &quot;A String&quot;, # The load balancing algorithm used within the scope of the locality. The possible values are:
1000 # - ROUND_ROBIN: This is a simple policy in which each healthy backend is selected in round robin order. This is the default.
1001 # - LEAST_REQUEST: An O(1) algorithm which selects two random healthy hosts and picks the host which has fewer active requests.
1002 # - RING_HASH: The ring/modulo hash load balancer implements consistent hashing to backends. The algorithm has the property that the addition/removal of a host from a set of N hosts only affects 1/N of the requests.
1003 # - RANDOM: The load balancer selects a random healthy host.
1004 # - ORIGINAL_DESTINATION: Backend host is selected based on the client connection metadata, i.e., connections are opened to the same address as the destination address of the incoming connection before the connection was redirected to the load balancer.
Bu Sun Kimd059ad82020-07-22 17:02:09 -07001005 # - MAGLEV: used as a drop in replacement for the ring hash load balancer. Maglev is not as stable as ring hash but has faster table lookup build times and host selection times. For more information about Maglev, see https://ai.google/research/pubs/pub44824
Bu Sun Kim65020912020-05-20 12:08:20 -07001006 #
1007 # This field is applicable to either:
1008 # - A regional backend service with the service_protocol set to HTTP, HTTPS, or HTTP2, and load_balancing_scheme set to INTERNAL_MANAGED.
1009 # - A global backend service with the load_balancing_scheme set to INTERNAL_SELF_MANAGED.
1010 #
Dmitry Frenkel3e17f892020-10-06 16:46:05 -07001011 # If sessionAffinity is not NONE, and this field is not set to MAGLEV or RING_HASH, session affinity settings will not take effect.
1012 #
1013 # Only the default ROUND_ROBIN policy is supported when the backend service is referenced by a URL map that is bound to target gRPC proxy that has validateForProxyless field set to true.
Bu Sun Kim65020912020-05-20 12:08:20 -07001014 &quot;logConfig&quot;: { # The available logging options for the load balancer traffic served by this backend service. # This field denotes the logging options for the load balancer traffic served by this backend service. If logging is enabled, logs will be exported to Stackdriver.
1015 &quot;enable&quot;: True or False, # This field denotes whether to enable logging for the load balancer traffic served by this backend service.
1016 &quot;sampleRate&quot;: 3.14, # This field can only be specified if logging is enabled for this backend service. The value of the field must be in [0, 1]. This configures the sampling rate of requests to the load balancer where 1.0 means all logged requests are reported and 0.0 means no logged requests are reported. The default value is 1.0.
1017 },
1018 &quot;name&quot;: &quot;A String&quot;, # Name of the resource. Provided by the client when the resource is created. The name must be 1-63 characters long, and comply with RFC1035. Specifically, the name must be 1-63 characters long and match the regular expression `[a-z]([-a-z0-9]*[a-z0-9])?` which means the first character must be a lowercase letter, and all following characters must be a dash, lowercase letter, or digit, except the last character, which cannot be a dash.
1019 &quot;network&quot;: &quot;A String&quot;, # The URL of the network to which this backend service belongs. This field can only be spcified when the load balancing scheme is set to INTERNAL.
1020 &quot;outlierDetection&quot;: { # Settings controlling the eviction of unhealthy hosts from the load balancing pool for the backend service. # Settings controlling the eviction of unhealthy hosts from the load balancing pool for the backend service. If not set, this feature is considered disabled.
1021 #
1022 # This field is applicable to either:
1023 # - A regional backend service with the service_protocol set to HTTP, HTTPS, or HTTP2, and load_balancing_scheme set to INTERNAL_MANAGED.
1024 # - A global backend service with the load_balancing_scheme set to INTERNAL_SELF_MANAGED.
Dmitry Frenkel3e17f892020-10-06 16:46:05 -07001025 #
1026 # Not supported when the backend service is referenced by a URL map that is bound to target gRPC proxy that has validateForProxyless field set to true.
Bu Sun Kim65020912020-05-20 12:08:20 -07001027 &quot;baseEjectionTime&quot;: { # A Duration represents a fixed-length span of time represented as a count of seconds and fractions of seconds at nanosecond resolution. It is independent of any calendar and concepts like &quot;day&quot; or &quot;month&quot;. Range is approximately 10,000 years. # The base time that a host is ejected for. The real ejection time is equal to the base ejection time multiplied by the number of times the host has been ejected. Defaults to 30000ms or 30s.
1028 &quot;nanos&quot;: 42, # Span of time that&#x27;s a fraction of a second at nanosecond resolution. Durations less than one second are represented with a 0 `seconds` field and a positive `nanos` field. Must be from 0 to 999,999,999 inclusive.
1029 &quot;seconds&quot;: &quot;A String&quot;, # Span of time at a resolution of a second. Must be from 0 to 315,576,000,000 inclusive. Note: these bounds are computed from: 60 sec/min * 60 min/hr * 24 hr/day * 365.25 days/year * 10000 years
1030 },
1031 &quot;consecutiveErrors&quot;: 42, # Number of errors before a host is ejected from the connection pool. When the backend host is accessed over HTTP, a 5xx return code qualifies as an error. Defaults to 5.
1032 &quot;consecutiveGatewayFailure&quot;: 42, # The number of consecutive gateway failures (502, 503, 504 status or connection errors that are mapped to one of those status codes) before a consecutive gateway failure ejection occurs. Defaults to 3.
1033 &quot;enforcingConsecutiveErrors&quot;: 42, # The percentage chance that a host will be actually ejected when an outlier status is detected through consecutive 5xx. This setting can be used to disable ejection or to ramp it up slowly. Defaults to 0.
1034 &quot;enforcingConsecutiveGatewayFailure&quot;: 42, # The percentage chance that a host will be actually ejected when an outlier status is detected through consecutive gateway failures. This setting can be used to disable ejection or to ramp it up slowly. Defaults to 100.
1035 &quot;enforcingSuccessRate&quot;: 42, # The percentage chance that a host will be actually ejected when an outlier status is detected through success rate statistics. This setting can be used to disable ejection or to ramp it up slowly. Defaults to 100.
1036 &quot;interval&quot;: { # A Duration represents a fixed-length span of time represented as a count of seconds and fractions of seconds at nanosecond resolution. It is independent of any calendar and concepts like &quot;day&quot; or &quot;month&quot;. Range is approximately 10,000 years. # Time interval between ejection analysis sweeps. This can result in both new ejections as well as hosts being returned to service. Defaults to 1 second.
1037 &quot;nanos&quot;: 42, # Span of time that&#x27;s a fraction of a second at nanosecond resolution. Durations less than one second are represented with a 0 `seconds` field and a positive `nanos` field. Must be from 0 to 999,999,999 inclusive.
1038 &quot;seconds&quot;: &quot;A String&quot;, # Span of time at a resolution of a second. Must be from 0 to 315,576,000,000 inclusive. Note: these bounds are computed from: 60 sec/min * 60 min/hr * 24 hr/day * 365.25 days/year * 10000 years
1039 },
1040 &quot;maxEjectionPercent&quot;: 42, # Maximum percentage of hosts in the load balancing pool for the backend service that can be ejected. Defaults to 50%.
1041 &quot;successRateMinimumHosts&quot;: 42, # The number of hosts in a cluster that must have enough request volume to detect success rate outliers. If the number of hosts is less than this setting, outlier detection via success rate statistics is not performed for any host in the cluster. Defaults to 5.
1042 &quot;successRateRequestVolume&quot;: 42, # The minimum number of total requests that must be collected in one interval (as defined by the interval duration above) to include this host in success rate based outlier detection. If the volume is lower than this setting, outlier detection via success rate statistics is not performed for that host. Defaults to 100.
1043 &quot;successRateStdevFactor&quot;: 42, # This factor is used to determine the ejection threshold for success rate outlier ejection. The ejection threshold is the difference between the mean success rate, and the product of this factor and the standard deviation of the mean success rate: mean - (stdev * success_rate_stdev_factor). This factor is divided by a thousand to get a double. That is, if the desired factor is 1.9, the runtime value should be 1900. Defaults to 1900.
1044 },
1045 &quot;port&quot;: 42, # Deprecated in favor of portName. The TCP port to connect on the backend. The default value is 80.
1046 #
1047 # This cannot be used if the loadBalancingScheme is INTERNAL (Internal TCP/UDP Load Balancing).
1048 &quot;portName&quot;: &quot;A String&quot;, # A named port on a backend instance group representing the port for communication to the backend VMs in that group. Required when the loadBalancingScheme is EXTERNAL, INTERNAL_MANAGED, or INTERNAL_SELF_MANAGED and the backends are instance groups. The named port must be defined on each backend instance group. This parameter has no meaning if the backends are NEGs.
1049 #
1050 #
1051 #
1052 # Must be omitted when the loadBalancingScheme is INTERNAL (Internal TCP/UDP Load Balancing).
1053 &quot;protocol&quot;: &quot;A String&quot;, # The protocol this BackendService uses to communicate with backends.
1054 #
Dmitry Frenkel3e17f892020-10-06 16:46:05 -07001055 # Possible values are HTTP, HTTPS, HTTP2, TCP, SSL, UDP or GRPC. depending on the chosen load balancer or Traffic Director configuration. Refer to the documentation for the load balancer or for Traffic Director for more information.
1056 #
1057 # Must be set to GRPC when the backend service is referenced by a URL map that is bound to target gRPC proxy.
Bu Sun Kim65020912020-05-20 12:08:20 -07001058 &quot;region&quot;: &quot;A String&quot;, # [Output Only] URL of the region where the regional backend service resides. This field is not applicable to global backend services. You must specify this field as part of the HTTP request URL. It is not settable as a field in the request body.
1059 &quot;securityPolicy&quot;: &quot;A String&quot;, # [Output Only] The resource URL for the security policy associated with this backend service.
Bu Sun Kim673ec5c2020-11-16 11:05:03 -07001060 &quot;securitySettings&quot;: { # The authentication and authorization settings for a BackendService. # This field specifies the security policy that applies to this backend service. This field is applicable to either:
1061 # - A regional backend service with the service_protocol set to HTTP, HTTPS, or HTTP2, and load_balancing_scheme set to INTERNAL_MANAGED.
1062 # - A global backend service with the load_balancing_scheme set to INTERNAL_SELF_MANAGED.
1063 &quot;clientTlsPolicy&quot;: &quot;A String&quot;, # Optional. A URL referring to a networksecurity.ClientTlsPolicy resource that describes how clients should authenticate with this service&#x27;s backends.
1064 # clientTlsPolicy only applies to a global BackendService with the loadBalancingScheme set to INTERNAL_SELF_MANAGED.
1065 # If left blank, communications are not encrypted.
1066 # Note: This field currently has no impact.
1067 &quot;subjectAltNames&quot;: [ # Optional. A list of Subject Alternative Names (SANs) that the client verifies during a mutual TLS handshake with an server/endpoint for this BackendService. When the server presents its X.509 certificate to the client, the client inspects the certificate&#x27;s subjectAltName field. If the field contains one of the specified values, the communication continues. Otherwise, it fails. This additional check enables the client to verify that the server is authorized to run the requested service.
1068 # Note that the contents of the server certificate&#x27;s subjectAltName field are configured by the Public Key Infrastructure which provisions server identities.
1069 # Only applies to a global BackendService with loadBalancingScheme set to INTERNAL_SELF_MANAGED. Only applies when BackendService has an attached clientTlsPolicy with clientCertificate (mTLS mode).
1070 # Note: This field currently has no impact.
1071 &quot;A String&quot;,
1072 ],
1073 },
Bu Sun Kim65020912020-05-20 12:08:20 -07001074 &quot;selfLink&quot;: &quot;A String&quot;, # [Output Only] Server-defined URL for the resource.
1075 &quot;sessionAffinity&quot;: &quot;A String&quot;, # Type of session affinity to use. The default is NONE. Session affinity is not applicable if the --protocol is UDP.
1076 #
1077 # When the loadBalancingScheme is EXTERNAL, possible values are NONE, CLIENT_IP, or GENERATED_COOKIE. You can use GENERATED_COOKIE if the protocol is HTTP or HTTPS.
1078 #
1079 # When the loadBalancingScheme is INTERNAL, possible values are NONE, CLIENT_IP, CLIENT_IP_PROTO, or CLIENT_IP_PORT_PROTO.
1080 #
1081 # When the loadBalancingScheme is INTERNAL_SELF_MANAGED, or INTERNAL_MANAGED, possible values are NONE, CLIENT_IP, GENERATED_COOKIE, HEADER_FIELD, or HTTP_COOKIE.
Dmitry Frenkel3e17f892020-10-06 16:46:05 -07001082 #
1083 # Not supported when the backend service is referenced by a URL map that is bound to target gRPC proxy that has validateForProxyless field set to true.
Bu Sun Kimd059ad82020-07-22 17:02:09 -07001084 &quot;timeoutSec&quot;: 42, # The backend service timeout has a different meaning depending on the type of load balancer. For more information see, Backend service settings The default is 30 seconds.
Bu Sun Kim65020912020-05-20 12:08:20 -07001085 },
Jon Wayne Parrott692617a2017-01-06 09:58:29 -08001086 ],
Bu Sun Kim65020912020-05-20 12:08:20 -07001087 &quot;kind&quot;: &quot;compute#backendServiceList&quot;, # [Output Only] Type of resource. Always compute#backendServiceList for lists of backend services.
1088 &quot;nextPageToken&quot;: &quot;A String&quot;, # [Output Only] This token allows you to get the next page of results for list requests. If the number of results is larger than maxResults, use the nextPageToken as a value for the query parameter pageToken in the next list request. Subsequent list requests will have their own nextPageToken to continue paging through the results.
1089 &quot;selfLink&quot;: &quot;A String&quot;, # [Output Only] Server-defined URL for this resource.
1090 &quot;warning&quot;: { # [Output Only] Informational warning message.
1091 &quot;code&quot;: &quot;A String&quot;, # [Output Only] A warning code, if applicable. For example, Compute Engine returns NO_RESULTS_ON_PAGE if there are no results in the response.
1092 &quot;data&quot;: [ # [Output Only] Metadata about this warning in key: value format. For example:
1093 # &quot;data&quot;: [ { &quot;key&quot;: &quot;scope&quot;, &quot;value&quot;: &quot;zones/us-east1-d&quot; }
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001094 {
Bu Sun Kim65020912020-05-20 12:08:20 -07001095 &quot;key&quot;: &quot;A String&quot;, # [Output Only] A key that provides more detail on the warning being returned. For example, for warnings where there are no results in a list request for a particular zone, this key might be scope and the key value might be the zone name. Other examples might be a key indicating a deprecated resource and a suggested replacement, or a warning about invalid network settings (for example, if an instance attempts to perform IP forwarding but is not enabled for IP forwarding).
1096 &quot;value&quot;: &quot;A String&quot;, # [Output Only] A warning data value corresponding to the key.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001097 },
1098 ],
Bu Sun Kim65020912020-05-20 12:08:20 -07001099 &quot;message&quot;: &quot;A String&quot;, # [Output Only] A human-readable description of the warning code.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001100 },
Jon Wayne Parrott692617a2017-01-06 09:58:29 -08001101 }</pre>
1102</div>
1103
1104<div class="method">
1105 <code class="details" id="list_next">list_next(previous_request, previous_response)</code>
1106 <pre>Retrieves the next page of results.
1107
1108Args:
1109 previous_request: The request for the previous page. (required)
1110 previous_response: The response from the request for the previous page. (required)
1111
1112Returns:
Bu Sun Kim65020912020-05-20 12:08:20 -07001113 A request object that you can call &#x27;execute()&#x27; on to request the next
Jon Wayne Parrott692617a2017-01-06 09:58:29 -08001114 page. Returns None if there are no more items in the collection.
1115 </pre>
1116</div>
1117
1118<div class="method">
Dan O'Mearadd494642020-05-01 07:42:23 -07001119 <code class="details" id="patch">patch(project, region, backendService, body=None, requestId=None)</code>
Bu Sun Kimd059ad82020-07-22 17:02:09 -07001120 <pre>Updates the specified regional BackendService resource with the data included in the request. For more information, see Understanding backend services This method supports PATCH semantics and uses the JSON merge patch format and processing rules.
Jon Wayne Parrott692617a2017-01-06 09:58:29 -08001121
1122Args:
1123 project: string, Project ID for this request. (required)
1124 region: string, Name of the region scoping this request. (required)
Sai Cheemalapati4ba8c232017-06-06 18:46:08 -04001125 backendService: string, Name of the BackendService resource to patch. (required)
Dan O'Mearadd494642020-05-01 07:42:23 -07001126 body: object, The request body.
Jon Wayne Parrott692617a2017-01-06 09:58:29 -08001127 The object takes the form of:
1128
Dan O'Mearadd494642020-05-01 07:42:23 -07001129{ # Represents a Backend Service resource.
Bu Sun Kim65020912020-05-20 12:08:20 -07001130 #
Bu Sun Kimd059ad82020-07-22 17:02:09 -07001131 # A backend service defines how Google Cloud load balancers distribute traffic. The backend service configuration contains a set of values, such as the protocol used to connect to backends, various distribution and session settings, health checks, and timeouts. These settings provide fine-grained control over how your load balancer behaves. Most of the settings have default values that allow for easy configuration if you need to get started quickly.
Bu Sun Kim65020912020-05-20 12:08:20 -07001132 #
1133 # Backend services in Google Compute Engine can be either regionally or globally scoped.
1134 #
1135 # * [Global](/compute/docs/reference/rest/{$api_version}/backendServices) * [Regional](/compute/docs/reference/rest/{$api_version}/regionBackendServices)
1136 #
Bu Sun Kimd059ad82020-07-22 17:02:09 -07001137 # For more information, see Backend Services.
Bu Sun Kim65020912020-05-20 12:08:20 -07001138 #
1139 # (== resource_for {$api_version}.backendService ==)
Dmitry Frenkel3e17f892020-10-06 16:46:05 -07001140 &quot;affinityCookieTtlSec&quot;: 42, # Lifetime of cookies in seconds. Only applicable if the loadBalancingScheme is EXTERNAL, INTERNAL_SELF_MANAGED, or INTERNAL_MANAGED, the protocol is HTTP or HTTPS, and the sessionAffinity is GENERATED_COOKIE, or HTTP_COOKIE.
1141 #
1142 # If set to 0, the cookie is non-persistent and lasts only until the end of the browser session (or equivalent). The maximum allowed value is one day (86,400).
1143 #
1144 # Not supported when the backend service is referenced by a URL map that is bound to target gRPC proxy that has validateForProxyless field set to true.
Bu Sun Kim65020912020-05-20 12:08:20 -07001145 &quot;backends&quot;: [ # The list of backends that serve this BackendService.
1146 { # Message containing information of one individual backend.
1147 &quot;balancingMode&quot;: &quot;A String&quot;, # Specifies the balancing mode for the backend.
1148 #
1149 # When choosing a balancing mode, you need to consider the loadBalancingScheme, and protocol for the backend service, as well as the type of backend (instance group or NEG).
1150 #
1151 #
1152 # - If the load balancing mode is CONNECTION, then the load is spread based on how many concurrent connections the backend can handle.
1153 # You can use the CONNECTION balancing mode if the protocol for the backend service is SSL, TCP, or UDP.
1154 #
1155 # If the loadBalancingScheme for the backend service is EXTERNAL (SSL Proxy and TCP Proxy load balancers), you must also specify exactly one of the following parameters: maxConnections (except for regional managed instance groups), maxConnectionsPerInstance, or maxConnectionsPerEndpoint.
1156 #
1157 # If the loadBalancingScheme for the backend service is INTERNAL (internal TCP/UDP load balancers), you cannot specify any additional parameters.
1158 #
1159 # - If the load balancing mode is RATE, the load is spread based on the rate of HTTP requests per second (RPS).
1160 # You can use the RATE balancing mode if the protocol for the backend service is HTTP or HTTPS. You must specify exactly one of the following parameters: maxRate (except for regional managed instance groups), maxRatePerInstance, or maxRatePerEndpoint.
1161 #
1162 # - If the load balancing mode is UTILIZATION, the load is spread based on the backend utilization of instances in an instance group.
1163 # You can use the UTILIZATION balancing mode if the loadBalancingScheme of the backend service is EXTERNAL, INTERNAL_SELF_MANAGED, or INTERNAL_MANAGED and the backends are instance groups. There are no restrictions on the backend service protocol.
Bu Sun Kimd059ad82020-07-22 17:02:09 -07001164 &quot;capacityScaler&quot;: 3.14, # A multiplier applied to the group&#x27;s maximum servicing capacity (based on UTILIZATION, RATE or CONNECTION). Default value is 1, which means the group will serve up to 100% of its configured capacity (depending on balancingMode). A setting of 0 means the group is completely drained, offering 0% of its available capacity. Valid range is 0.0 and [0.1,1.0]. You cannot configure a setting larger than 0 and smaller than 0.1. You cannot configure a setting of 0 when there is only one backend attached to the backend service.
Bu Sun Kim65020912020-05-20 12:08:20 -07001165 #
1166 # This cannot be used for internal load balancing.
1167 &quot;description&quot;: &quot;A String&quot;, # An optional description of this resource. Provide this property when you create the resource.
1168 &quot;failover&quot;: True or False, # This field designates whether this is a failover backend. More than one failover backend can be configured for a given BackendService.
1169 &quot;group&quot;: &quot;A String&quot;, # The fully-qualified URL of an instance group or network endpoint group (NEG) resource. The type of backend that a backend service supports depends on the backend service&#x27;s loadBalancingScheme.
1170 #
1171 #
1172 # - When the loadBalancingScheme for the backend service is EXTERNAL, INTERNAL_SELF_MANAGED, or INTERNAL_MANAGED, the backend can be either an instance group or a NEG. The backends on the backend service must be either all instance groups or all NEGs. You cannot mix instance group and NEG backends on the same backend service.
1173 #
1174 #
1175 # - When the loadBalancingScheme for the backend service is INTERNAL, the backend must be an instance group in the same region as the backend service. NEGs are not supported.
1176 #
1177 # You must use the fully-qualified URL (starting with https://www.googleapis.com/) to specify the instance group or NEG. Partial URLs are not supported.
1178 &quot;maxConnections&quot;: 42, # Defines a target maximum number of simultaneous connections that the backend can handle. Valid for network endpoint group and instance group backends (except for regional managed instance groups). If the backend&#x27;s balancingMode is UTILIZATION, this is an optional parameter. If the backend&#x27;s balancingMode is CONNECTION, and backend is attached to a backend service whose loadBalancingScheme is EXTERNAL, you must specify either this parameter, maxConnectionsPerInstance, or maxConnectionsPerEndpoint.
1179 #
1180 # Not available if the backend&#x27;s balancingMode is RATE. If the loadBalancingScheme is INTERNAL, then maxConnections is not supported, even though the backend requires a balancing mode of CONNECTION.
1181 &quot;maxConnectionsPerEndpoint&quot;: 42, # Defines a target maximum number of simultaneous connections for an endpoint of a NEG. This is multiplied by the number of endpoints in the NEG to implicitly calculate a maximum number of target maximum simultaneous connections for the NEG. If the backend&#x27;s balancingMode is CONNECTION, and the backend is attached to a backend service whose loadBalancingScheme is EXTERNAL, you must specify either this parameter, maxConnections, or maxConnectionsPerInstance.
1182 #
1183 # Not available if the backend&#x27;s balancingMode is RATE. Internal TCP/UDP load balancing does not support setting maxConnectionsPerEndpoint even though its backends require a balancing mode of CONNECTION.
1184 &quot;maxConnectionsPerInstance&quot;: 42, # Defines a target maximum number of simultaneous connections for a single VM in a backend instance group. This is multiplied by the number of instances in the instance group to implicitly calculate a target maximum number of simultaneous connections for the whole instance group. If the backend&#x27;s balancingMode is UTILIZATION, this is an optional parameter. If the backend&#x27;s balancingMode is CONNECTION, and backend is attached to a backend service whose loadBalancingScheme is EXTERNAL, you must specify either this parameter, maxConnections, or maxConnectionsPerEndpoint.
1185 #
1186 # Not available if the backend&#x27;s balancingMode is RATE. Internal TCP/UDP load balancing does not support setting maxConnectionsPerInstance even though its backends require a balancing mode of CONNECTION.
1187 &quot;maxRate&quot;: 42, # Defines a maximum number of HTTP requests per second (RPS) that the backend can handle. Valid for network endpoint group and instance group backends (except for regional managed instance groups). Must not be defined if the backend is a managed instance group that uses autoscaling based on load balancing.
1188 #
1189 # If the backend&#x27;s balancingMode is UTILIZATION, this is an optional parameter. If the backend&#x27;s balancingMode is RATE, you must specify maxRate, maxRatePerInstance, or maxRatePerEndpoint.
1190 #
1191 # Not available if the backend&#x27;s balancingMode is CONNECTION.
1192 &quot;maxRatePerEndpoint&quot;: 3.14, # Defines a maximum target for requests per second (RPS) for an endpoint of a NEG. This is multiplied by the number of endpoints in the NEG to implicitly calculate a target maximum rate for the NEG.
1193 #
1194 # If the backend&#x27;s balancingMode is RATE, you must specify either this parameter, maxRate (except for regional managed instance groups), or maxRatePerInstance.
1195 #
1196 # Not available if the backend&#x27;s balancingMode is CONNECTION.
1197 &quot;maxRatePerInstance&quot;: 3.14, # Defines a maximum target for requests per second (RPS) for a single VM in a backend instance group. This is multiplied by the number of instances in the instance group to implicitly calculate a target maximum rate for the whole instance group.
1198 #
1199 # If the backend&#x27;s balancingMode is UTILIZATION, this is an optional parameter. If the backend&#x27;s balancingMode is RATE, you must specify either this parameter, maxRate (except for regional managed instance groups), or maxRatePerEndpoint.
1200 #
1201 # Not available if the backend&#x27;s balancingMode is CONNECTION.
1202 &quot;maxUtilization&quot;: 3.14, # Defines the maximum average backend utilization of a backend VM in an instance group. The valid range is [0.0, 1.0]. This is an optional parameter if the backend&#x27;s balancingMode is UTILIZATION.
1203 #
1204 # This parameter can be used in conjunction with maxRate, maxRatePerInstance, maxConnections (except for regional managed instance groups), or maxConnectionsPerInstance.
Jon Wayne Parrott692617a2017-01-06 09:58:29 -08001205 },
Bu Sun Kim65020912020-05-20 12:08:20 -07001206 ],
1207 &quot;cdnPolicy&quot;: { # Message containing Cloud CDN configuration for a backend service. # Cloud CDN configuration for this BackendService.
1208 &quot;cacheKeyPolicy&quot;: { # Message containing what to include in the cache key for a request for Cloud CDN. # The CacheKeyPolicy for this CdnPolicy.
1209 &quot;includeHost&quot;: True or False, # If true, requests to different hosts will be cached separately.
1210 &quot;includeProtocol&quot;: True or False, # If true, http and https requests will be cached separately.
1211 &quot;includeQueryString&quot;: True or False, # If true, include query string parameters in the cache key according to query_string_whitelist and query_string_blacklist. If neither is set, the entire query string will be included. If false, the query string will be excluded from the cache key entirely.
1212 &quot;queryStringBlacklist&quot;: [ # Names of query string parameters to exclude in cache keys. All other parameters will be included. Either specify query_string_whitelist or query_string_blacklist, not both. &#x27;&amp;&#x27; and &#x27;=&#x27; will be percent encoded and not treated as delimiters.
1213 &quot;A String&quot;,
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001214 ],
Bu Sun Kim65020912020-05-20 12:08:20 -07001215 &quot;queryStringWhitelist&quot;: [ # Names of query string parameters to include in cache keys. All other parameters will be excluded. Either specify query_string_whitelist or query_string_blacklist, not both. &#x27;&amp;&#x27; and &#x27;=&#x27; will be percent encoded and not treated as delimiters.
1216 &quot;A String&quot;,
1217 ],
Sai Cheemalapati4ba8c232017-06-06 18:46:08 -04001218 },
Bu Sun Kim65020912020-05-20 12:08:20 -07001219 &quot;signedUrlCacheMaxAgeSec&quot;: &quot;A String&quot;, # Maximum number of seconds the response to a signed URL request will be considered fresh. After this time period, the response will be revalidated before being served. Defaults to 1hr (3600s). When serving responses to signed URL requests, Cloud CDN will internally behave as though all responses from this backend had a &quot;Cache-Control: public, max-age=[TTL]&quot; header, regardless of any existing Cache-Control header. The actual headers served in responses will not be altered.
1220 &quot;signedUrlKeyNames&quot;: [ # [Output Only] Names of the keys for signing request URLs.
1221 &quot;A String&quot;,
Jon Wayne Parrott692617a2017-01-06 09:58:29 -08001222 ],
Bu Sun Kim65020912020-05-20 12:08:20 -07001223 },
1224 &quot;circuitBreakers&quot;: { # Settings controlling the volume of connections to a backend service. # Settings controlling the volume of connections to a backend service. If not set, this feature is considered disabled.
1225 #
1226 # This field is applicable to either:
1227 # - A regional backend service with the service_protocol set to HTTP, HTTPS, or HTTP2, and load_balancing_scheme set to INTERNAL_MANAGED.
1228 # - A global backend service with the load_balancing_scheme set to INTERNAL_SELF_MANAGED.
Dmitry Frenkel3e17f892020-10-06 16:46:05 -07001229 #
1230 # Not supported when the backend service is referenced by a URL map that is bound to target gRPC proxy that has validateForProxyless field set to true.
Bu Sun Kim65020912020-05-20 12:08:20 -07001231 &quot;maxConnections&quot;: 42, # The maximum number of connections to the backend service. If not specified, there is no limit.
1232 &quot;maxPendingRequests&quot;: 42, # The maximum number of pending requests allowed to the backend service. If not specified, there is no limit.
1233 &quot;maxRequests&quot;: 42, # The maximum number of parallel requests that allowed to the backend service. If not specified, there is no limit.
1234 &quot;maxRequestsPerConnection&quot;: 42, # Maximum requests for a single connection to the backend service. This parameter is respected by both the HTTP/1.1 and HTTP/2 implementations. If not specified, there is no limit. Setting this parameter to 1 will effectively disable keep alive.
1235 &quot;maxRetries&quot;: 42, # The maximum number of parallel retries allowed to the backend cluster. If not specified, the default is 1.
1236 },
1237 &quot;connectionDraining&quot;: { # Message containing connection draining configuration.
1238 &quot;drainingTimeoutSec&quot;: 42, # The amount of time in seconds to allow existing connections to persist while on unhealthy backend VMs. Only applicable if the protocol is not UDP. The valid range is [0, 3600].
1239 },
1240 &quot;consistentHash&quot;: { # This message defines settings for a consistent hash style load balancer. # Consistent Hash-based load balancing can be used to provide soft session affinity based on HTTP headers, cookies or other properties. This load balancing policy is applicable only for HTTP connections. The affinity to a particular destination host will be lost when one or more hosts are added/removed from the destination service. This field specifies parameters that control consistent hashing. This field is only applicable when localityLbPolicy is set to MAGLEV or RING_HASH.
1241 #
1242 # This field is applicable to either:
1243 # - A regional backend service with the service_protocol set to HTTP, HTTPS, or HTTP2, and load_balancing_scheme set to INTERNAL_MANAGED.
1244 # - A global backend service with the load_balancing_scheme set to INTERNAL_SELF_MANAGED.
Dmitry Frenkel3e17f892020-10-06 16:46:05 -07001245 #
1246 # Not supported when the backend service is referenced by a URL map that is bound to target gRPC proxy that has validateForProxyless field set to true.
Bu Sun Kim65020912020-05-20 12:08:20 -07001247 &quot;httpCookie&quot;: { # The information about the HTTP Cookie on which the hash function is based for load balancing policies that use a consistent hash. # Hash is based on HTTP Cookie. This field describes a HTTP cookie that will be used as the hash key for the consistent hash load balancer. If the cookie is not present, it will be generated. This field is applicable if the sessionAffinity is set to HTTP_COOKIE.
1248 &quot;name&quot;: &quot;A String&quot;, # Name of the cookie.
1249 &quot;path&quot;: &quot;A String&quot;, # Path to set for the cookie.
1250 &quot;ttl&quot;: { # A Duration represents a fixed-length span of time represented as a count of seconds and fractions of seconds at nanosecond resolution. It is independent of any calendar and concepts like &quot;day&quot; or &quot;month&quot;. Range is approximately 10,000 years. # Lifetime of the cookie.
1251 &quot;nanos&quot;: 42, # Span of time that&#x27;s a fraction of a second at nanosecond resolution. Durations less than one second are represented with a 0 `seconds` field and a positive `nanos` field. Must be from 0 to 999,999,999 inclusive.
1252 &quot;seconds&quot;: &quot;A String&quot;, # Span of time at a resolution of a second. Must be from 0 to 315,576,000,000 inclusive. Note: these bounds are computed from: 60 sec/min * 60 min/hr * 24 hr/day * 365.25 days/year * 10000 years
1253 },
Sai Cheemalapati4ba8c232017-06-06 18:46:08 -04001254 },
Bu Sun Kim65020912020-05-20 12:08:20 -07001255 &quot;httpHeaderName&quot;: &quot;A String&quot;, # The hash based on the value of the specified header field. This field is applicable if the sessionAffinity is set to HEADER_FIELD.
1256 &quot;minimumRingSize&quot;: &quot;A String&quot;, # The minimum number of virtual nodes to use for the hash ring. Defaults to 1024. Larger ring sizes result in more granular load distributions. If the number of hosts in the load balancing pool is larger than the ring size, each host will be assigned a single virtual node.
1257 },
1258 &quot;creationTimestamp&quot;: &quot;A String&quot;, # [Output Only] Creation timestamp in RFC3339 text format.
1259 &quot;customRequestHeaders&quot;: [ # Headers that the HTTP/S load balancer should add to proxied requests.
1260 &quot;A String&quot;,
1261 ],
1262 &quot;description&quot;: &quot;A String&quot;, # An optional description of this resource. Provide this property when you create the resource.
1263 &quot;enableCDN&quot;: True or False, # If true, enables Cloud CDN for the backend service. Only applicable if the loadBalancingScheme is EXTERNAL and the protocol is HTTP or HTTPS.
1264 &quot;failoverPolicy&quot;: { # Applicable only to Failover for Internal TCP/UDP Load Balancing. On failover or failback, this field indicates whether connection draining will be honored. GCP has a fixed connection draining timeout of 10 minutes. A setting of true terminates existing TCP connections to the active pool during failover and failback, immediately draining traffic. A setting of false allows existing TCP connections to persist, even on VMs no longer in the active pool, for up to the duration of the connection draining timeout (10 minutes). # Applicable only to Failover for Internal TCP/UDP Load Balancing. Requires at least one backend instance group to be defined as a backup (failover) backend.
1265 &quot;disableConnectionDrainOnFailover&quot;: True or False, # This can be set to true only if the protocol is TCP.
1266 #
1267 # The default is false.
1268 &quot;dropTrafficIfUnhealthy&quot;: True or False, # Applicable only to Failover for Internal TCP/UDP Load Balancing. If set to true, connections to the load balancer are dropped when all primary and all backup backend VMs are unhealthy. If set to false, connections are distributed among all primary VMs when all primary and all backup backend VMs are unhealthy.
1269 #
1270 # The default is false.
1271 &quot;failoverRatio&quot;: 3.14, # Applicable only to Failover for Internal TCP/UDP Load Balancing. The value of the field must be in the range [0, 1]. If the value is 0, the load balancer performs a failover when the number of healthy primary VMs equals zero. For all other values, the load balancer performs a failover when the total number of healthy primary VMs is less than this ratio.
1272 },
1273 &quot;fingerprint&quot;: &quot;A String&quot;, # Fingerprint of this resource. A hash of the contents stored in this object. This field is used in optimistic locking. This field will be ignored when inserting a BackendService. An up-to-date fingerprint must be provided in order to update the BackendService, otherwise the request will fail with error 412 conditionNotMet.
1274 #
1275 # To see the latest fingerprint, make a get() request to retrieve a BackendService.
Dmitry Frenkel3e17f892020-10-06 16:46:05 -07001276 &quot;healthChecks&quot;: [ # The list of URLs to the healthChecks, httpHealthChecks (legacy), or httpsHealthChecks (legacy) resource for health checking this backend service. Not all backend services support legacy health checks. See Load balancer guide. Currently, at most one health check can be specified for each backend service. Backend services with instance group or zonal NEG backends must have a health check. Backend services with internet or serverless NEG backends must not have a health check.
Bu Sun Kim65020912020-05-20 12:08:20 -07001277 &quot;A String&quot;,
1278 ],
Bu Sun Kimd059ad82020-07-22 17:02:09 -07001279 &quot;iap&quot;: { # Identity-Aware Proxy # The configurations for Identity-Aware Proxy on this resource.
1280 &quot;enabled&quot;: True or False, # Whether the serving infrastructure will authenticate and authorize all incoming requests. If true, the oauth2ClientId and oauth2ClientSecret fields must be non-empty.
1281 &quot;oauth2ClientId&quot;: &quot;A String&quot;, # OAuth2 client ID to use for the authentication flow.
1282 &quot;oauth2ClientSecret&quot;: &quot;A String&quot;, # OAuth2 client secret to use for the authentication flow. For security reasons, this value cannot be retrieved via the API. Instead, the SHA-256 hash of the value is returned in the oauth2ClientSecretSha256 field.
Bu Sun Kim65020912020-05-20 12:08:20 -07001283 &quot;oauth2ClientSecretSha256&quot;: &quot;A String&quot;, # [Output Only] SHA256 hash value for the field oauth2_client_secret above.
1284 },
1285 &quot;id&quot;: &quot;A String&quot;, # [Output Only] The unique identifier for the resource. This identifier is defined by the server.
1286 &quot;kind&quot;: &quot;compute#backendService&quot;, # [Output Only] Type of resource. Always compute#backendService for backend services.
1287 &quot;loadBalancingScheme&quot;: &quot;A String&quot;, # Specifies the load balancer type. Choose EXTERNAL for load balancers that receive traffic from external clients. Choose INTERNAL for Internal TCP/UDP Load Balancing. Choose INTERNAL_MANAGED for Internal HTTP(S) Load Balancing. Choose INTERNAL_SELF_MANAGED for Traffic Director. A backend service created for one type of load balancing cannot be used with another. For more information, refer to Choosing a load balancer.
1288 &quot;localityLbPolicy&quot;: &quot;A String&quot;, # The load balancing algorithm used within the scope of the locality. The possible values are:
1289 # - ROUND_ROBIN: This is a simple policy in which each healthy backend is selected in round robin order. This is the default.
1290 # - LEAST_REQUEST: An O(1) algorithm which selects two random healthy hosts and picks the host which has fewer active requests.
1291 # - RING_HASH: The ring/modulo hash load balancer implements consistent hashing to backends. The algorithm has the property that the addition/removal of a host from a set of N hosts only affects 1/N of the requests.
1292 # - RANDOM: The load balancer selects a random healthy host.
1293 # - ORIGINAL_DESTINATION: Backend host is selected based on the client connection metadata, i.e., connections are opened to the same address as the destination address of the incoming connection before the connection was redirected to the load balancer.
Bu Sun Kimd059ad82020-07-22 17:02:09 -07001294 # - MAGLEV: used as a drop in replacement for the ring hash load balancer. Maglev is not as stable as ring hash but has faster table lookup build times and host selection times. For more information about Maglev, see https://ai.google/research/pubs/pub44824
Bu Sun Kim65020912020-05-20 12:08:20 -07001295 #
1296 # This field is applicable to either:
1297 # - A regional backend service with the service_protocol set to HTTP, HTTPS, or HTTP2, and load_balancing_scheme set to INTERNAL_MANAGED.
1298 # - A global backend service with the load_balancing_scheme set to INTERNAL_SELF_MANAGED.
1299 #
Dmitry Frenkel3e17f892020-10-06 16:46:05 -07001300 # If sessionAffinity is not NONE, and this field is not set to MAGLEV or RING_HASH, session affinity settings will not take effect.
1301 #
1302 # Only the default ROUND_ROBIN policy is supported when the backend service is referenced by a URL map that is bound to target gRPC proxy that has validateForProxyless field set to true.
Bu Sun Kim65020912020-05-20 12:08:20 -07001303 &quot;logConfig&quot;: { # The available logging options for the load balancer traffic served by this backend service. # This field denotes the logging options for the load balancer traffic served by this backend service. If logging is enabled, logs will be exported to Stackdriver.
1304 &quot;enable&quot;: True or False, # This field denotes whether to enable logging for the load balancer traffic served by this backend service.
1305 &quot;sampleRate&quot;: 3.14, # This field can only be specified if logging is enabled for this backend service. The value of the field must be in [0, 1]. This configures the sampling rate of requests to the load balancer where 1.0 means all logged requests are reported and 0.0 means no logged requests are reported. The default value is 1.0.
1306 },
1307 &quot;name&quot;: &quot;A String&quot;, # Name of the resource. Provided by the client when the resource is created. The name must be 1-63 characters long, and comply with RFC1035. Specifically, the name must be 1-63 characters long and match the regular expression `[a-z]([-a-z0-9]*[a-z0-9])?` which means the first character must be a lowercase letter, and all following characters must be a dash, lowercase letter, or digit, except the last character, which cannot be a dash.
1308 &quot;network&quot;: &quot;A String&quot;, # The URL of the network to which this backend service belongs. This field can only be spcified when the load balancing scheme is set to INTERNAL.
1309 &quot;outlierDetection&quot;: { # Settings controlling the eviction of unhealthy hosts from the load balancing pool for the backend service. # Settings controlling the eviction of unhealthy hosts from the load balancing pool for the backend service. If not set, this feature is considered disabled.
1310 #
1311 # This field is applicable to either:
1312 # - A regional backend service with the service_protocol set to HTTP, HTTPS, or HTTP2, and load_balancing_scheme set to INTERNAL_MANAGED.
1313 # - A global backend service with the load_balancing_scheme set to INTERNAL_SELF_MANAGED.
Dmitry Frenkel3e17f892020-10-06 16:46:05 -07001314 #
1315 # Not supported when the backend service is referenced by a URL map that is bound to target gRPC proxy that has validateForProxyless field set to true.
Bu Sun Kim65020912020-05-20 12:08:20 -07001316 &quot;baseEjectionTime&quot;: { # A Duration represents a fixed-length span of time represented as a count of seconds and fractions of seconds at nanosecond resolution. It is independent of any calendar and concepts like &quot;day&quot; or &quot;month&quot;. Range is approximately 10,000 years. # The base time that a host is ejected for. The real ejection time is equal to the base ejection time multiplied by the number of times the host has been ejected. Defaults to 30000ms or 30s.
1317 &quot;nanos&quot;: 42, # Span of time that&#x27;s a fraction of a second at nanosecond resolution. Durations less than one second are represented with a 0 `seconds` field and a positive `nanos` field. Must be from 0 to 999,999,999 inclusive.
1318 &quot;seconds&quot;: &quot;A String&quot;, # Span of time at a resolution of a second. Must be from 0 to 315,576,000,000 inclusive. Note: these bounds are computed from: 60 sec/min * 60 min/hr * 24 hr/day * 365.25 days/year * 10000 years
Dan O'Mearadd494642020-05-01 07:42:23 -07001319 },
Bu Sun Kim65020912020-05-20 12:08:20 -07001320 &quot;consecutiveErrors&quot;: 42, # Number of errors before a host is ejected from the connection pool. When the backend host is accessed over HTTP, a 5xx return code qualifies as an error. Defaults to 5.
1321 &quot;consecutiveGatewayFailure&quot;: 42, # The number of consecutive gateway failures (502, 503, 504 status or connection errors that are mapped to one of those status codes) before a consecutive gateway failure ejection occurs. Defaults to 3.
1322 &quot;enforcingConsecutiveErrors&quot;: 42, # The percentage chance that a host will be actually ejected when an outlier status is detected through consecutive 5xx. This setting can be used to disable ejection or to ramp it up slowly. Defaults to 0.
1323 &quot;enforcingConsecutiveGatewayFailure&quot;: 42, # The percentage chance that a host will be actually ejected when an outlier status is detected through consecutive gateway failures. This setting can be used to disable ejection or to ramp it up slowly. Defaults to 100.
1324 &quot;enforcingSuccessRate&quot;: 42, # The percentage chance that a host will be actually ejected when an outlier status is detected through success rate statistics. This setting can be used to disable ejection or to ramp it up slowly. Defaults to 100.
1325 &quot;interval&quot;: { # A Duration represents a fixed-length span of time represented as a count of seconds and fractions of seconds at nanosecond resolution. It is independent of any calendar and concepts like &quot;day&quot; or &quot;month&quot;. Range is approximately 10,000 years. # Time interval between ejection analysis sweeps. This can result in both new ejections as well as hosts being returned to service. Defaults to 1 second.
1326 &quot;nanos&quot;: 42, # Span of time that&#x27;s a fraction of a second at nanosecond resolution. Durations less than one second are represented with a 0 `seconds` field and a positive `nanos` field. Must be from 0 to 999,999,999 inclusive.
1327 &quot;seconds&quot;: &quot;A String&quot;, # Span of time at a resolution of a second. Must be from 0 to 315,576,000,000 inclusive. Note: these bounds are computed from: 60 sec/min * 60 min/hr * 24 hr/day * 365.25 days/year * 10000 years
Dan O'Mearadd494642020-05-01 07:42:23 -07001328 },
Bu Sun Kim65020912020-05-20 12:08:20 -07001329 &quot;maxEjectionPercent&quot;: 42, # Maximum percentage of hosts in the load balancing pool for the backend service that can be ejected. Defaults to 50%.
1330 &quot;successRateMinimumHosts&quot;: 42, # The number of hosts in a cluster that must have enough request volume to detect success rate outliers. If the number of hosts is less than this setting, outlier detection via success rate statistics is not performed for any host in the cluster. Defaults to 5.
1331 &quot;successRateRequestVolume&quot;: 42, # The minimum number of total requests that must be collected in one interval (as defined by the interval duration above) to include this host in success rate based outlier detection. If the volume is lower than this setting, outlier detection via success rate statistics is not performed for that host. Defaults to 100.
1332 &quot;successRateStdevFactor&quot;: 42, # This factor is used to determine the ejection threshold for success rate outlier ejection. The ejection threshold is the difference between the mean success rate, and the product of this factor and the standard deviation of the mean success rate: mean - (stdev * success_rate_stdev_factor). This factor is divided by a thousand to get a double. That is, if the desired factor is 1.9, the runtime value should be 1900. Defaults to 1900.
1333 },
1334 &quot;port&quot;: 42, # Deprecated in favor of portName. The TCP port to connect on the backend. The default value is 80.
1335 #
1336 # This cannot be used if the loadBalancingScheme is INTERNAL (Internal TCP/UDP Load Balancing).
1337 &quot;portName&quot;: &quot;A String&quot;, # A named port on a backend instance group representing the port for communication to the backend VMs in that group. Required when the loadBalancingScheme is EXTERNAL, INTERNAL_MANAGED, or INTERNAL_SELF_MANAGED and the backends are instance groups. The named port must be defined on each backend instance group. This parameter has no meaning if the backends are NEGs.
1338 #
1339 #
1340 #
1341 # Must be omitted when the loadBalancingScheme is INTERNAL (Internal TCP/UDP Load Balancing).
1342 &quot;protocol&quot;: &quot;A String&quot;, # The protocol this BackendService uses to communicate with backends.
1343 #
Dmitry Frenkel3e17f892020-10-06 16:46:05 -07001344 # Possible values are HTTP, HTTPS, HTTP2, TCP, SSL, UDP or GRPC. depending on the chosen load balancer or Traffic Director configuration. Refer to the documentation for the load balancer or for Traffic Director for more information.
1345 #
1346 # Must be set to GRPC when the backend service is referenced by a URL map that is bound to target gRPC proxy.
Bu Sun Kim65020912020-05-20 12:08:20 -07001347 &quot;region&quot;: &quot;A String&quot;, # [Output Only] URL of the region where the regional backend service resides. This field is not applicable to global backend services. You must specify this field as part of the HTTP request URL. It is not settable as a field in the request body.
1348 &quot;securityPolicy&quot;: &quot;A String&quot;, # [Output Only] The resource URL for the security policy associated with this backend service.
Bu Sun Kim673ec5c2020-11-16 11:05:03 -07001349 &quot;securitySettings&quot;: { # The authentication and authorization settings for a BackendService. # This field specifies the security policy that applies to this backend service. This field is applicable to either:
1350 # - A regional backend service with the service_protocol set to HTTP, HTTPS, or HTTP2, and load_balancing_scheme set to INTERNAL_MANAGED.
1351 # - A global backend service with the load_balancing_scheme set to INTERNAL_SELF_MANAGED.
1352 &quot;clientTlsPolicy&quot;: &quot;A String&quot;, # Optional. A URL referring to a networksecurity.ClientTlsPolicy resource that describes how clients should authenticate with this service&#x27;s backends.
1353 # clientTlsPolicy only applies to a global BackendService with the loadBalancingScheme set to INTERNAL_SELF_MANAGED.
1354 # If left blank, communications are not encrypted.
1355 # Note: This field currently has no impact.
1356 &quot;subjectAltNames&quot;: [ # Optional. A list of Subject Alternative Names (SANs) that the client verifies during a mutual TLS handshake with an server/endpoint for this BackendService. When the server presents its X.509 certificate to the client, the client inspects the certificate&#x27;s subjectAltName field. If the field contains one of the specified values, the communication continues. Otherwise, it fails. This additional check enables the client to verify that the server is authorized to run the requested service.
1357 # Note that the contents of the server certificate&#x27;s subjectAltName field are configured by the Public Key Infrastructure which provisions server identities.
1358 # Only applies to a global BackendService with loadBalancingScheme set to INTERNAL_SELF_MANAGED. Only applies when BackendService has an attached clientTlsPolicy with clientCertificate (mTLS mode).
1359 # Note: This field currently has no impact.
1360 &quot;A String&quot;,
1361 ],
1362 },
Bu Sun Kim65020912020-05-20 12:08:20 -07001363 &quot;selfLink&quot;: &quot;A String&quot;, # [Output Only] Server-defined URL for the resource.
1364 &quot;sessionAffinity&quot;: &quot;A String&quot;, # Type of session affinity to use. The default is NONE. Session affinity is not applicable if the --protocol is UDP.
1365 #
1366 # When the loadBalancingScheme is EXTERNAL, possible values are NONE, CLIENT_IP, or GENERATED_COOKIE. You can use GENERATED_COOKIE if the protocol is HTTP or HTTPS.
1367 #
1368 # When the loadBalancingScheme is INTERNAL, possible values are NONE, CLIENT_IP, CLIENT_IP_PROTO, or CLIENT_IP_PORT_PROTO.
1369 #
1370 # When the loadBalancingScheme is INTERNAL_SELF_MANAGED, or INTERNAL_MANAGED, possible values are NONE, CLIENT_IP, GENERATED_COOKIE, HEADER_FIELD, or HTTP_COOKIE.
Dmitry Frenkel3e17f892020-10-06 16:46:05 -07001371 #
1372 # Not supported when the backend service is referenced by a URL map that is bound to target gRPC proxy that has validateForProxyless field set to true.
Bu Sun Kimd059ad82020-07-22 17:02:09 -07001373 &quot;timeoutSec&quot;: 42, # The backend service timeout has a different meaning depending on the type of load balancer. For more information see, Backend service settings The default is 30 seconds.
Bu Sun Kim65020912020-05-20 12:08:20 -07001374}
Jon Wayne Parrott692617a2017-01-06 09:58:29 -08001375
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001376 requestId: string, An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed.
1377
1378For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments.
1379
1380The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000).
Jon Wayne Parrott692617a2017-01-06 09:58:29 -08001381
1382Returns:
1383 An object of the form:
1384
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001385 { # Represents an Operation resource.
1386 #
Dan O'Mearadd494642020-05-01 07:42:23 -07001387 # Google Compute Engine has three Operation resources:
1388 #
1389 # * [Global](/compute/docs/reference/rest/{$api_version}/globalOperations) * [Regional](/compute/docs/reference/rest/{$api_version}/regionOperations) * [Zonal](/compute/docs/reference/rest/{$api_version}/zoneOperations)
1390 #
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001391 # You can use an operation resource to manage asynchronous API requests. For more information, read Handling API responses.
1392 #
1393 # Operations can be global, regional or zonal.
Dan O'Mearadd494642020-05-01 07:42:23 -07001394 # - For global operations, use the `globalOperations` resource.
1395 # - For regional operations, use the `regionOperations` resource.
1396 # - For zonal operations, use the `zonalOperations` resource.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001397 #
Dan O'Mearadd494642020-05-01 07:42:23 -07001398 # For more information, read Global, Regional, and Zonal Resources. (== resource_for {$api_version}.globalOperations ==) (== resource_for {$api_version}.regionOperations ==) (== resource_for {$api_version}.zoneOperations ==)
Bu Sun Kim65020912020-05-20 12:08:20 -07001399 &quot;clientOperationId&quot;: &quot;A String&quot;, # [Output Only] The value of `requestId` if you provided it in the request. Not present otherwise.
1400 &quot;creationTimestamp&quot;: &quot;A String&quot;, # [Deprecated] This field is deprecated.
1401 &quot;description&quot;: &quot;A String&quot;, # [Output Only] A textual description of the operation, which is set when the operation is created.
1402 &quot;endTime&quot;: &quot;A String&quot;, # [Output Only] The time that this operation was completed. This value is in RFC3339 text format.
1403 &quot;error&quot;: { # [Output Only] If errors are generated during processing of the operation, this field will be populated.
1404 &quot;errors&quot;: [ # [Output Only] The array of errors encountered while processing this operation.
Jon Wayne Parrott692617a2017-01-06 09:58:29 -08001405 {
Bu Sun Kim65020912020-05-20 12:08:20 -07001406 &quot;code&quot;: &quot;A String&quot;, # [Output Only] The error type identifier for this error.
1407 &quot;location&quot;: &quot;A String&quot;, # [Output Only] Indicates the field in the request that caused the error. This property is optional.
1408 &quot;message&quot;: &quot;A String&quot;, # [Output Only] An optional, human-readable error message.
Jon Wayne Parrott692617a2017-01-06 09:58:29 -08001409 },
1410 ],
1411 },
Bu Sun Kim65020912020-05-20 12:08:20 -07001412 &quot;httpErrorMessage&quot;: &quot;A String&quot;, # [Output Only] If the operation fails, this field contains the HTTP error message that was returned, such as `NOT FOUND`.
1413 &quot;httpErrorStatusCode&quot;: 42, # [Output Only] If the operation fails, this field contains the HTTP error status code that was returned. For example, a `404` means the resource was not found.
1414 &quot;id&quot;: &quot;A String&quot;, # [Output Only] The unique identifier for the operation. This identifier is defined by the server.
1415 &quot;insertTime&quot;: &quot;A String&quot;, # [Output Only] The time that this operation was requested. This value is in RFC3339 text format.
1416 &quot;kind&quot;: &quot;compute#operation&quot;, # [Output Only] Type of the resource. Always `compute#operation` for Operation resources.
1417 &quot;name&quot;: &quot;A String&quot;, # [Output Only] Name of the operation.
1418 &quot;operationType&quot;: &quot;A String&quot;, # [Output Only] The type of operation, such as `insert`, `update`, or `delete`, and so on.
1419 &quot;progress&quot;: 42, # [Output Only] An optional progress indicator that ranges from 0 to 100. There is no requirement that this be linear or support any granularity of operations. This should not be used to guess when the operation will be complete. This number should monotonically increase as the operation progresses.
1420 &quot;region&quot;: &quot;A String&quot;, # [Output Only] The URL of the region where the operation resides. Only applicable when performing regional operations.
1421 &quot;selfLink&quot;: &quot;A String&quot;, # [Output Only] Server-defined URL for the resource.
1422 &quot;startTime&quot;: &quot;A String&quot;, # [Output Only] The time that this operation was started by the server. This value is in RFC3339 text format.
1423 &quot;status&quot;: &quot;A String&quot;, # [Output Only] The status of the operation, which can be one of the following: `PENDING`, `RUNNING`, or `DONE`.
1424 &quot;statusMessage&quot;: &quot;A String&quot;, # [Output Only] An optional textual description of the current status of the operation.
1425 &quot;targetId&quot;: &quot;A String&quot;, # [Output Only] The unique target ID, which identifies a specific incarnation of the target resource.
1426 &quot;targetLink&quot;: &quot;A String&quot;, # [Output Only] The URL of the resource that the operation modifies. For operations related to creating a snapshot, this points to the persistent disk that the snapshot was created from.
1427 &quot;user&quot;: &quot;A String&quot;, # [Output Only] User who requested the operation, for example: `user@example.com`.
1428 &quot;warnings&quot;: [ # [Output Only] If warning messages are generated during processing of the operation, this field will be populated.
1429 {
1430 &quot;code&quot;: &quot;A String&quot;, # [Output Only] A warning code, if applicable. For example, Compute Engine returns NO_RESULTS_ON_PAGE if there are no results in the response.
1431 &quot;data&quot;: [ # [Output Only] Metadata about this warning in key: value format. For example:
1432 # &quot;data&quot;: [ { &quot;key&quot;: &quot;scope&quot;, &quot;value&quot;: &quot;zones/us-east1-d&quot; }
1433 {
1434 &quot;key&quot;: &quot;A String&quot;, # [Output Only] A key that provides more detail on the warning being returned. For example, for warnings where there are no results in a list request for a particular zone, this key might be scope and the key value might be the zone name. Other examples might be a key indicating a deprecated resource and a suggested replacement, or a warning about invalid network settings (for example, if an instance attempts to perform IP forwarding but is not enabled for IP forwarding).
1435 &quot;value&quot;: &quot;A String&quot;, # [Output Only] A warning data value corresponding to the key.
1436 },
1437 ],
1438 &quot;message&quot;: &quot;A String&quot;, # [Output Only] A human-readable description of the warning code.
1439 },
1440 ],
1441 &quot;zone&quot;: &quot;A String&quot;, # [Output Only] The URL of the zone where the operation resides. Only applicable when performing per-zone operations.
Jon Wayne Parrott692617a2017-01-06 09:58:29 -08001442 }</pre>
1443</div>
1444
1445<div class="method">
Dan O'Mearadd494642020-05-01 07:42:23 -07001446 <code class="details" id="update">update(project, region, backendService, body=None, requestId=None)</code>
Bu Sun Kimd059ad82020-07-22 17:02:09 -07001447 <pre>Updates the specified regional BackendService resource with the data included in the request. For more information, see Backend services overview.
Jon Wayne Parrott692617a2017-01-06 09:58:29 -08001448
1449Args:
1450 project: string, Project ID for this request. (required)
1451 region: string, Name of the region scoping this request. (required)
1452 backendService: string, Name of the BackendService resource to update. (required)
Dan O'Mearadd494642020-05-01 07:42:23 -07001453 body: object, The request body.
Jon Wayne Parrott692617a2017-01-06 09:58:29 -08001454 The object takes the form of:
1455
Dan O'Mearadd494642020-05-01 07:42:23 -07001456{ # Represents a Backend Service resource.
Bu Sun Kim65020912020-05-20 12:08:20 -07001457 #
Bu Sun Kimd059ad82020-07-22 17:02:09 -07001458 # A backend service defines how Google Cloud load balancers distribute traffic. The backend service configuration contains a set of values, such as the protocol used to connect to backends, various distribution and session settings, health checks, and timeouts. These settings provide fine-grained control over how your load balancer behaves. Most of the settings have default values that allow for easy configuration if you need to get started quickly.
Bu Sun Kim65020912020-05-20 12:08:20 -07001459 #
1460 # Backend services in Google Compute Engine can be either regionally or globally scoped.
1461 #
1462 # * [Global](/compute/docs/reference/rest/{$api_version}/backendServices) * [Regional](/compute/docs/reference/rest/{$api_version}/regionBackendServices)
1463 #
Bu Sun Kimd059ad82020-07-22 17:02:09 -07001464 # For more information, see Backend Services.
Bu Sun Kim65020912020-05-20 12:08:20 -07001465 #
1466 # (== resource_for {$api_version}.backendService ==)
Dmitry Frenkel3e17f892020-10-06 16:46:05 -07001467 &quot;affinityCookieTtlSec&quot;: 42, # Lifetime of cookies in seconds. Only applicable if the loadBalancingScheme is EXTERNAL, INTERNAL_SELF_MANAGED, or INTERNAL_MANAGED, the protocol is HTTP or HTTPS, and the sessionAffinity is GENERATED_COOKIE, or HTTP_COOKIE.
1468 #
1469 # If set to 0, the cookie is non-persistent and lasts only until the end of the browser session (or equivalent). The maximum allowed value is one day (86,400).
1470 #
1471 # Not supported when the backend service is referenced by a URL map that is bound to target gRPC proxy that has validateForProxyless field set to true.
Bu Sun Kim65020912020-05-20 12:08:20 -07001472 &quot;backends&quot;: [ # The list of backends that serve this BackendService.
1473 { # Message containing information of one individual backend.
1474 &quot;balancingMode&quot;: &quot;A String&quot;, # Specifies the balancing mode for the backend.
1475 #
1476 # When choosing a balancing mode, you need to consider the loadBalancingScheme, and protocol for the backend service, as well as the type of backend (instance group or NEG).
1477 #
1478 #
1479 # - If the load balancing mode is CONNECTION, then the load is spread based on how many concurrent connections the backend can handle.
1480 # You can use the CONNECTION balancing mode if the protocol for the backend service is SSL, TCP, or UDP.
1481 #
1482 # If the loadBalancingScheme for the backend service is EXTERNAL (SSL Proxy and TCP Proxy load balancers), you must also specify exactly one of the following parameters: maxConnections (except for regional managed instance groups), maxConnectionsPerInstance, or maxConnectionsPerEndpoint.
1483 #
1484 # If the loadBalancingScheme for the backend service is INTERNAL (internal TCP/UDP load balancers), you cannot specify any additional parameters.
1485 #
1486 # - If the load balancing mode is RATE, the load is spread based on the rate of HTTP requests per second (RPS).
1487 # You can use the RATE balancing mode if the protocol for the backend service is HTTP or HTTPS. You must specify exactly one of the following parameters: maxRate (except for regional managed instance groups), maxRatePerInstance, or maxRatePerEndpoint.
1488 #
1489 # - If the load balancing mode is UTILIZATION, the load is spread based on the backend utilization of instances in an instance group.
1490 # You can use the UTILIZATION balancing mode if the loadBalancingScheme of the backend service is EXTERNAL, INTERNAL_SELF_MANAGED, or INTERNAL_MANAGED and the backends are instance groups. There are no restrictions on the backend service protocol.
Bu Sun Kimd059ad82020-07-22 17:02:09 -07001491 &quot;capacityScaler&quot;: 3.14, # A multiplier applied to the group&#x27;s maximum servicing capacity (based on UTILIZATION, RATE or CONNECTION). Default value is 1, which means the group will serve up to 100% of its configured capacity (depending on balancingMode). A setting of 0 means the group is completely drained, offering 0% of its available capacity. Valid range is 0.0 and [0.1,1.0]. You cannot configure a setting larger than 0 and smaller than 0.1. You cannot configure a setting of 0 when there is only one backend attached to the backend service.
Bu Sun Kim65020912020-05-20 12:08:20 -07001492 #
1493 # This cannot be used for internal load balancing.
1494 &quot;description&quot;: &quot;A String&quot;, # An optional description of this resource. Provide this property when you create the resource.
1495 &quot;failover&quot;: True or False, # This field designates whether this is a failover backend. More than one failover backend can be configured for a given BackendService.
1496 &quot;group&quot;: &quot;A String&quot;, # The fully-qualified URL of an instance group or network endpoint group (NEG) resource. The type of backend that a backend service supports depends on the backend service&#x27;s loadBalancingScheme.
1497 #
1498 #
1499 # - When the loadBalancingScheme for the backend service is EXTERNAL, INTERNAL_SELF_MANAGED, or INTERNAL_MANAGED, the backend can be either an instance group or a NEG. The backends on the backend service must be either all instance groups or all NEGs. You cannot mix instance group and NEG backends on the same backend service.
1500 #
1501 #
1502 # - When the loadBalancingScheme for the backend service is INTERNAL, the backend must be an instance group in the same region as the backend service. NEGs are not supported.
1503 #
1504 # You must use the fully-qualified URL (starting with https://www.googleapis.com/) to specify the instance group or NEG. Partial URLs are not supported.
1505 &quot;maxConnections&quot;: 42, # Defines a target maximum number of simultaneous connections that the backend can handle. Valid for network endpoint group and instance group backends (except for regional managed instance groups). If the backend&#x27;s balancingMode is UTILIZATION, this is an optional parameter. If the backend&#x27;s balancingMode is CONNECTION, and backend is attached to a backend service whose loadBalancingScheme is EXTERNAL, you must specify either this parameter, maxConnectionsPerInstance, or maxConnectionsPerEndpoint.
1506 #
1507 # Not available if the backend&#x27;s balancingMode is RATE. If the loadBalancingScheme is INTERNAL, then maxConnections is not supported, even though the backend requires a balancing mode of CONNECTION.
1508 &quot;maxConnectionsPerEndpoint&quot;: 42, # Defines a target maximum number of simultaneous connections for an endpoint of a NEG. This is multiplied by the number of endpoints in the NEG to implicitly calculate a maximum number of target maximum simultaneous connections for the NEG. If the backend&#x27;s balancingMode is CONNECTION, and the backend is attached to a backend service whose loadBalancingScheme is EXTERNAL, you must specify either this parameter, maxConnections, or maxConnectionsPerInstance.
1509 #
1510 # Not available if the backend&#x27;s balancingMode is RATE. Internal TCP/UDP load balancing does not support setting maxConnectionsPerEndpoint even though its backends require a balancing mode of CONNECTION.
1511 &quot;maxConnectionsPerInstance&quot;: 42, # Defines a target maximum number of simultaneous connections for a single VM in a backend instance group. This is multiplied by the number of instances in the instance group to implicitly calculate a target maximum number of simultaneous connections for the whole instance group. If the backend&#x27;s balancingMode is UTILIZATION, this is an optional parameter. If the backend&#x27;s balancingMode is CONNECTION, and backend is attached to a backend service whose loadBalancingScheme is EXTERNAL, you must specify either this parameter, maxConnections, or maxConnectionsPerEndpoint.
1512 #
1513 # Not available if the backend&#x27;s balancingMode is RATE. Internal TCP/UDP load balancing does not support setting maxConnectionsPerInstance even though its backends require a balancing mode of CONNECTION.
1514 &quot;maxRate&quot;: 42, # Defines a maximum number of HTTP requests per second (RPS) that the backend can handle. Valid for network endpoint group and instance group backends (except for regional managed instance groups). Must not be defined if the backend is a managed instance group that uses autoscaling based on load balancing.
1515 #
1516 # If the backend&#x27;s balancingMode is UTILIZATION, this is an optional parameter. If the backend&#x27;s balancingMode is RATE, you must specify maxRate, maxRatePerInstance, or maxRatePerEndpoint.
1517 #
1518 # Not available if the backend&#x27;s balancingMode is CONNECTION.
1519 &quot;maxRatePerEndpoint&quot;: 3.14, # Defines a maximum target for requests per second (RPS) for an endpoint of a NEG. This is multiplied by the number of endpoints in the NEG to implicitly calculate a target maximum rate for the NEG.
1520 #
1521 # If the backend&#x27;s balancingMode is RATE, you must specify either this parameter, maxRate (except for regional managed instance groups), or maxRatePerInstance.
1522 #
1523 # Not available if the backend&#x27;s balancingMode is CONNECTION.
1524 &quot;maxRatePerInstance&quot;: 3.14, # Defines a maximum target for requests per second (RPS) for a single VM in a backend instance group. This is multiplied by the number of instances in the instance group to implicitly calculate a target maximum rate for the whole instance group.
1525 #
1526 # If the backend&#x27;s balancingMode is UTILIZATION, this is an optional parameter. If the backend&#x27;s balancingMode is RATE, you must specify either this parameter, maxRate (except for regional managed instance groups), or maxRatePerEndpoint.
1527 #
1528 # Not available if the backend&#x27;s balancingMode is CONNECTION.
1529 &quot;maxUtilization&quot;: 3.14, # Defines the maximum average backend utilization of a backend VM in an instance group. The valid range is [0.0, 1.0]. This is an optional parameter if the backend&#x27;s balancingMode is UTILIZATION.
1530 #
1531 # This parameter can be used in conjunction with maxRate, maxRatePerInstance, maxConnections (except for regional managed instance groups), or maxConnectionsPerInstance.
Jon Wayne Parrott692617a2017-01-06 09:58:29 -08001532 },
Bu Sun Kim65020912020-05-20 12:08:20 -07001533 ],
1534 &quot;cdnPolicy&quot;: { # Message containing Cloud CDN configuration for a backend service. # Cloud CDN configuration for this BackendService.
1535 &quot;cacheKeyPolicy&quot;: { # Message containing what to include in the cache key for a request for Cloud CDN. # The CacheKeyPolicy for this CdnPolicy.
1536 &quot;includeHost&quot;: True or False, # If true, requests to different hosts will be cached separately.
1537 &quot;includeProtocol&quot;: True or False, # If true, http and https requests will be cached separately.
1538 &quot;includeQueryString&quot;: True or False, # If true, include query string parameters in the cache key according to query_string_whitelist and query_string_blacklist. If neither is set, the entire query string will be included. If false, the query string will be excluded from the cache key entirely.
1539 &quot;queryStringBlacklist&quot;: [ # Names of query string parameters to exclude in cache keys. All other parameters will be included. Either specify query_string_whitelist or query_string_blacklist, not both. &#x27;&amp;&#x27; and &#x27;=&#x27; will be percent encoded and not treated as delimiters.
1540 &quot;A String&quot;,
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001541 ],
Bu Sun Kim65020912020-05-20 12:08:20 -07001542 &quot;queryStringWhitelist&quot;: [ # Names of query string parameters to include in cache keys. All other parameters will be excluded. Either specify query_string_whitelist or query_string_blacklist, not both. &#x27;&amp;&#x27; and &#x27;=&#x27; will be percent encoded and not treated as delimiters.
1543 &quot;A String&quot;,
1544 ],
Sai Cheemalapati4ba8c232017-06-06 18:46:08 -04001545 },
Bu Sun Kim65020912020-05-20 12:08:20 -07001546 &quot;signedUrlCacheMaxAgeSec&quot;: &quot;A String&quot;, # Maximum number of seconds the response to a signed URL request will be considered fresh. After this time period, the response will be revalidated before being served. Defaults to 1hr (3600s). When serving responses to signed URL requests, Cloud CDN will internally behave as though all responses from this backend had a &quot;Cache-Control: public, max-age=[TTL]&quot; header, regardless of any existing Cache-Control header. The actual headers served in responses will not be altered.
1547 &quot;signedUrlKeyNames&quot;: [ # [Output Only] Names of the keys for signing request URLs.
1548 &quot;A String&quot;,
Jon Wayne Parrott692617a2017-01-06 09:58:29 -08001549 ],
Bu Sun Kim65020912020-05-20 12:08:20 -07001550 },
1551 &quot;circuitBreakers&quot;: { # Settings controlling the volume of connections to a backend service. # Settings controlling the volume of connections to a backend service. If not set, this feature is considered disabled.
1552 #
1553 # This field is applicable to either:
1554 # - A regional backend service with the service_protocol set to HTTP, HTTPS, or HTTP2, and load_balancing_scheme set to INTERNAL_MANAGED.
1555 # - A global backend service with the load_balancing_scheme set to INTERNAL_SELF_MANAGED.
Dmitry Frenkel3e17f892020-10-06 16:46:05 -07001556 #
1557 # Not supported when the backend service is referenced by a URL map that is bound to target gRPC proxy that has validateForProxyless field set to true.
Bu Sun Kim65020912020-05-20 12:08:20 -07001558 &quot;maxConnections&quot;: 42, # The maximum number of connections to the backend service. If not specified, there is no limit.
1559 &quot;maxPendingRequests&quot;: 42, # The maximum number of pending requests allowed to the backend service. If not specified, there is no limit.
1560 &quot;maxRequests&quot;: 42, # The maximum number of parallel requests that allowed to the backend service. If not specified, there is no limit.
1561 &quot;maxRequestsPerConnection&quot;: 42, # Maximum requests for a single connection to the backend service. This parameter is respected by both the HTTP/1.1 and HTTP/2 implementations. If not specified, there is no limit. Setting this parameter to 1 will effectively disable keep alive.
1562 &quot;maxRetries&quot;: 42, # The maximum number of parallel retries allowed to the backend cluster. If not specified, the default is 1.
1563 },
1564 &quot;connectionDraining&quot;: { # Message containing connection draining configuration.
1565 &quot;drainingTimeoutSec&quot;: 42, # The amount of time in seconds to allow existing connections to persist while on unhealthy backend VMs. Only applicable if the protocol is not UDP. The valid range is [0, 3600].
1566 },
1567 &quot;consistentHash&quot;: { # This message defines settings for a consistent hash style load balancer. # Consistent Hash-based load balancing can be used to provide soft session affinity based on HTTP headers, cookies or other properties. This load balancing policy is applicable only for HTTP connections. The affinity to a particular destination host will be lost when one or more hosts are added/removed from the destination service. This field specifies parameters that control consistent hashing. This field is only applicable when localityLbPolicy is set to MAGLEV or RING_HASH.
1568 #
1569 # This field is applicable to either:
1570 # - A regional backend service with the service_protocol set to HTTP, HTTPS, or HTTP2, and load_balancing_scheme set to INTERNAL_MANAGED.
1571 # - A global backend service with the load_balancing_scheme set to INTERNAL_SELF_MANAGED.
Dmitry Frenkel3e17f892020-10-06 16:46:05 -07001572 #
1573 # Not supported when the backend service is referenced by a URL map that is bound to target gRPC proxy that has validateForProxyless field set to true.
Bu Sun Kim65020912020-05-20 12:08:20 -07001574 &quot;httpCookie&quot;: { # The information about the HTTP Cookie on which the hash function is based for load balancing policies that use a consistent hash. # Hash is based on HTTP Cookie. This field describes a HTTP cookie that will be used as the hash key for the consistent hash load balancer. If the cookie is not present, it will be generated. This field is applicable if the sessionAffinity is set to HTTP_COOKIE.
1575 &quot;name&quot;: &quot;A String&quot;, # Name of the cookie.
1576 &quot;path&quot;: &quot;A String&quot;, # Path to set for the cookie.
1577 &quot;ttl&quot;: { # A Duration represents a fixed-length span of time represented as a count of seconds and fractions of seconds at nanosecond resolution. It is independent of any calendar and concepts like &quot;day&quot; or &quot;month&quot;. Range is approximately 10,000 years. # Lifetime of the cookie.
1578 &quot;nanos&quot;: 42, # Span of time that&#x27;s a fraction of a second at nanosecond resolution. Durations less than one second are represented with a 0 `seconds` field and a positive `nanos` field. Must be from 0 to 999,999,999 inclusive.
1579 &quot;seconds&quot;: &quot;A String&quot;, # Span of time at a resolution of a second. Must be from 0 to 315,576,000,000 inclusive. Note: these bounds are computed from: 60 sec/min * 60 min/hr * 24 hr/day * 365.25 days/year * 10000 years
1580 },
Sai Cheemalapati4ba8c232017-06-06 18:46:08 -04001581 },
Bu Sun Kim65020912020-05-20 12:08:20 -07001582 &quot;httpHeaderName&quot;: &quot;A String&quot;, # The hash based on the value of the specified header field. This field is applicable if the sessionAffinity is set to HEADER_FIELD.
1583 &quot;minimumRingSize&quot;: &quot;A String&quot;, # The minimum number of virtual nodes to use for the hash ring. Defaults to 1024. Larger ring sizes result in more granular load distributions. If the number of hosts in the load balancing pool is larger than the ring size, each host will be assigned a single virtual node.
1584 },
1585 &quot;creationTimestamp&quot;: &quot;A String&quot;, # [Output Only] Creation timestamp in RFC3339 text format.
1586 &quot;customRequestHeaders&quot;: [ # Headers that the HTTP/S load balancer should add to proxied requests.
1587 &quot;A String&quot;,
1588 ],
1589 &quot;description&quot;: &quot;A String&quot;, # An optional description of this resource. Provide this property when you create the resource.
1590 &quot;enableCDN&quot;: True or False, # If true, enables Cloud CDN for the backend service. Only applicable if the loadBalancingScheme is EXTERNAL and the protocol is HTTP or HTTPS.
1591 &quot;failoverPolicy&quot;: { # Applicable only to Failover for Internal TCP/UDP Load Balancing. On failover or failback, this field indicates whether connection draining will be honored. GCP has a fixed connection draining timeout of 10 minutes. A setting of true terminates existing TCP connections to the active pool during failover and failback, immediately draining traffic. A setting of false allows existing TCP connections to persist, even on VMs no longer in the active pool, for up to the duration of the connection draining timeout (10 minutes). # Applicable only to Failover for Internal TCP/UDP Load Balancing. Requires at least one backend instance group to be defined as a backup (failover) backend.
1592 &quot;disableConnectionDrainOnFailover&quot;: True or False, # This can be set to true only if the protocol is TCP.
1593 #
1594 # The default is false.
1595 &quot;dropTrafficIfUnhealthy&quot;: True or False, # Applicable only to Failover for Internal TCP/UDP Load Balancing. If set to true, connections to the load balancer are dropped when all primary and all backup backend VMs are unhealthy. If set to false, connections are distributed among all primary VMs when all primary and all backup backend VMs are unhealthy.
1596 #
1597 # The default is false.
1598 &quot;failoverRatio&quot;: 3.14, # Applicable only to Failover for Internal TCP/UDP Load Balancing. The value of the field must be in the range [0, 1]. If the value is 0, the load balancer performs a failover when the number of healthy primary VMs equals zero. For all other values, the load balancer performs a failover when the total number of healthy primary VMs is less than this ratio.
1599 },
1600 &quot;fingerprint&quot;: &quot;A String&quot;, # Fingerprint of this resource. A hash of the contents stored in this object. This field is used in optimistic locking. This field will be ignored when inserting a BackendService. An up-to-date fingerprint must be provided in order to update the BackendService, otherwise the request will fail with error 412 conditionNotMet.
1601 #
1602 # To see the latest fingerprint, make a get() request to retrieve a BackendService.
Dmitry Frenkel3e17f892020-10-06 16:46:05 -07001603 &quot;healthChecks&quot;: [ # The list of URLs to the healthChecks, httpHealthChecks (legacy), or httpsHealthChecks (legacy) resource for health checking this backend service. Not all backend services support legacy health checks. See Load balancer guide. Currently, at most one health check can be specified for each backend service. Backend services with instance group or zonal NEG backends must have a health check. Backend services with internet or serverless NEG backends must not have a health check.
Bu Sun Kim65020912020-05-20 12:08:20 -07001604 &quot;A String&quot;,
1605 ],
Bu Sun Kimd059ad82020-07-22 17:02:09 -07001606 &quot;iap&quot;: { # Identity-Aware Proxy # The configurations for Identity-Aware Proxy on this resource.
1607 &quot;enabled&quot;: True or False, # Whether the serving infrastructure will authenticate and authorize all incoming requests. If true, the oauth2ClientId and oauth2ClientSecret fields must be non-empty.
1608 &quot;oauth2ClientId&quot;: &quot;A String&quot;, # OAuth2 client ID to use for the authentication flow.
1609 &quot;oauth2ClientSecret&quot;: &quot;A String&quot;, # OAuth2 client secret to use for the authentication flow. For security reasons, this value cannot be retrieved via the API. Instead, the SHA-256 hash of the value is returned in the oauth2ClientSecretSha256 field.
Bu Sun Kim65020912020-05-20 12:08:20 -07001610 &quot;oauth2ClientSecretSha256&quot;: &quot;A String&quot;, # [Output Only] SHA256 hash value for the field oauth2_client_secret above.
1611 },
1612 &quot;id&quot;: &quot;A String&quot;, # [Output Only] The unique identifier for the resource. This identifier is defined by the server.
1613 &quot;kind&quot;: &quot;compute#backendService&quot;, # [Output Only] Type of resource. Always compute#backendService for backend services.
1614 &quot;loadBalancingScheme&quot;: &quot;A String&quot;, # Specifies the load balancer type. Choose EXTERNAL for load balancers that receive traffic from external clients. Choose INTERNAL for Internal TCP/UDP Load Balancing. Choose INTERNAL_MANAGED for Internal HTTP(S) Load Balancing. Choose INTERNAL_SELF_MANAGED for Traffic Director. A backend service created for one type of load balancing cannot be used with another. For more information, refer to Choosing a load balancer.
1615 &quot;localityLbPolicy&quot;: &quot;A String&quot;, # The load balancing algorithm used within the scope of the locality. The possible values are:
1616 # - ROUND_ROBIN: This is a simple policy in which each healthy backend is selected in round robin order. This is the default.
1617 # - LEAST_REQUEST: An O(1) algorithm which selects two random healthy hosts and picks the host which has fewer active requests.
1618 # - RING_HASH: The ring/modulo hash load balancer implements consistent hashing to backends. The algorithm has the property that the addition/removal of a host from a set of N hosts only affects 1/N of the requests.
1619 # - RANDOM: The load balancer selects a random healthy host.
1620 # - ORIGINAL_DESTINATION: Backend host is selected based on the client connection metadata, i.e., connections are opened to the same address as the destination address of the incoming connection before the connection was redirected to the load balancer.
Bu Sun Kimd059ad82020-07-22 17:02:09 -07001621 # - MAGLEV: used as a drop in replacement for the ring hash load balancer. Maglev is not as stable as ring hash but has faster table lookup build times and host selection times. For more information about Maglev, see https://ai.google/research/pubs/pub44824
Bu Sun Kim65020912020-05-20 12:08:20 -07001622 #
1623 # This field is applicable to either:
1624 # - A regional backend service with the service_protocol set to HTTP, HTTPS, or HTTP2, and load_balancing_scheme set to INTERNAL_MANAGED.
1625 # - A global backend service with the load_balancing_scheme set to INTERNAL_SELF_MANAGED.
1626 #
Dmitry Frenkel3e17f892020-10-06 16:46:05 -07001627 # If sessionAffinity is not NONE, and this field is not set to MAGLEV or RING_HASH, session affinity settings will not take effect.
1628 #
1629 # Only the default ROUND_ROBIN policy is supported when the backend service is referenced by a URL map that is bound to target gRPC proxy that has validateForProxyless field set to true.
Bu Sun Kim65020912020-05-20 12:08:20 -07001630 &quot;logConfig&quot;: { # The available logging options for the load balancer traffic served by this backend service. # This field denotes the logging options for the load balancer traffic served by this backend service. If logging is enabled, logs will be exported to Stackdriver.
1631 &quot;enable&quot;: True or False, # This field denotes whether to enable logging for the load balancer traffic served by this backend service.
1632 &quot;sampleRate&quot;: 3.14, # This field can only be specified if logging is enabled for this backend service. The value of the field must be in [0, 1]. This configures the sampling rate of requests to the load balancer where 1.0 means all logged requests are reported and 0.0 means no logged requests are reported. The default value is 1.0.
1633 },
1634 &quot;name&quot;: &quot;A String&quot;, # Name of the resource. Provided by the client when the resource is created. The name must be 1-63 characters long, and comply with RFC1035. Specifically, the name must be 1-63 characters long and match the regular expression `[a-z]([-a-z0-9]*[a-z0-9])?` which means the first character must be a lowercase letter, and all following characters must be a dash, lowercase letter, or digit, except the last character, which cannot be a dash.
1635 &quot;network&quot;: &quot;A String&quot;, # The URL of the network to which this backend service belongs. This field can only be spcified when the load balancing scheme is set to INTERNAL.
1636 &quot;outlierDetection&quot;: { # Settings controlling the eviction of unhealthy hosts from the load balancing pool for the backend service. # Settings controlling the eviction of unhealthy hosts from the load balancing pool for the backend service. If not set, this feature is considered disabled.
1637 #
1638 # This field is applicable to either:
1639 # - A regional backend service with the service_protocol set to HTTP, HTTPS, or HTTP2, and load_balancing_scheme set to INTERNAL_MANAGED.
1640 # - A global backend service with the load_balancing_scheme set to INTERNAL_SELF_MANAGED.
Dmitry Frenkel3e17f892020-10-06 16:46:05 -07001641 #
1642 # Not supported when the backend service is referenced by a URL map that is bound to target gRPC proxy that has validateForProxyless field set to true.
Bu Sun Kim65020912020-05-20 12:08:20 -07001643 &quot;baseEjectionTime&quot;: { # A Duration represents a fixed-length span of time represented as a count of seconds and fractions of seconds at nanosecond resolution. It is independent of any calendar and concepts like &quot;day&quot; or &quot;month&quot;. Range is approximately 10,000 years. # The base time that a host is ejected for. The real ejection time is equal to the base ejection time multiplied by the number of times the host has been ejected. Defaults to 30000ms or 30s.
1644 &quot;nanos&quot;: 42, # Span of time that&#x27;s a fraction of a second at nanosecond resolution. Durations less than one second are represented with a 0 `seconds` field and a positive `nanos` field. Must be from 0 to 999,999,999 inclusive.
1645 &quot;seconds&quot;: &quot;A String&quot;, # Span of time at a resolution of a second. Must be from 0 to 315,576,000,000 inclusive. Note: these bounds are computed from: 60 sec/min * 60 min/hr * 24 hr/day * 365.25 days/year * 10000 years
Dan O'Mearadd494642020-05-01 07:42:23 -07001646 },
Bu Sun Kim65020912020-05-20 12:08:20 -07001647 &quot;consecutiveErrors&quot;: 42, # Number of errors before a host is ejected from the connection pool. When the backend host is accessed over HTTP, a 5xx return code qualifies as an error. Defaults to 5.
1648 &quot;consecutiveGatewayFailure&quot;: 42, # The number of consecutive gateway failures (502, 503, 504 status or connection errors that are mapped to one of those status codes) before a consecutive gateway failure ejection occurs. Defaults to 3.
1649 &quot;enforcingConsecutiveErrors&quot;: 42, # The percentage chance that a host will be actually ejected when an outlier status is detected through consecutive 5xx. This setting can be used to disable ejection or to ramp it up slowly. Defaults to 0.
1650 &quot;enforcingConsecutiveGatewayFailure&quot;: 42, # The percentage chance that a host will be actually ejected when an outlier status is detected through consecutive gateway failures. This setting can be used to disable ejection or to ramp it up slowly. Defaults to 100.
1651 &quot;enforcingSuccessRate&quot;: 42, # The percentage chance that a host will be actually ejected when an outlier status is detected through success rate statistics. This setting can be used to disable ejection or to ramp it up slowly. Defaults to 100.
1652 &quot;interval&quot;: { # A Duration represents a fixed-length span of time represented as a count of seconds and fractions of seconds at nanosecond resolution. It is independent of any calendar and concepts like &quot;day&quot; or &quot;month&quot;. Range is approximately 10,000 years. # Time interval between ejection analysis sweeps. This can result in both new ejections as well as hosts being returned to service. Defaults to 1 second.
1653 &quot;nanos&quot;: 42, # Span of time that&#x27;s a fraction of a second at nanosecond resolution. Durations less than one second are represented with a 0 `seconds` field and a positive `nanos` field. Must be from 0 to 999,999,999 inclusive.
1654 &quot;seconds&quot;: &quot;A String&quot;, # Span of time at a resolution of a second. Must be from 0 to 315,576,000,000 inclusive. Note: these bounds are computed from: 60 sec/min * 60 min/hr * 24 hr/day * 365.25 days/year * 10000 years
Dan O'Mearadd494642020-05-01 07:42:23 -07001655 },
Bu Sun Kim65020912020-05-20 12:08:20 -07001656 &quot;maxEjectionPercent&quot;: 42, # Maximum percentage of hosts in the load balancing pool for the backend service that can be ejected. Defaults to 50%.
1657 &quot;successRateMinimumHosts&quot;: 42, # The number of hosts in a cluster that must have enough request volume to detect success rate outliers. If the number of hosts is less than this setting, outlier detection via success rate statistics is not performed for any host in the cluster. Defaults to 5.
1658 &quot;successRateRequestVolume&quot;: 42, # The minimum number of total requests that must be collected in one interval (as defined by the interval duration above) to include this host in success rate based outlier detection. If the volume is lower than this setting, outlier detection via success rate statistics is not performed for that host. Defaults to 100.
1659 &quot;successRateStdevFactor&quot;: 42, # This factor is used to determine the ejection threshold for success rate outlier ejection. The ejection threshold is the difference between the mean success rate, and the product of this factor and the standard deviation of the mean success rate: mean - (stdev * success_rate_stdev_factor). This factor is divided by a thousand to get a double. That is, if the desired factor is 1.9, the runtime value should be 1900. Defaults to 1900.
1660 },
1661 &quot;port&quot;: 42, # Deprecated in favor of portName. The TCP port to connect on the backend. The default value is 80.
1662 #
1663 # This cannot be used if the loadBalancingScheme is INTERNAL (Internal TCP/UDP Load Balancing).
1664 &quot;portName&quot;: &quot;A String&quot;, # A named port on a backend instance group representing the port for communication to the backend VMs in that group. Required when the loadBalancingScheme is EXTERNAL, INTERNAL_MANAGED, or INTERNAL_SELF_MANAGED and the backends are instance groups. The named port must be defined on each backend instance group. This parameter has no meaning if the backends are NEGs.
1665 #
1666 #
1667 #
1668 # Must be omitted when the loadBalancingScheme is INTERNAL (Internal TCP/UDP Load Balancing).
1669 &quot;protocol&quot;: &quot;A String&quot;, # The protocol this BackendService uses to communicate with backends.
1670 #
Dmitry Frenkel3e17f892020-10-06 16:46:05 -07001671 # Possible values are HTTP, HTTPS, HTTP2, TCP, SSL, UDP or GRPC. depending on the chosen load balancer or Traffic Director configuration. Refer to the documentation for the load balancer or for Traffic Director for more information.
1672 #
1673 # Must be set to GRPC when the backend service is referenced by a URL map that is bound to target gRPC proxy.
Bu Sun Kim65020912020-05-20 12:08:20 -07001674 &quot;region&quot;: &quot;A String&quot;, # [Output Only] URL of the region where the regional backend service resides. This field is not applicable to global backend services. You must specify this field as part of the HTTP request URL. It is not settable as a field in the request body.
1675 &quot;securityPolicy&quot;: &quot;A String&quot;, # [Output Only] The resource URL for the security policy associated with this backend service.
Bu Sun Kim673ec5c2020-11-16 11:05:03 -07001676 &quot;securitySettings&quot;: { # The authentication and authorization settings for a BackendService. # This field specifies the security policy that applies to this backend service. This field is applicable to either:
1677 # - A regional backend service with the service_protocol set to HTTP, HTTPS, or HTTP2, and load_balancing_scheme set to INTERNAL_MANAGED.
1678 # - A global backend service with the load_balancing_scheme set to INTERNAL_SELF_MANAGED.
1679 &quot;clientTlsPolicy&quot;: &quot;A String&quot;, # Optional. A URL referring to a networksecurity.ClientTlsPolicy resource that describes how clients should authenticate with this service&#x27;s backends.
1680 # clientTlsPolicy only applies to a global BackendService with the loadBalancingScheme set to INTERNAL_SELF_MANAGED.
1681 # If left blank, communications are not encrypted.
1682 # Note: This field currently has no impact.
1683 &quot;subjectAltNames&quot;: [ # Optional. A list of Subject Alternative Names (SANs) that the client verifies during a mutual TLS handshake with an server/endpoint for this BackendService. When the server presents its X.509 certificate to the client, the client inspects the certificate&#x27;s subjectAltName field. If the field contains one of the specified values, the communication continues. Otherwise, it fails. This additional check enables the client to verify that the server is authorized to run the requested service.
1684 # Note that the contents of the server certificate&#x27;s subjectAltName field are configured by the Public Key Infrastructure which provisions server identities.
1685 # Only applies to a global BackendService with loadBalancingScheme set to INTERNAL_SELF_MANAGED. Only applies when BackendService has an attached clientTlsPolicy with clientCertificate (mTLS mode).
1686 # Note: This field currently has no impact.
1687 &quot;A String&quot;,
1688 ],
1689 },
Bu Sun Kim65020912020-05-20 12:08:20 -07001690 &quot;selfLink&quot;: &quot;A String&quot;, # [Output Only] Server-defined URL for the resource.
1691 &quot;sessionAffinity&quot;: &quot;A String&quot;, # Type of session affinity to use. The default is NONE. Session affinity is not applicable if the --protocol is UDP.
1692 #
1693 # When the loadBalancingScheme is EXTERNAL, possible values are NONE, CLIENT_IP, or GENERATED_COOKIE. You can use GENERATED_COOKIE if the protocol is HTTP or HTTPS.
1694 #
1695 # When the loadBalancingScheme is INTERNAL, possible values are NONE, CLIENT_IP, CLIENT_IP_PROTO, or CLIENT_IP_PORT_PROTO.
1696 #
1697 # When the loadBalancingScheme is INTERNAL_SELF_MANAGED, or INTERNAL_MANAGED, possible values are NONE, CLIENT_IP, GENERATED_COOKIE, HEADER_FIELD, or HTTP_COOKIE.
Dmitry Frenkel3e17f892020-10-06 16:46:05 -07001698 #
1699 # Not supported when the backend service is referenced by a URL map that is bound to target gRPC proxy that has validateForProxyless field set to true.
Bu Sun Kimd059ad82020-07-22 17:02:09 -07001700 &quot;timeoutSec&quot;: 42, # The backend service timeout has a different meaning depending on the type of load balancer. For more information see, Backend service settings The default is 30 seconds.
Bu Sun Kim65020912020-05-20 12:08:20 -07001701}
Jon Wayne Parrott692617a2017-01-06 09:58:29 -08001702
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001703 requestId: string, An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed.
1704
1705For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments.
1706
1707The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000).
Jon Wayne Parrott692617a2017-01-06 09:58:29 -08001708
1709Returns:
1710 An object of the form:
1711
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001712 { # Represents an Operation resource.
1713 #
Dan O'Mearadd494642020-05-01 07:42:23 -07001714 # Google Compute Engine has three Operation resources:
1715 #
1716 # * [Global](/compute/docs/reference/rest/{$api_version}/globalOperations) * [Regional](/compute/docs/reference/rest/{$api_version}/regionOperations) * [Zonal](/compute/docs/reference/rest/{$api_version}/zoneOperations)
1717 #
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001718 # You can use an operation resource to manage asynchronous API requests. For more information, read Handling API responses.
1719 #
1720 # Operations can be global, regional or zonal.
Dan O'Mearadd494642020-05-01 07:42:23 -07001721 # - For global operations, use the `globalOperations` resource.
1722 # - For regional operations, use the `regionOperations` resource.
1723 # - For zonal operations, use the `zonalOperations` resource.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001724 #
Dan O'Mearadd494642020-05-01 07:42:23 -07001725 # For more information, read Global, Regional, and Zonal Resources. (== resource_for {$api_version}.globalOperations ==) (== resource_for {$api_version}.regionOperations ==) (== resource_for {$api_version}.zoneOperations ==)
Bu Sun Kim65020912020-05-20 12:08:20 -07001726 &quot;clientOperationId&quot;: &quot;A String&quot;, # [Output Only] The value of `requestId` if you provided it in the request. Not present otherwise.
1727 &quot;creationTimestamp&quot;: &quot;A String&quot;, # [Deprecated] This field is deprecated.
1728 &quot;description&quot;: &quot;A String&quot;, # [Output Only] A textual description of the operation, which is set when the operation is created.
1729 &quot;endTime&quot;: &quot;A String&quot;, # [Output Only] The time that this operation was completed. This value is in RFC3339 text format.
1730 &quot;error&quot;: { # [Output Only] If errors are generated during processing of the operation, this field will be populated.
1731 &quot;errors&quot;: [ # [Output Only] The array of errors encountered while processing this operation.
Jon Wayne Parrott692617a2017-01-06 09:58:29 -08001732 {
Bu Sun Kim65020912020-05-20 12:08:20 -07001733 &quot;code&quot;: &quot;A String&quot;, # [Output Only] The error type identifier for this error.
1734 &quot;location&quot;: &quot;A String&quot;, # [Output Only] Indicates the field in the request that caused the error. This property is optional.
1735 &quot;message&quot;: &quot;A String&quot;, # [Output Only] An optional, human-readable error message.
Jon Wayne Parrott692617a2017-01-06 09:58:29 -08001736 },
1737 ],
1738 },
Bu Sun Kim65020912020-05-20 12:08:20 -07001739 &quot;httpErrorMessage&quot;: &quot;A String&quot;, # [Output Only] If the operation fails, this field contains the HTTP error message that was returned, such as `NOT FOUND`.
1740 &quot;httpErrorStatusCode&quot;: 42, # [Output Only] If the operation fails, this field contains the HTTP error status code that was returned. For example, a `404` means the resource was not found.
1741 &quot;id&quot;: &quot;A String&quot;, # [Output Only] The unique identifier for the operation. This identifier is defined by the server.
1742 &quot;insertTime&quot;: &quot;A String&quot;, # [Output Only] The time that this operation was requested. This value is in RFC3339 text format.
1743 &quot;kind&quot;: &quot;compute#operation&quot;, # [Output Only] Type of the resource. Always `compute#operation` for Operation resources.
1744 &quot;name&quot;: &quot;A String&quot;, # [Output Only] Name of the operation.
1745 &quot;operationType&quot;: &quot;A String&quot;, # [Output Only] The type of operation, such as `insert`, `update`, or `delete`, and so on.
1746 &quot;progress&quot;: 42, # [Output Only] An optional progress indicator that ranges from 0 to 100. There is no requirement that this be linear or support any granularity of operations. This should not be used to guess when the operation will be complete. This number should monotonically increase as the operation progresses.
1747 &quot;region&quot;: &quot;A String&quot;, # [Output Only] The URL of the region where the operation resides. Only applicable when performing regional operations.
1748 &quot;selfLink&quot;: &quot;A String&quot;, # [Output Only] Server-defined URL for the resource.
1749 &quot;startTime&quot;: &quot;A String&quot;, # [Output Only] The time that this operation was started by the server. This value is in RFC3339 text format.
1750 &quot;status&quot;: &quot;A String&quot;, # [Output Only] The status of the operation, which can be one of the following: `PENDING`, `RUNNING`, or `DONE`.
1751 &quot;statusMessage&quot;: &quot;A String&quot;, # [Output Only] An optional textual description of the current status of the operation.
1752 &quot;targetId&quot;: &quot;A String&quot;, # [Output Only] The unique target ID, which identifies a specific incarnation of the target resource.
1753 &quot;targetLink&quot;: &quot;A String&quot;, # [Output Only] The URL of the resource that the operation modifies. For operations related to creating a snapshot, this points to the persistent disk that the snapshot was created from.
1754 &quot;user&quot;: &quot;A String&quot;, # [Output Only] User who requested the operation, for example: `user@example.com`.
1755 &quot;warnings&quot;: [ # [Output Only] If warning messages are generated during processing of the operation, this field will be populated.
1756 {
1757 &quot;code&quot;: &quot;A String&quot;, # [Output Only] A warning code, if applicable. For example, Compute Engine returns NO_RESULTS_ON_PAGE if there are no results in the response.
1758 &quot;data&quot;: [ # [Output Only] Metadata about this warning in key: value format. For example:
1759 # &quot;data&quot;: [ { &quot;key&quot;: &quot;scope&quot;, &quot;value&quot;: &quot;zones/us-east1-d&quot; }
1760 {
1761 &quot;key&quot;: &quot;A String&quot;, # [Output Only] A key that provides more detail on the warning being returned. For example, for warnings where there are no results in a list request for a particular zone, this key might be scope and the key value might be the zone name. Other examples might be a key indicating a deprecated resource and a suggested replacement, or a warning about invalid network settings (for example, if an instance attempts to perform IP forwarding but is not enabled for IP forwarding).
1762 &quot;value&quot;: &quot;A String&quot;, # [Output Only] A warning data value corresponding to the key.
1763 },
1764 ],
1765 &quot;message&quot;: &quot;A String&quot;, # [Output Only] A human-readable description of the warning code.
1766 },
1767 ],
1768 &quot;zone&quot;: &quot;A String&quot;, # [Output Only] The URL of the zone where the operation resides. Only applicable when performing per-zone operations.
Jon Wayne Parrott692617a2017-01-06 09:58:29 -08001769 }</pre>
1770</div>
1771
1772</body></html>