Index: generated/googleapis/lib/compute/v1.dart |
diff --git a/generated/googleapis/lib/compute/v1.dart b/generated/googleapis/lib/compute/v1.dart |
index 5fc0327af57a70016de068c1544bd2f8cb80a4ab..c748a6118604dc44ca4f22f8f8348e2111134c55 100644 |
--- a/generated/googleapis/lib/compute/v1.dart |
+++ b/generated/googleapis/lib/compute/v1.dart |
@@ -37,6 +37,7 @@ class ComputeApi { |
final commons.ApiRequester _requester; |
+ AcceleratorTypesResourceApi get acceleratorTypes => new AcceleratorTypesResourceApi(_requester); |
AddressesResourceApi get addresses => new AddressesResourceApi(_requester); |
AutoscalersResourceApi get autoscalers => new AutoscalersResourceApi(_requester); |
BackendBucketsResourceApi get backendBuckets => new BackendBucketsResourceApi(_requester); |
@@ -62,6 +63,7 @@ class ComputeApi { |
ProjectsResourceApi get projects => new ProjectsResourceApi(_requester); |
RegionAutoscalersResourceApi get regionAutoscalers => new RegionAutoscalersResourceApi(_requester); |
RegionBackendServicesResourceApi get regionBackendServices => new RegionBackendServicesResourceApi(_requester); |
+ RegionCommitmentsResourceApi get regionCommitments => new RegionCommitmentsResourceApi(_requester); |
RegionInstanceGroupManagersResourceApi get regionInstanceGroupManagers => new RegionInstanceGroupManagersResourceApi(_requester); |
RegionInstanceGroupsResourceApi get regionInstanceGroups => new RegionInstanceGroupsResourceApi(_requester); |
RegionOperationsResourceApi get regionOperations => new RegionOperationsResourceApi(_requester); |
@@ -88,6 +90,273 @@ class ComputeApi { |
} |
+class AcceleratorTypesResourceApi { |
+ final commons.ApiRequester _requester; |
+ |
+ AcceleratorTypesResourceApi(commons.ApiRequester client) : |
+ _requester = client; |
+ |
+ /** |
+ * Retrieves an aggregated list of accelerator types. |
+ * |
+ * Request parameters: |
+ * |
+ * [project] - Project ID for this request. |
+ * Value must have pattern |
+ * "(?:(?:[-a-z0-9]{1,63}\.)*(?:[a-z](?:[-a-z0-9]{0,61}[a-z0-9])?):)?(?:[0-9]{1,19}|(?:[a-z0-9](?:[-a-z0-9]{0,61}[a-z0-9])?))". |
+ * |
+ * [filter] - Sets a filter {expression} for filtering listed resources. Your |
+ * {expression} must be in the format: field_name comparison_string |
+ * literal_string. |
+ * |
+ * The field_name is the name of the field you want to compare. Only atomic |
+ * field types are supported (string, number, boolean). The comparison_string |
+ * must be either eq (equals) or ne (not equals). The literal_string is the |
+ * string value to filter to. The literal value must be valid for the type of |
+ * field you are filtering by (string, number, boolean). For string fields, |
+ * the literal value is interpreted as a regular expression using RE2 syntax. |
+ * The literal value must match the entire field. |
+ * |
+ * For example, to filter for instances that do not have a name of |
+ * example-instance, you would use name ne example-instance. |
+ * |
+ * You can filter on nested fields. For example, you could filter on instances |
+ * that have set the scheduling.automaticRestart field to true. Use filtering |
+ * on nested fields to take advantage of labels to organize and search for |
+ * results based on label values. |
+ * |
+ * To filter on multiple expressions, provide each separate expression within |
+ * parentheses. For example, (scheduling.automaticRestart eq true) (zone eq |
+ * us-central1-f). Multiple expressions are treated as AND expressions, |
+ * meaning that resources must match all expressions to pass the filters. |
+ * |
+ * [maxResults] - 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) |
+ * |
+ * [orderBy] - Sorts list results by a certain order. By default, results are |
+ * returned in alphanumerical order based on the resource name. |
+ * |
+ * You can also sort results in descending order based on the creation |
+ * timestamp using orderBy="creationTimestamp desc". 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. |
+ * |
+ * Currently, only sorting by name or creationTimestamp desc is supported. |
+ * |
+ * [pageToken] - Specifies a page token to use. Set pageToken to the |
+ * nextPageToken returned by a previous list request to get the next page of |
+ * results. |
+ * |
+ * Completes with a [AcceleratorTypeAggregatedList]. |
+ * |
+ * Completes with a [commons.ApiRequestError] if the API endpoint returned an |
+ * error. |
+ * |
+ * If the used [http.Client] completes with an error when making a REST call, |
+ * this method will complete with the same error. |
+ */ |
+ async.Future<AcceleratorTypeAggregatedList> aggregatedList(core.String project, {core.String filter, core.int maxResults, core.String orderBy, core.String pageToken}) { |
+ var _url = null; |
+ var _queryParams = new core.Map(); |
+ var _uploadMedia = null; |
+ var _uploadOptions = null; |
+ var _downloadOptions = commons.DownloadOptions.Metadata; |
+ var _body = null; |
+ |
+ if (project == null) { |
+ throw new core.ArgumentError("Parameter project is required."); |
+ } |
+ if (filter != null) { |
+ _queryParams["filter"] = [filter]; |
+ } |
+ if (maxResults != null) { |
+ _queryParams["maxResults"] = ["${maxResults}"]; |
+ } |
+ if (orderBy != null) { |
+ _queryParams["orderBy"] = [orderBy]; |
+ } |
+ if (pageToken != null) { |
+ _queryParams["pageToken"] = [pageToken]; |
+ } |
+ |
+ _url = commons.Escaper.ecapeVariable('$project') + '/aggregated/acceleratorTypes'; |
+ |
+ var _response = _requester.request(_url, |
+ "GET", |
+ body: _body, |
+ queryParams: _queryParams, |
+ uploadOptions: _uploadOptions, |
+ uploadMedia: _uploadMedia, |
+ downloadOptions: _downloadOptions); |
+ return _response.then((data) => new AcceleratorTypeAggregatedList.fromJson(data)); |
+ } |
+ |
+ /** |
+ * Returns the specified accelerator type. Get a list of available accelerator |
+ * types by making a list() request. |
+ * |
+ * Request parameters: |
+ * |
+ * [project] - Project ID for this request. |
+ * Value must have pattern |
+ * "(?:(?:[-a-z0-9]{1,63}\.)*(?:[a-z](?:[-a-z0-9]{0,61}[a-z0-9])?):)?(?:[0-9]{1,19}|(?:[a-z0-9](?:[-a-z0-9]{0,61}[a-z0-9])?))". |
+ * |
+ * [zone] - The name of the zone for this request. |
+ * Value must have pattern "[a-z](?:[-a-z0-9]{0,61}[a-z0-9])?". |
+ * |
+ * [acceleratorType] - Name of the accelerator type to return. |
+ * Value must have pattern "[a-z](?:[-a-z0-9]{0,61}[a-z0-9])?". |
+ * |
+ * Completes with a [AcceleratorType]. |
+ * |
+ * Completes with a [commons.ApiRequestError] if the API endpoint returned an |
+ * error. |
+ * |
+ * If the used [http.Client] completes with an error when making a REST call, |
+ * this method will complete with the same error. |
+ */ |
+ async.Future<AcceleratorType> get(core.String project, core.String zone, core.String acceleratorType) { |
+ var _url = null; |
+ var _queryParams = new core.Map(); |
+ var _uploadMedia = null; |
+ var _uploadOptions = null; |
+ var _downloadOptions = commons.DownloadOptions.Metadata; |
+ var _body = null; |
+ |
+ if (project == null) { |
+ throw new core.ArgumentError("Parameter project is required."); |
+ } |
+ if (zone == null) { |
+ throw new core.ArgumentError("Parameter zone is required."); |
+ } |
+ if (acceleratorType == null) { |
+ throw new core.ArgumentError("Parameter acceleratorType is required."); |
+ } |
+ |
+ _url = commons.Escaper.ecapeVariable('$project') + '/zones/' + commons.Escaper.ecapeVariable('$zone') + '/acceleratorTypes/' + commons.Escaper.ecapeVariable('$acceleratorType'); |
+ |
+ var _response = _requester.request(_url, |
+ "GET", |
+ body: _body, |
+ queryParams: _queryParams, |
+ uploadOptions: _uploadOptions, |
+ uploadMedia: _uploadMedia, |
+ downloadOptions: _downloadOptions); |
+ return _response.then((data) => new AcceleratorType.fromJson(data)); |
+ } |
+ |
+ /** |
+ * Retrieves a list of accelerator types available to the specified project. |
+ * |
+ * Request parameters: |
+ * |
+ * [project] - Project ID for this request. |
+ * Value must have pattern |
+ * "(?:(?:[-a-z0-9]{1,63}\.)*(?:[a-z](?:[-a-z0-9]{0,61}[a-z0-9])?):)?(?:[0-9]{1,19}|(?:[a-z0-9](?:[-a-z0-9]{0,61}[a-z0-9])?))". |
+ * |
+ * [zone] - The name of the zone for this request. |
+ * Value must have pattern "[a-z](?:[-a-z0-9]{0,61}[a-z0-9])?". |
+ * |
+ * [filter] - Sets a filter {expression} for filtering listed resources. Your |
+ * {expression} must be in the format: field_name comparison_string |
+ * literal_string. |
+ * |
+ * The field_name is the name of the field you want to compare. Only atomic |
+ * field types are supported (string, number, boolean). The comparison_string |
+ * must be either eq (equals) or ne (not equals). The literal_string is the |
+ * string value to filter to. The literal value must be valid for the type of |
+ * field you are filtering by (string, number, boolean). For string fields, |
+ * the literal value is interpreted as a regular expression using RE2 syntax. |
+ * The literal value must match the entire field. |
+ * |
+ * For example, to filter for instances that do not have a name of |
+ * example-instance, you would use name ne example-instance. |
+ * |
+ * You can filter on nested fields. For example, you could filter on instances |
+ * that have set the scheduling.automaticRestart field to true. Use filtering |
+ * on nested fields to take advantage of labels to organize and search for |
+ * results based on label values. |
+ * |
+ * To filter on multiple expressions, provide each separate expression within |
+ * parentheses. For example, (scheduling.automaticRestart eq true) (zone eq |
+ * us-central1-f). Multiple expressions are treated as AND expressions, |
+ * meaning that resources must match all expressions to pass the filters. |
+ * |
+ * [maxResults] - 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) |
+ * |
+ * [orderBy] - Sorts list results by a certain order. By default, results are |
+ * returned in alphanumerical order based on the resource name. |
+ * |
+ * You can also sort results in descending order based on the creation |
+ * timestamp using orderBy="creationTimestamp desc". 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. |
+ * |
+ * Currently, only sorting by name or creationTimestamp desc is supported. |
+ * |
+ * [pageToken] - Specifies a page token to use. Set pageToken to the |
+ * nextPageToken returned by a previous list request to get the next page of |
+ * results. |
+ * |
+ * Completes with a [AcceleratorTypeList]. |
+ * |
+ * Completes with a [commons.ApiRequestError] if the API endpoint returned an |
+ * error. |
+ * |
+ * If the used [http.Client] completes with an error when making a REST call, |
+ * this method will complete with the same error. |
+ */ |
+ async.Future<AcceleratorTypeList> list(core.String project, core.String zone, {core.String filter, core.int maxResults, core.String orderBy, core.String pageToken}) { |
+ var _url = null; |
+ var _queryParams = new core.Map(); |
+ var _uploadMedia = null; |
+ var _uploadOptions = null; |
+ var _downloadOptions = commons.DownloadOptions.Metadata; |
+ var _body = null; |
+ |
+ if (project == null) { |
+ throw new core.ArgumentError("Parameter project is required."); |
+ } |
+ if (zone == null) { |
+ throw new core.ArgumentError("Parameter zone is required."); |
+ } |
+ if (filter != null) { |
+ _queryParams["filter"] = [filter]; |
+ } |
+ if (maxResults != null) { |
+ _queryParams["maxResults"] = ["${maxResults}"]; |
+ } |
+ if (orderBy != null) { |
+ _queryParams["orderBy"] = [orderBy]; |
+ } |
+ if (pageToken != null) { |
+ _queryParams["pageToken"] = [pageToken]; |
+ } |
+ |
+ _url = commons.Escaper.ecapeVariable('$project') + '/zones/' + commons.Escaper.ecapeVariable('$zone') + '/acceleratorTypes'; |
+ |
+ var _response = _requester.request(_url, |
+ "GET", |
+ body: _body, |
+ queryParams: _queryParams, |
+ uploadOptions: _uploadOptions, |
+ uploadMedia: _uploadMedia, |
+ downloadOptions: _downloadOptions); |
+ return _response.then((data) => new AcceleratorTypeList.fromJson(data)); |
+ } |
+ |
+} |
+ |
+ |
class AddressesResourceApi { |
final commons.ApiRequester _requester; |
@@ -832,7 +1101,8 @@ class AutoscalersResourceApi { |
/** |
* Updates an autoscaler in the specified project using the data included in |
- * the request. This method supports patch semantics. |
+ * the request. This method supports PATCH semantics and uses the JSON merge |
+ * patch format and processing rules. |
* |
* [request] - The metadata request object. |
* |
@@ -1201,7 +1471,8 @@ class BackendBucketsResourceApi { |
/** |
* Updates the specified BackendBucket resource with the data included in the |
- * request. This method supports patch semantics. |
+ * request. This method supports PATCH semantics and uses the JSON merge patch |
+ * format and processing rules. |
* |
* [request] - The metadata request object. |
* |
@@ -1715,7 +1986,8 @@ class BackendServicesResourceApi { |
* Patches the specified BackendService resource with the data included in the |
* request. There are several restrictions and guidelines to keep in mind when |
* updating a backend service. Read Restrictions and Guidelines for more |
- * information. This method supports patch semantics. |
+ * information. This method supports PATCH semantics and uses the JSON merge |
+ * patch format and processing rules. |
* |
* [request] - The metadata request object. |
* |
@@ -4553,7 +4825,8 @@ class HealthChecksResourceApi { |
/** |
* Updates a HealthCheck resource in the specified project using the data |
- * included in the request. This method supports patch semantics. |
+ * included in the request. This method supports PATCH semantics and uses the |
+ * JSON merge patch format and processing rules. |
* |
* [request] - The metadata request object. |
* |
@@ -4910,7 +5183,8 @@ class HttpHealthChecksResourceApi { |
/** |
* Updates a HttpHealthCheck resource in the specified project using the data |
- * included in the request. This method supports patch semantics. |
+ * included in the request. This method supports PATCH semantics and uses the |
+ * JSON merge patch format and processing rules. |
* |
* [request] - The metadata request object. |
* |
@@ -5267,7 +5541,8 @@ class HttpsHealthChecksResourceApi { |
/** |
* Updates a HttpsHealthCheck resource in the specified project using the data |
- * included in the request. This method supports patch semantics. |
+ * included in the request. This method supports PATCH semantics and uses the |
+ * JSON merge patch format and processing rules. |
* |
* [request] - The metadata request object. |
* |
@@ -5589,6 +5864,8 @@ class ImagesResourceApi { |
* Value must have pattern |
* "(?:(?:[-a-z0-9]{1,63}\.)*(?:[a-z](?:[-a-z0-9]{0,61}[a-z0-9])?):)?(?:[0-9]{1,19}|(?:[a-z0-9](?:[-a-z0-9]{0,61}[a-z0-9])?))". |
* |
+ * [forceCreate] - Force image creation if true. |
+ * |
* Completes with a [Operation]. |
* |
* Completes with a [commons.ApiRequestError] if the API endpoint returned an |
@@ -5597,7 +5874,7 @@ class ImagesResourceApi { |
* If the used [http.Client] completes with an error when making a REST call, |
* this method will complete with the same error. |
*/ |
- async.Future<Operation> insert(Image request, core.String project) { |
+ async.Future<Operation> insert(Image request, core.String project, {core.bool forceCreate}) { |
var _url = null; |
var _queryParams = new core.Map(); |
var _uploadMedia = null; |
@@ -5611,6 +5888,9 @@ class ImagesResourceApi { |
if (project == null) { |
throw new core.ArgumentError("Parameter project is required."); |
} |
+ if (forceCreate != null) { |
+ _queryParams["forceCreate"] = ["${forceCreate}"]; |
+ } |
_url = commons.Escaper.ecapeVariable('$project') + '/global/images'; |
@@ -8417,8 +8697,8 @@ class InstancesResourceApi { |
} |
/** |
- * Changes the machine type for a stopped instance to the machine type |
- * specified in the request. |
+ * Changes the number and/or type of accelerator for a stopped instance to the |
+ * values specified in the request. |
* |
* [request] - The metadata request object. |
* |
@@ -8442,7 +8722,7 @@ class InstancesResourceApi { |
* If the used [http.Client] completes with an error when making a REST call, |
* this method will complete with the same error. |
*/ |
- async.Future<Operation> setMachineType(InstancesSetMachineTypeRequest request, core.String project, core.String zone, core.String instance) { |
+ async.Future<Operation> setMachineResources(InstancesSetMachineResourcesRequest request, core.String project, core.String zone, core.String instance) { |
var _url = null; |
var _queryParams = new core.Map(); |
var _uploadMedia = null; |
@@ -8463,7 +8743,7 @@ class InstancesResourceApi { |
throw new core.ArgumentError("Parameter instance is required."); |
} |
- _url = commons.Escaper.ecapeVariable('$project') + '/zones/' + commons.Escaper.ecapeVariable('$zone') + '/instances/' + commons.Escaper.ecapeVariable('$instance') + '/setMachineType'; |
+ _url = commons.Escaper.ecapeVariable('$project') + '/zones/' + commons.Escaper.ecapeVariable('$zone') + '/instances/' + commons.Escaper.ecapeVariable('$instance') + '/setMachineResources'; |
var _response = _requester.request(_url, |
"POST", |
@@ -8476,9 +8756,68 @@ class InstancesResourceApi { |
} |
/** |
- * Sets metadata for the specified instance to the data included in the |
- * request. |
- * |
+ * Changes the machine type for a stopped instance to the machine type |
+ * specified in the request. |
+ * |
+ * [request] - The metadata request object. |
+ * |
+ * Request parameters: |
+ * |
+ * [project] - Project ID for this request. |
+ * Value must have pattern |
+ * "(?:(?:[-a-z0-9]{1,63}\.)*(?:[a-z](?:[-a-z0-9]{0,61}[a-z0-9])?):)?(?:[0-9]{1,19}|(?:[a-z0-9](?:[-a-z0-9]{0,61}[a-z0-9])?))". |
+ * |
+ * [zone] - The name of the zone for this request. |
+ * Value must have pattern "[a-z](?:[-a-z0-9]{0,61}[a-z0-9])?". |
+ * |
+ * [instance] - Name of the instance scoping this request. |
+ * Value must have pattern "[a-z](?:[-a-z0-9]{0,61}[a-z0-9])?". |
+ * |
+ * Completes with a [Operation]. |
+ * |
+ * Completes with a [commons.ApiRequestError] if the API endpoint returned an |
+ * error. |
+ * |
+ * If the used [http.Client] completes with an error when making a REST call, |
+ * this method will complete with the same error. |
+ */ |
+ async.Future<Operation> setMachineType(InstancesSetMachineTypeRequest request, core.String project, core.String zone, core.String instance) { |
+ var _url = null; |
+ var _queryParams = new core.Map(); |
+ var _uploadMedia = null; |
+ var _uploadOptions = null; |
+ var _downloadOptions = commons.DownloadOptions.Metadata; |
+ var _body = null; |
+ |
+ if (request != null) { |
+ _body = convert.JSON.encode((request).toJson()); |
+ } |
+ if (project == null) { |
+ throw new core.ArgumentError("Parameter project is required."); |
+ } |
+ if (zone == null) { |
+ throw new core.ArgumentError("Parameter zone is required."); |
+ } |
+ if (instance == null) { |
+ throw new core.ArgumentError("Parameter instance is required."); |
+ } |
+ |
+ _url = commons.Escaper.ecapeVariable('$project') + '/zones/' + commons.Escaper.ecapeVariable('$zone') + '/instances/' + commons.Escaper.ecapeVariable('$instance') + '/setMachineType'; |
+ |
+ var _response = _requester.request(_url, |
+ "POST", |
+ body: _body, |
+ queryParams: _queryParams, |
+ uploadOptions: _uploadOptions, |
+ uploadMedia: _uploadMedia, |
+ downloadOptions: _downloadOptions); |
+ return _response.then((data) => new Operation.fromJson(data)); |
+ } |
+ |
+ /** |
+ * Sets metadata for the specified instance to the data included in the |
+ * request. |
+ * |
* [request] - The metadata request object. |
* |
* Request parameters: |
@@ -8890,8 +9229,7 @@ class LicensesResourceApi { |
_requester = client; |
/** |
- * Returns the specified License resource. Get a list of available licenses by |
- * making a list() request. |
+ * Returns the specified License resource. |
* |
* Request parameters: |
* |
@@ -10463,7 +10801,8 @@ class RegionAutoscalersResourceApi { |
/** |
* Updates an autoscaler in the specified project using the data included in |
- * the request. This method supports patch semantics. |
+ * the request. This method supports PATCH semantics and uses the JSON merge |
+ * patch format and processing rules. |
* |
* [request] - The metadata request object. |
* |
@@ -10918,7 +11257,8 @@ class RegionBackendServicesResourceApi { |
* Updates the specified regional BackendService resource with the data |
* included in the request. There are several restrictions and guidelines to |
* keep in mind when updating a backend service. Read Restrictions and |
- * Guidelines for more information. This method supports patch semantics. |
+ * Guidelines for more information. This method supports PATCH semantics and |
+ * uses the JSON merge patch format and processing rules. |
* |
* [request] - The metadata request object. |
* |
@@ -11039,29 +11379,14 @@ class RegionBackendServicesResourceApi { |
} |
-class RegionInstanceGroupManagersResourceApi { |
+class RegionCommitmentsResourceApi { |
final commons.ApiRequester _requester; |
- RegionInstanceGroupManagersResourceApi(commons.ApiRequester client) : |
+ RegionCommitmentsResourceApi(commons.ApiRequester client) : |
_requester = client; |
/** |
- * Schedules a group action to remove the specified instances from the managed |
- * instance group. Abandoning an instance does not delete the instance, but it |
- * does remove the instance from any target pools that are applied by the |
- * managed instance group. This method reduces the targetSize of the managed |
- * instance group by the number of instances that you abandon. This operation |
- * is marked as DONE when the action is scheduled even if the instances have |
- * not yet been removed from the group. You must separately verify the status |
- * of the abandoning action with the listmanagedinstances method. |
- * |
- * If the group is part of a backend service that has enabled connection |
- * draining, it can take up to 60 seconds after the connection draining |
- * duration has elapsed before the VM instance is removed or deleted. |
- * |
- * You can specify a maximum of 1000 instances with this method per request. |
- * |
- * [request] - The metadata request object. |
+ * Retrieves an aggregated list of commitments. |
* |
* Request parameters: |
* |
@@ -11069,11 +11394,53 @@ class RegionInstanceGroupManagersResourceApi { |
* Value must have pattern |
* "(?:(?:[-a-z0-9]{1,63}\.)*(?:[a-z](?:[-a-z0-9]{0,61}[a-z0-9])?):)?(?:[0-9]{1,19}|(?:[a-z0-9](?:[-a-z0-9]{0,61}[a-z0-9])?))". |
* |
- * [region] - Name of the region scoping this request. |
+ * [filter] - Sets a filter {expression} for filtering listed resources. Your |
+ * {expression} must be in the format: field_name comparison_string |
+ * literal_string. |
* |
- * [instanceGroupManager] - Name of the managed instance group. |
+ * The field_name is the name of the field you want to compare. Only atomic |
+ * field types are supported (string, number, boolean). The comparison_string |
+ * must be either eq (equals) or ne (not equals). The literal_string is the |
+ * string value to filter to. The literal value must be valid for the type of |
+ * field you are filtering by (string, number, boolean). For string fields, |
+ * the literal value is interpreted as a regular expression using RE2 syntax. |
+ * The literal value must match the entire field. |
* |
- * Completes with a [Operation]. |
+ * For example, to filter for instances that do not have a name of |
+ * example-instance, you would use name ne example-instance. |
+ * |
+ * You can filter on nested fields. For example, you could filter on instances |
+ * that have set the scheduling.automaticRestart field to true. Use filtering |
+ * on nested fields to take advantage of labels to organize and search for |
+ * results based on label values. |
+ * |
+ * To filter on multiple expressions, provide each separate expression within |
+ * parentheses. For example, (scheduling.automaticRestart eq true) (zone eq |
+ * us-central1-f). Multiple expressions are treated as AND expressions, |
+ * meaning that resources must match all expressions to pass the filters. |
+ * |
+ * [maxResults] - 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) |
+ * |
+ * [orderBy] - Sorts list results by a certain order. By default, results are |
+ * returned in alphanumerical order based on the resource name. |
+ * |
+ * You can also sort results in descending order based on the creation |
+ * timestamp using orderBy="creationTimestamp desc". 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. |
+ * |
+ * Currently, only sorting by name or creationTimestamp desc is supported. |
+ * |
+ * [pageToken] - Specifies a page token to use. Set pageToken to the |
+ * nextPageToken returned by a previous list request to get the next page of |
+ * results. |
+ * |
+ * Completes with a [CommitmentAggregatedList]. |
* |
* Completes with a [commons.ApiRequestError] if the API endpoint returned an |
* error. |
@@ -11081,7 +11448,7 @@ class RegionInstanceGroupManagersResourceApi { |
* If the used [http.Client] completes with an error when making a REST call, |
* this method will complete with the same error. |
*/ |
- async.Future<Operation> abandonInstances(RegionInstanceGroupManagersAbandonInstancesRequest request, core.String project, core.String region, core.String instanceGroupManager) { |
+ async.Future<CommitmentAggregatedList> aggregatedList(core.String project, {core.String filter, core.int maxResults, core.String orderBy, core.String pageToken}) { |
var _url = null; |
var _queryParams = new core.Map(); |
var _uploadMedia = null; |
@@ -11089,34 +11456,37 @@ class RegionInstanceGroupManagersResourceApi { |
var _downloadOptions = commons.DownloadOptions.Metadata; |
var _body = null; |
- if (request != null) { |
- _body = convert.JSON.encode((request).toJson()); |
- } |
if (project == null) { |
throw new core.ArgumentError("Parameter project is required."); |
} |
- if (region == null) { |
- throw new core.ArgumentError("Parameter region is required."); |
+ if (filter != null) { |
+ _queryParams["filter"] = [filter]; |
} |
- if (instanceGroupManager == null) { |
- throw new core.ArgumentError("Parameter instanceGroupManager is required."); |
+ if (maxResults != null) { |
+ _queryParams["maxResults"] = ["${maxResults}"]; |
+ } |
+ if (orderBy != null) { |
+ _queryParams["orderBy"] = [orderBy]; |
+ } |
+ if (pageToken != null) { |
+ _queryParams["pageToken"] = [pageToken]; |
} |
- _url = commons.Escaper.ecapeVariable('$project') + '/regions/' + commons.Escaper.ecapeVariable('$region') + '/instanceGroupManagers/' + commons.Escaper.ecapeVariable('$instanceGroupManager') + '/abandonInstances'; |
+ _url = commons.Escaper.ecapeVariable('$project') + '/aggregated/commitments'; |
var _response = _requester.request(_url, |
- "POST", |
+ "GET", |
body: _body, |
queryParams: _queryParams, |
uploadOptions: _uploadOptions, |
uploadMedia: _uploadMedia, |
downloadOptions: _downloadOptions); |
- return _response.then((data) => new Operation.fromJson(data)); |
+ return _response.then((data) => new CommitmentAggregatedList.fromJson(data)); |
} |
/** |
- * Deletes the specified managed instance group and all of the instances in |
- * that group. |
+ * Returns the specified commitment resource. Get a list of available |
+ * commitments by making a list() request. |
* |
* Request parameters: |
* |
@@ -11124,11 +11494,13 @@ class RegionInstanceGroupManagersResourceApi { |
* Value must have pattern |
* "(?:(?:[-a-z0-9]{1,63}\.)*(?:[a-z](?:[-a-z0-9]{0,61}[a-z0-9])?):)?(?:[0-9]{1,19}|(?:[a-z0-9](?:[-a-z0-9]{0,61}[a-z0-9])?))". |
* |
- * [region] - Name of the region scoping this request. |
+ * [region] - Name of the region for this request. |
+ * Value must have pattern "[a-z](?:[-a-z0-9]{0,61}[a-z0-9])?". |
* |
- * [instanceGroupManager] - Name of the managed instance group to delete. |
+ * [commitment] - Name of the commitment to return. |
+ * Value must have pattern "[a-z](?:[-a-z0-9]{0,61}[a-z0-9])?". |
* |
- * Completes with a [Operation]. |
+ * Completes with a [Commitment]. |
* |
* Completes with a [commons.ApiRequestError] if the API endpoint returned an |
* error. |
@@ -11136,7 +11508,7 @@ class RegionInstanceGroupManagersResourceApi { |
* If the used [http.Client] completes with an error when making a REST call, |
* this method will complete with the same error. |
*/ |
- async.Future<Operation> delete(core.String project, core.String region, core.String instanceGroupManager) { |
+ async.Future<Commitment> get(core.String project, core.String region, core.String commitment) { |
var _url = null; |
var _queryParams = new core.Map(); |
var _uploadMedia = null; |
@@ -11150,36 +11522,25 @@ class RegionInstanceGroupManagersResourceApi { |
if (region == null) { |
throw new core.ArgumentError("Parameter region is required."); |
} |
- if (instanceGroupManager == null) { |
- throw new core.ArgumentError("Parameter instanceGroupManager is required."); |
+ if (commitment == null) { |
+ throw new core.ArgumentError("Parameter commitment is required."); |
} |
- _url = commons.Escaper.ecapeVariable('$project') + '/regions/' + commons.Escaper.ecapeVariable('$region') + '/instanceGroupManagers/' + commons.Escaper.ecapeVariable('$instanceGroupManager'); |
+ _url = commons.Escaper.ecapeVariable('$project') + '/regions/' + commons.Escaper.ecapeVariable('$region') + '/commitments/' + commons.Escaper.ecapeVariable('$commitment'); |
var _response = _requester.request(_url, |
- "DELETE", |
+ "GET", |
body: _body, |
queryParams: _queryParams, |
uploadOptions: _uploadOptions, |
uploadMedia: _uploadMedia, |
downloadOptions: _downloadOptions); |
- return _response.then((data) => new Operation.fromJson(data)); |
+ return _response.then((data) => new Commitment.fromJson(data)); |
} |
/** |
- * Schedules a group action to delete the specified instances in the managed |
- * instance group. The instances are also removed from any target pools of |
- * which they were a member. This method reduces the targetSize of the managed |
- * instance group by the number of instances that you delete. This operation |
- * is marked as DONE when the action is scheduled even if the instances are |
- * still being deleted. You must separately verify the status of the deleting |
- * action with the listmanagedinstances method. |
- * |
- * If the group is part of a backend service that has enabled connection |
- * draining, it can take up to 60 seconds after the connection draining |
- * duration has elapsed before the VM instance is removed or deleted. |
- * |
- * You can specify a maximum of 1000 instances with this method per request. |
+ * Creates a commitment in the specified project using the data included in |
+ * the request. |
* |
* [request] - The metadata request object. |
* |
@@ -11189,9 +11550,8 @@ class RegionInstanceGroupManagersResourceApi { |
* Value must have pattern |
* "(?:(?:[-a-z0-9]{1,63}\.)*(?:[a-z](?:[-a-z0-9]{0,61}[a-z0-9])?):)?(?:[0-9]{1,19}|(?:[a-z0-9](?:[-a-z0-9]{0,61}[a-z0-9])?))". |
* |
- * [region] - Name of the region scoping this request. |
- * |
- * [instanceGroupManager] - Name of the managed instance group. |
+ * [region] - Name of the region for this request. |
+ * Value must have pattern "[a-z](?:[-a-z0-9]{0,61}[a-z0-9])?". |
* |
* Completes with a [Operation]. |
* |
@@ -11201,7 +11561,7 @@ class RegionInstanceGroupManagersResourceApi { |
* If the used [http.Client] completes with an error when making a REST call, |
* this method will complete with the same error. |
*/ |
- async.Future<Operation> deleteInstances(RegionInstanceGroupManagersDeleteInstancesRequest request, core.String project, core.String region, core.String instanceGroupManager) { |
+ async.Future<Operation> insert(Commitment request, core.String project, core.String region) { |
var _url = null; |
var _queryParams = new core.Map(); |
var _uploadMedia = null; |
@@ -11218,11 +11578,8 @@ class RegionInstanceGroupManagersResourceApi { |
if (region == null) { |
throw new core.ArgumentError("Parameter region is required."); |
} |
- if (instanceGroupManager == null) { |
- throw new core.ArgumentError("Parameter instanceGroupManager is required."); |
- } |
- _url = commons.Escaper.ecapeVariable('$project') + '/regions/' + commons.Escaper.ecapeVariable('$region') + '/instanceGroupManagers/' + commons.Escaper.ecapeVariable('$instanceGroupManager') + '/deleteInstances'; |
+ _url = commons.Escaper.ecapeVariable('$project') + '/regions/' + commons.Escaper.ecapeVariable('$region') + '/commitments'; |
var _response = _requester.request(_url, |
"POST", |
@@ -11235,7 +11592,7 @@ class RegionInstanceGroupManagersResourceApi { |
} |
/** |
- * Returns all of the details about the specified managed instance group. |
+ * Retrieves a list of commitments contained within the specified region. |
* |
* Request parameters: |
* |
@@ -11243,11 +11600,56 @@ class RegionInstanceGroupManagersResourceApi { |
* Value must have pattern |
* "(?:(?:[-a-z0-9]{1,63}\.)*(?:[a-z](?:[-a-z0-9]{0,61}[a-z0-9])?):)?(?:[0-9]{1,19}|(?:[a-z0-9](?:[-a-z0-9]{0,61}[a-z0-9])?))". |
* |
- * [region] - Name of the region scoping this request. |
+ * [region] - Name of the region for this request. |
+ * Value must have pattern "[a-z](?:[-a-z0-9]{0,61}[a-z0-9])?". |
* |
- * [instanceGroupManager] - Name of the managed instance group to return. |
+ * [filter] - Sets a filter {expression} for filtering listed resources. Your |
+ * {expression} must be in the format: field_name comparison_string |
+ * literal_string. |
* |
- * Completes with a [InstanceGroupManager]. |
+ * The field_name is the name of the field you want to compare. Only atomic |
+ * field types are supported (string, number, boolean). The comparison_string |
+ * must be either eq (equals) or ne (not equals). The literal_string is the |
+ * string value to filter to. The literal value must be valid for the type of |
+ * field you are filtering by (string, number, boolean). For string fields, |
+ * the literal value is interpreted as a regular expression using RE2 syntax. |
+ * The literal value must match the entire field. |
+ * |
+ * For example, to filter for instances that do not have a name of |
+ * example-instance, you would use name ne example-instance. |
+ * |
+ * You can filter on nested fields. For example, you could filter on instances |
+ * that have set the scheduling.automaticRestart field to true. Use filtering |
+ * on nested fields to take advantage of labels to organize and search for |
+ * results based on label values. |
+ * |
+ * To filter on multiple expressions, provide each separate expression within |
+ * parentheses. For example, (scheduling.automaticRestart eq true) (zone eq |
+ * us-central1-f). Multiple expressions are treated as AND expressions, |
+ * meaning that resources must match all expressions to pass the filters. |
+ * |
+ * [maxResults] - 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) |
+ * |
+ * [orderBy] - Sorts list results by a certain order. By default, results are |
+ * returned in alphanumerical order based on the resource name. |
+ * |
+ * You can also sort results in descending order based on the creation |
+ * timestamp using orderBy="creationTimestamp desc". 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. |
+ * |
+ * Currently, only sorting by name or creationTimestamp desc is supported. |
+ * |
+ * [pageToken] - Specifies a page token to use. Set pageToken to the |
+ * nextPageToken returned by a previous list request to get the next page of |
+ * results. |
+ * |
+ * Completes with a [CommitmentList]. |
* |
* Completes with a [commons.ApiRequestError] if the API endpoint returned an |
* error. |
@@ -11255,7 +11657,7 @@ class RegionInstanceGroupManagersResourceApi { |
* If the used [http.Client] completes with an error when making a REST call, |
* this method will complete with the same error. |
*/ |
- async.Future<InstanceGroupManager> get(core.String project, core.String region, core.String instanceGroupManager) { |
+ async.Future<CommitmentList> list(core.String project, core.String region, {core.String filter, core.int maxResults, core.String orderBy, core.String pageToken}) { |
var _url = null; |
var _queryParams = new core.Map(); |
var _uploadMedia = null; |
@@ -11269,11 +11671,20 @@ class RegionInstanceGroupManagersResourceApi { |
if (region == null) { |
throw new core.ArgumentError("Parameter region is required."); |
} |
- if (instanceGroupManager == null) { |
- throw new core.ArgumentError("Parameter instanceGroupManager is required."); |
+ if (filter != null) { |
+ _queryParams["filter"] = [filter]; |
+ } |
+ if (maxResults != null) { |
+ _queryParams["maxResults"] = ["${maxResults}"]; |
+ } |
+ if (orderBy != null) { |
+ _queryParams["orderBy"] = [orderBy]; |
+ } |
+ if (pageToken != null) { |
+ _queryParams["pageToken"] = [pageToken]; |
} |
- _url = commons.Escaper.ecapeVariable('$project') + '/regions/' + commons.Escaper.ecapeVariable('$region') + '/instanceGroupManagers/' + commons.Escaper.ecapeVariable('$instanceGroupManager'); |
+ _url = commons.Escaper.ecapeVariable('$project') + '/regions/' + commons.Escaper.ecapeVariable('$region') + '/commitments'; |
var _response = _requester.request(_url, |
"GET", |
@@ -11282,7 +11693,256 @@ class RegionInstanceGroupManagersResourceApi { |
uploadOptions: _uploadOptions, |
uploadMedia: _uploadMedia, |
downloadOptions: _downloadOptions); |
- return _response.then((data) => new InstanceGroupManager.fromJson(data)); |
+ return _response.then((data) => new CommitmentList.fromJson(data)); |
+ } |
+ |
+} |
+ |
+ |
+class RegionInstanceGroupManagersResourceApi { |
+ final commons.ApiRequester _requester; |
+ |
+ RegionInstanceGroupManagersResourceApi(commons.ApiRequester client) : |
+ _requester = client; |
+ |
+ /** |
+ * Schedules a group action to remove the specified instances from the managed |
+ * instance group. Abandoning an instance does not delete the instance, but it |
+ * does remove the instance from any target pools that are applied by the |
+ * managed instance group. This method reduces the targetSize of the managed |
+ * instance group by the number of instances that you abandon. This operation |
+ * is marked as DONE when the action is scheduled even if the instances have |
+ * not yet been removed from the group. You must separately verify the status |
+ * of the abandoning action with the listmanagedinstances method. |
+ * |
+ * If the group is part of a backend service that has enabled connection |
+ * draining, it can take up to 60 seconds after the connection draining |
+ * duration has elapsed before the VM instance is removed or deleted. |
+ * |
+ * You can specify a maximum of 1000 instances with this method per request. |
+ * |
+ * [request] - The metadata request object. |
+ * |
+ * Request parameters: |
+ * |
+ * [project] - Project ID for this request. |
+ * Value must have pattern |
+ * "(?:(?:[-a-z0-9]{1,63}\.)*(?:[a-z](?:[-a-z0-9]{0,61}[a-z0-9])?):)?(?:[0-9]{1,19}|(?:[a-z0-9](?:[-a-z0-9]{0,61}[a-z0-9])?))". |
+ * |
+ * [region] - Name of the region scoping this request. |
+ * |
+ * [instanceGroupManager] - Name of the managed instance group. |
+ * |
+ * Completes with a [Operation]. |
+ * |
+ * Completes with a [commons.ApiRequestError] if the API endpoint returned an |
+ * error. |
+ * |
+ * If the used [http.Client] completes with an error when making a REST call, |
+ * this method will complete with the same error. |
+ */ |
+ async.Future<Operation> abandonInstances(RegionInstanceGroupManagersAbandonInstancesRequest request, core.String project, core.String region, core.String instanceGroupManager) { |
+ var _url = null; |
+ var _queryParams = new core.Map(); |
+ var _uploadMedia = null; |
+ var _uploadOptions = null; |
+ var _downloadOptions = commons.DownloadOptions.Metadata; |
+ var _body = null; |
+ |
+ if (request != null) { |
+ _body = convert.JSON.encode((request).toJson()); |
+ } |
+ if (project == null) { |
+ throw new core.ArgumentError("Parameter project is required."); |
+ } |
+ if (region == null) { |
+ throw new core.ArgumentError("Parameter region is required."); |
+ } |
+ if (instanceGroupManager == null) { |
+ throw new core.ArgumentError("Parameter instanceGroupManager is required."); |
+ } |
+ |
+ _url = commons.Escaper.ecapeVariable('$project') + '/regions/' + commons.Escaper.ecapeVariable('$region') + '/instanceGroupManagers/' + commons.Escaper.ecapeVariable('$instanceGroupManager') + '/abandonInstances'; |
+ |
+ var _response = _requester.request(_url, |
+ "POST", |
+ body: _body, |
+ queryParams: _queryParams, |
+ uploadOptions: _uploadOptions, |
+ uploadMedia: _uploadMedia, |
+ downloadOptions: _downloadOptions); |
+ return _response.then((data) => new Operation.fromJson(data)); |
+ } |
+ |
+ /** |
+ * Deletes the specified managed instance group and all of the instances in |
+ * that group. |
+ * |
+ * Request parameters: |
+ * |
+ * [project] - Project ID for this request. |
+ * Value must have pattern |
+ * "(?:(?:[-a-z0-9]{1,63}\.)*(?:[a-z](?:[-a-z0-9]{0,61}[a-z0-9])?):)?(?:[0-9]{1,19}|(?:[a-z0-9](?:[-a-z0-9]{0,61}[a-z0-9])?))". |
+ * |
+ * [region] - Name of the region scoping this request. |
+ * |
+ * [instanceGroupManager] - Name of the managed instance group to delete. |
+ * |
+ * Completes with a [Operation]. |
+ * |
+ * Completes with a [commons.ApiRequestError] if the API endpoint returned an |
+ * error. |
+ * |
+ * If the used [http.Client] completes with an error when making a REST call, |
+ * this method will complete with the same error. |
+ */ |
+ async.Future<Operation> delete(core.String project, core.String region, core.String instanceGroupManager) { |
+ var _url = null; |
+ var _queryParams = new core.Map(); |
+ var _uploadMedia = null; |
+ var _uploadOptions = null; |
+ var _downloadOptions = commons.DownloadOptions.Metadata; |
+ var _body = null; |
+ |
+ if (project == null) { |
+ throw new core.ArgumentError("Parameter project is required."); |
+ } |
+ if (region == null) { |
+ throw new core.ArgumentError("Parameter region is required."); |
+ } |
+ if (instanceGroupManager == null) { |
+ throw new core.ArgumentError("Parameter instanceGroupManager is required."); |
+ } |
+ |
+ _url = commons.Escaper.ecapeVariable('$project') + '/regions/' + commons.Escaper.ecapeVariable('$region') + '/instanceGroupManagers/' + commons.Escaper.ecapeVariable('$instanceGroupManager'); |
+ |
+ var _response = _requester.request(_url, |
+ "DELETE", |
+ body: _body, |
+ queryParams: _queryParams, |
+ uploadOptions: _uploadOptions, |
+ uploadMedia: _uploadMedia, |
+ downloadOptions: _downloadOptions); |
+ return _response.then((data) => new Operation.fromJson(data)); |
+ } |
+ |
+ /** |
+ * Schedules a group action to delete the specified instances in the managed |
+ * instance group. The instances are also removed from any target pools of |
+ * which they were a member. This method reduces the targetSize of the managed |
+ * instance group by the number of instances that you delete. This operation |
+ * is marked as DONE when the action is scheduled even if the instances are |
+ * still being deleted. You must separately verify the status of the deleting |
+ * action with the listmanagedinstances method. |
+ * |
+ * If the group is part of a backend service that has enabled connection |
+ * draining, it can take up to 60 seconds after the connection draining |
+ * duration has elapsed before the VM instance is removed or deleted. |
+ * |
+ * You can specify a maximum of 1000 instances with this method per request. |
+ * |
+ * [request] - The metadata request object. |
+ * |
+ * Request parameters: |
+ * |
+ * [project] - Project ID for this request. |
+ * Value must have pattern |
+ * "(?:(?:[-a-z0-9]{1,63}\.)*(?:[a-z](?:[-a-z0-9]{0,61}[a-z0-9])?):)?(?:[0-9]{1,19}|(?:[a-z0-9](?:[-a-z0-9]{0,61}[a-z0-9])?))". |
+ * |
+ * [region] - Name of the region scoping this request. |
+ * |
+ * [instanceGroupManager] - Name of the managed instance group. |
+ * |
+ * Completes with a [Operation]. |
+ * |
+ * Completes with a [commons.ApiRequestError] if the API endpoint returned an |
+ * error. |
+ * |
+ * If the used [http.Client] completes with an error when making a REST call, |
+ * this method will complete with the same error. |
+ */ |
+ async.Future<Operation> deleteInstances(RegionInstanceGroupManagersDeleteInstancesRequest request, core.String project, core.String region, core.String instanceGroupManager) { |
+ var _url = null; |
+ var _queryParams = new core.Map(); |
+ var _uploadMedia = null; |
+ var _uploadOptions = null; |
+ var _downloadOptions = commons.DownloadOptions.Metadata; |
+ var _body = null; |
+ |
+ if (request != null) { |
+ _body = convert.JSON.encode((request).toJson()); |
+ } |
+ if (project == null) { |
+ throw new core.ArgumentError("Parameter project is required."); |
+ } |
+ if (region == null) { |
+ throw new core.ArgumentError("Parameter region is required."); |
+ } |
+ if (instanceGroupManager == null) { |
+ throw new core.ArgumentError("Parameter instanceGroupManager is required."); |
+ } |
+ |
+ _url = commons.Escaper.ecapeVariable('$project') + '/regions/' + commons.Escaper.ecapeVariable('$region') + '/instanceGroupManagers/' + commons.Escaper.ecapeVariable('$instanceGroupManager') + '/deleteInstances'; |
+ |
+ var _response = _requester.request(_url, |
+ "POST", |
+ body: _body, |
+ queryParams: _queryParams, |
+ uploadOptions: _uploadOptions, |
+ uploadMedia: _uploadMedia, |
+ downloadOptions: _downloadOptions); |
+ return _response.then((data) => new Operation.fromJson(data)); |
+ } |
+ |
+ /** |
+ * Returns all of the details about the specified managed instance group. |
+ * |
+ * Request parameters: |
+ * |
+ * [project] - Project ID for this request. |
+ * Value must have pattern |
+ * "(?:(?:[-a-z0-9]{1,63}\.)*(?:[a-z](?:[-a-z0-9]{0,61}[a-z0-9])?):)?(?:[0-9]{1,19}|(?:[a-z0-9](?:[-a-z0-9]{0,61}[a-z0-9])?))". |
+ * |
+ * [region] - Name of the region scoping this request. |
+ * |
+ * [instanceGroupManager] - Name of the managed instance group to return. |
+ * |
+ * Completes with a [InstanceGroupManager]. |
+ * |
+ * Completes with a [commons.ApiRequestError] if the API endpoint returned an |
+ * error. |
+ * |
+ * If the used [http.Client] completes with an error when making a REST call, |
+ * this method will complete with the same error. |
+ */ |
+ async.Future<InstanceGroupManager> get(core.String project, core.String region, core.String instanceGroupManager) { |
+ var _url = null; |
+ var _queryParams = new core.Map(); |
+ var _uploadMedia = null; |
+ var _uploadOptions = null; |
+ var _downloadOptions = commons.DownloadOptions.Metadata; |
+ var _body = null; |
+ |
+ if (project == null) { |
+ throw new core.ArgumentError("Parameter project is required."); |
+ } |
+ if (region == null) { |
+ throw new core.ArgumentError("Parameter region is required."); |
+ } |
+ if (instanceGroupManager == null) { |
+ throw new core.ArgumentError("Parameter instanceGroupManager is required."); |
+ } |
+ |
+ _url = commons.Escaper.ecapeVariable('$project') + '/regions/' + commons.Escaper.ecapeVariable('$region') + '/instanceGroupManagers/' + commons.Escaper.ecapeVariable('$instanceGroupManager'); |
+ |
+ var _response = _requester.request(_url, |
+ "GET", |
+ body: _body, |
+ queryParams: _queryParams, |
+ uploadOptions: _uploadOptions, |
+ uploadMedia: _uploadMedia, |
+ downloadOptions: _downloadOptions); |
+ return _response.then((data) => new InstanceGroupManager.fromJson(data)); |
} |
/** |
@@ -17552,7 +18212,8 @@ class UrlMapsResourceApi { |
/** |
* Patches the specified UrlMap resource with the data included in the |
- * request. This method supports patch semantics. |
+ * request. This method supports PATCH semantics and uses the JSON merge patch |
+ * format and processing rules. |
* |
* [request] - The metadata request object. |
* |
@@ -18466,81 +19127,50 @@ class ZonesResourceApi { |
/** |
- * An access configuration attached to an instance's network interface. Only one |
- * access config per instance is supported. |
+ * A specification of the type and number of accelerator cards attached to the |
+ * instance. |
*/ |
-class AccessConfig { |
+class AcceleratorConfig { |
+ /** The number of the guest accelerator cards exposed to this instance. */ |
+ core.int acceleratorCount; |
/** |
- * [Output Only] Type of the resource. Always compute#accessConfig for access |
- * configs. |
+ * Full or partial URL of the accelerator type resource to expose to this |
+ * instance. |
*/ |
- core.String kind; |
- /** |
- * The name of this access configuration. The default and recommended name is |
- * External NAT but you can use any arbitrary string you would like. For |
- * example, My external IP or Network Access. |
- */ |
- core.String name; |
- /** |
- * An external IP address associated with this instance. Specify an unused |
- * static external IP address available to the project or leave this field |
- * undefined to use an IP from a shared ephemeral IP address pool. If you |
- * specify a static external IP address, it must live in the same region as |
- * the zone of the instance. |
- */ |
- core.String natIP; |
- /** |
- * The type of configuration. The default and only option is ONE_TO_ONE_NAT. |
- * Possible string values are: |
- * - "ONE_TO_ONE_NAT" |
- */ |
- core.String type; |
+ core.String acceleratorType; |
- AccessConfig(); |
+ AcceleratorConfig(); |
- AccessConfig.fromJson(core.Map _json) { |
- if (_json.containsKey("kind")) { |
- kind = _json["kind"]; |
- } |
- if (_json.containsKey("name")) { |
- name = _json["name"]; |
+ AcceleratorConfig.fromJson(core.Map _json) { |
+ if (_json.containsKey("acceleratorCount")) { |
+ acceleratorCount = _json["acceleratorCount"]; |
} |
- if (_json.containsKey("natIP")) { |
- natIP = _json["natIP"]; |
- } |
- if (_json.containsKey("type")) { |
- type = _json["type"]; |
+ if (_json.containsKey("acceleratorType")) { |
+ acceleratorType = _json["acceleratorType"]; |
} |
} |
core.Map<core.String, core.Object> toJson() { |
final core.Map<core.String, core.Object> _json = new core.Map<core.String, core.Object>(); |
- if (kind != null) { |
- _json["kind"] = kind; |
- } |
- if (name != null) { |
- _json["name"] = name; |
- } |
- if (natIP != null) { |
- _json["natIP"] = natIP; |
+ if (acceleratorCount != null) { |
+ _json["acceleratorCount"] = acceleratorCount; |
} |
- if (type != null) { |
- _json["type"] = type; |
+ if (acceleratorType != null) { |
+ _json["acceleratorType"] = acceleratorType; |
} |
return _json; |
} |
} |
-/** A reserved address resource. */ |
-class Address { |
- /** The static external IP address represented by this resource. */ |
- core.String address; |
+/** An Accelerator Type resource. */ |
+class AcceleratorType { |
/** [Output Only] Creation timestamp in RFC3339 text format. */ |
core.String creationTimestamp; |
/** |
- * An optional description of this resource. Provide this property when you |
- * create the resource. |
+ * [Output Only] The deprecation status associated with this accelerator type. |
*/ |
+ DeprecationStatus deprecated; |
+ /** [Output Only] An optional textual description of the resource. */ |
core.String description; |
/** |
* [Output Only] The unique identifier for the resource. This identifier is |
@@ -18548,135 +19178,99 @@ class Address { |
*/ |
core.String id; |
/** |
- * The IP Version that will be used by this address. Valid options are IPV4 or |
- * IPV6. This can only be specified for a global address. |
- * Possible string values are: |
- * - "IPV4" |
- * - "IPV6" |
- * - "UNSPECIFIED_VERSION" |
- */ |
- core.String ipVersion; |
- /** |
- * [Output Only] Type of the resource. Always compute#address for addresses. |
+ * [Output Only] The type of the resource. Always compute#acceleratorType for |
+ * accelerator types. |
*/ |
core.String kind; |
- /** |
- * 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. |
- */ |
+ /** [Output Only] Maximum accelerator cards allowed per instance. */ |
+ core.int maximumCardsPerInstance; |
+ /** [Output Only] Name of the resource. */ |
core.String name; |
- /** |
- * [Output Only] URL of the region where the regional address resides. This |
- * field is not applicable to global addresses. |
- */ |
- core.String region; |
- /** [Output Only] Server-defined URL for the resource. */ |
+ /** [Output Only] Server-defined fully-qualified URL for this resource. */ |
core.String selfLink; |
/** |
- * [Output Only] The status of the address, which can be either IN_USE or |
- * RESERVED. An address that is RESERVED is currently reserved and available |
- * to use. An IN_USE address is currently being used by another resource and |
- * is not available. |
- * Possible string values are: |
- * - "IN_USE" |
- * - "RESERVED" |
+ * [Output Only] The name of the zone where the accelerator type resides, such |
+ * as us-central1-a. |
*/ |
- core.String status; |
- /** [Output Only] The URLs of the resources that are using this address. */ |
- core.List<core.String> users; |
+ core.String zone; |
- Address(); |
+ AcceleratorType(); |
- Address.fromJson(core.Map _json) { |
- if (_json.containsKey("address")) { |
- address = _json["address"]; |
- } |
+ AcceleratorType.fromJson(core.Map _json) { |
if (_json.containsKey("creationTimestamp")) { |
creationTimestamp = _json["creationTimestamp"]; |
} |
+ if (_json.containsKey("deprecated")) { |
+ deprecated = new DeprecationStatus.fromJson(_json["deprecated"]); |
+ } |
if (_json.containsKey("description")) { |
description = _json["description"]; |
} |
if (_json.containsKey("id")) { |
id = _json["id"]; |
} |
- if (_json.containsKey("ipVersion")) { |
- ipVersion = _json["ipVersion"]; |
- } |
if (_json.containsKey("kind")) { |
kind = _json["kind"]; |
} |
+ if (_json.containsKey("maximumCardsPerInstance")) { |
+ maximumCardsPerInstance = _json["maximumCardsPerInstance"]; |
+ } |
if (_json.containsKey("name")) { |
name = _json["name"]; |
} |
- if (_json.containsKey("region")) { |
- region = _json["region"]; |
- } |
if (_json.containsKey("selfLink")) { |
selfLink = _json["selfLink"]; |
} |
- if (_json.containsKey("status")) { |
- status = _json["status"]; |
- } |
- if (_json.containsKey("users")) { |
- users = _json["users"]; |
+ if (_json.containsKey("zone")) { |
+ zone = _json["zone"]; |
} |
} |
core.Map<core.String, core.Object> toJson() { |
final core.Map<core.String, core.Object> _json = new core.Map<core.String, core.Object>(); |
- if (address != null) { |
- _json["address"] = address; |
- } |
if (creationTimestamp != null) { |
_json["creationTimestamp"] = creationTimestamp; |
} |
+ if (deprecated != null) { |
+ _json["deprecated"] = (deprecated).toJson(); |
+ } |
if (description != null) { |
_json["description"] = description; |
} |
if (id != null) { |
_json["id"] = id; |
} |
- if (ipVersion != null) { |
- _json["ipVersion"] = ipVersion; |
- } |
if (kind != null) { |
_json["kind"] = kind; |
} |
+ if (maximumCardsPerInstance != null) { |
+ _json["maximumCardsPerInstance"] = maximumCardsPerInstance; |
+ } |
if (name != null) { |
_json["name"] = name; |
} |
- if (region != null) { |
- _json["region"] = region; |
- } |
if (selfLink != null) { |
_json["selfLink"] = selfLink; |
} |
- if (status != null) { |
- _json["status"] = status; |
- } |
- if (users != null) { |
- _json["users"] = users; |
+ if (zone != null) { |
+ _json["zone"] = zone; |
} |
return _json; |
} |
} |
-class AddressAggregatedList { |
+class AcceleratorTypeAggregatedList { |
/** |
- * [Output Only] Unique identifier for the resource; defined by the server. |
+ * [Output Only] The unique identifier for the resource. This identifier is |
+ * defined by the server. |
*/ |
core.String id; |
- /** [Output Only] A map of scoped address lists. */ |
- core.Map<core.String, AddressesScopedList> items; |
+ /** [Output Only] A map of scoped accelerator type lists. */ |
+ core.Map<core.String, AcceleratorTypesScopedList> items; |
/** |
- * [Output Only] Type of resource. Always compute#addressAggregatedList for |
- * aggregated lists of addresses. |
+ * [Output Only] Type of resource. Always |
+ * compute#acceleratorTypeAggregatedList for aggregated lists of accelerator |
+ * types. |
*/ |
core.String kind; |
/** |
@@ -18690,14 +19284,14 @@ class AddressAggregatedList { |
/** [Output Only] Server-defined URL for this resource. */ |
core.String selfLink; |
- AddressAggregatedList(); |
+ AcceleratorTypeAggregatedList(); |
- AddressAggregatedList.fromJson(core.Map _json) { |
+ AcceleratorTypeAggregatedList.fromJson(core.Map _json) { |
if (_json.containsKey("id")) { |
id = _json["id"]; |
} |
if (_json.containsKey("items")) { |
- items = commons.mapMap<core.Map<core.String, core.Object>, AddressesScopedList>(_json["items"], (core.Map<core.String, core.Object> item) => new AddressesScopedList.fromJson(item)); |
+ items = commons.mapMap<core.Map<core.String, core.Object>, AcceleratorTypesScopedList>(_json["items"], (core.Map<core.String, core.Object> item) => new AcceleratorTypesScopedList.fromJson(item)); |
} |
if (_json.containsKey("kind")) { |
kind = _json["kind"]; |
@@ -18716,7 +19310,7 @@ class AddressAggregatedList { |
_json["id"] = id; |
} |
if (items != null) { |
- _json["items"] = commons.mapMap<AddressesScopedList, core.Map<core.String, core.Object>>(items, (AddressesScopedList item) => (item).toJson()); |
+ _json["items"] = commons.mapMap<AcceleratorTypesScopedList, core.Map<core.String, core.Object>>(items, (AcceleratorTypesScopedList item) => (item).toJson()); |
} |
if (kind != null) { |
_json["kind"] = kind; |
@@ -18731,39 +19325,32 @@ class AddressAggregatedList { |
} |
} |
-/** Contains a list of addresses. */ |
-class AddressList { |
+/** Contains a list of accelerator types. */ |
+class AcceleratorTypeList { |
/** |
- * [Output Only] The unique identifier for the resource. This identifier is |
- * defined by the server. |
+ * [Output Only] Unique identifier for the resource; defined by the server. |
*/ |
core.String id; |
- /** [Output Only] A list of addresses. */ |
- core.List<Address> items; |
+ /** A list of AcceleratorType resources. */ |
+ core.List<AcceleratorType> items; |
/** |
- * [Output Only] Type of resource. Always compute#addressList for lists of |
- * addresses. |
+ * [Output Only] Type of resource. Always compute#acceleratorTypeList for |
+ * lists of accelerator types. |
*/ |
core.String kind; |
- /** |
- * [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. |
- */ |
+ /** [Output Only] A token used to continue a truncated list request. */ |
core.String nextPageToken; |
- /** [Output Only] Server-defined URL for the resource. */ |
+ /** [Output Only] Server-defined URL for this resource. */ |
core.String selfLink; |
- AddressList(); |
+ AcceleratorTypeList(); |
- AddressList.fromJson(core.Map _json) { |
+ AcceleratorTypeList.fromJson(core.Map _json) { |
if (_json.containsKey("id")) { |
id = _json["id"]; |
} |
if (_json.containsKey("items")) { |
- items = _json["items"].map((value) => new Address.fromJson(value)).toList(); |
+ items = _json["items"].map((value) => new AcceleratorType.fromJson(value)).toList(); |
} |
if (_json.containsKey("kind")) { |
kind = _json["kind"]; |
@@ -18797,7 +19384,7 @@ class AddressList { |
} |
} |
-class AddressesScopedListWarningData { |
+class AcceleratorTypesScopedListWarningData { |
/** |
* [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 |
@@ -18811,9 +19398,9 @@ class AddressesScopedListWarningData { |
/** [Output Only] A warning data value corresponding to the key. */ |
core.String value; |
- AddressesScopedListWarningData(); |
+ AcceleratorTypesScopedListWarningData(); |
- AddressesScopedListWarningData.fromJson(core.Map _json) { |
+ AcceleratorTypesScopedListWarningData.fromJson(core.Map _json) { |
if (_json.containsKey("key")) { |
key = _json["key"]; |
} |
@@ -18835,10 +19422,10 @@ class AddressesScopedListWarningData { |
} |
/** |
- * [Output Only] Informational warning which replaces the list of addresses when |
- * the list is empty. |
+ * [Output Only] An informational warning that appears when the accelerator |
+ * types list is empty. |
*/ |
-class AddressesScopedListWarning { |
+class AcceleratorTypesScopedListWarning { |
/** |
* [Output Only] A warning code, if applicable. For example, Compute Engine |
* returns NO_RESULTS_ON_PAGE if there are no results in the response. |
@@ -18867,18 +19454,18 @@ class AddressesScopedListWarning { |
* example: |
* "data": [ { "key": "scope", "value": "zones/us-east1-d" } |
*/ |
- core.List<AddressesScopedListWarningData> data; |
+ core.List<AcceleratorTypesScopedListWarningData> data; |
/** [Output Only] A human-readable description of the warning code. */ |
core.String message; |
- AddressesScopedListWarning(); |
+ AcceleratorTypesScopedListWarning(); |
- AddressesScopedListWarning.fromJson(core.Map _json) { |
+ AcceleratorTypesScopedListWarning.fromJson(core.Map _json) { |
if (_json.containsKey("code")) { |
code = _json["code"]; |
} |
if (_json.containsKey("data")) { |
- data = _json["data"].map((value) => new AddressesScopedListWarningData.fromJson(value)).toList(); |
+ data = _json["data"].map((value) => new AcceleratorTypesScopedListWarningData.fromJson(value)).toList(); |
} |
if (_json.containsKey("message")) { |
message = _json["message"]; |
@@ -18900,30 +19487,30 @@ class AddressesScopedListWarning { |
} |
} |
-class AddressesScopedList { |
- /** [Output Only] List of addresses contained in this scope. */ |
- core.List<Address> addresses; |
+class AcceleratorTypesScopedList { |
+ /** [Output Only] List of accelerator types contained in this scope. */ |
+ core.List<AcceleratorType> acceleratorTypes; |
/** |
- * [Output Only] Informational warning which replaces the list of addresses |
- * when the list is empty. |
+ * [Output Only] An informational warning that appears when the accelerator |
+ * types list is empty. |
*/ |
- AddressesScopedListWarning warning; |
+ AcceleratorTypesScopedListWarning warning; |
- AddressesScopedList(); |
+ AcceleratorTypesScopedList(); |
- AddressesScopedList.fromJson(core.Map _json) { |
- if (_json.containsKey("addresses")) { |
- addresses = _json["addresses"].map((value) => new Address.fromJson(value)).toList(); |
+ AcceleratorTypesScopedList.fromJson(core.Map _json) { |
+ if (_json.containsKey("acceleratorTypes")) { |
+ acceleratorTypes = _json["acceleratorTypes"].map((value) => new AcceleratorType.fromJson(value)).toList(); |
} |
if (_json.containsKey("warning")) { |
- warning = new AddressesScopedListWarning.fromJson(_json["warning"]); |
+ warning = new AcceleratorTypesScopedListWarning.fromJson(_json["warning"]); |
} |
} |
core.Map<core.String, core.Object> toJson() { |
final core.Map<core.String, core.Object> _json = new core.Map<core.String, core.Object>(); |
- if (addresses != null) { |
- _json["addresses"] = addresses.map((value) => (value).toJson()).toList(); |
+ if (acceleratorTypes != null) { |
+ _json["acceleratorTypes"] = acceleratorTypes.map((value) => (value).toJson()).toList(); |
} |
if (warning != null) { |
_json["warning"] = (warning).toJson(); |
@@ -18932,449 +19519,220 @@ class AddressesScopedList { |
} |
} |
-/** An instance-attached disk resource. */ |
-class AttachedDisk { |
- /** |
- * Specifies whether the disk will be auto-deleted when the instance is |
- * deleted (but not when the disk is detached from the instance). |
- */ |
- core.bool autoDelete; |
+/** |
+ * An access configuration attached to an instance's network interface. Only one |
+ * access config per instance is supported. |
+ */ |
+class AccessConfig { |
/** |
- * Indicates that this is a boot disk. The virtual machine will use the first |
- * partition of the disk for its root filesystem. |
+ * [Output Only] Type of the resource. Always compute#accessConfig for access |
+ * configs. |
*/ |
- core.bool boot; |
+ core.String kind; |
/** |
- * Specifies a unique device name of your choice that is reflected into the |
- * /dev/disk/by-id/google-* tree of a Linux operating system running within |
- * the instance. This name can be used to reference the device for mounting, |
- * resizing, and so on, from within the instance. |
- * |
- * If not specified, the server chooses a default device name to apply to this |
- * disk, in the form persistent-disks-x, where x is a number assigned by |
- * Google Compute Engine. This field is only applicable for persistent disks. |
+ * The name of this access configuration. The default and recommended name is |
+ * External NAT but you can use any arbitrary string you would like. For |
+ * example, My external IP or Network Access. |
*/ |
- core.String deviceName; |
+ core.String name; |
/** |
- * Encrypts or decrypts a disk using a customer-supplied encryption key. |
- * |
- * If you are creating a new disk, this field encrypts the new disk using an |
- * encryption key that you provide. If you are attaching an existing disk that |
- * is already encrypted, this field decrypts the disk using the |
- * customer-supplied encryption key. |
- * |
- * If you encrypt a disk using a customer-supplied key, you must provide the |
- * same key again when you attempt to use this resource at a later time. For |
- * example, you must provide the key when you create a snapshot or an image |
- * from the disk or when you attach the disk to a virtual machine instance. |
- * |
- * If you do not provide an encryption key, then the disk will be encrypted |
- * using an automatically generated key and you do not need to provide a key |
- * to use the disk later. |
- * |
- * Instance templates do not store customer-supplied encryption keys, so you |
- * cannot use your own keys to encrypt disks in a managed instance group. |
+ * An external IP address associated with this instance. Specify an unused |
+ * static external IP address available to the project or leave this field |
+ * undefined to use an IP from a shared ephemeral IP address pool. If you |
+ * specify a static external IP address, it must live in the same region as |
+ * the zone of the instance. |
*/ |
- CustomerEncryptionKey diskEncryptionKey; |
+ core.String natIP; |
/** |
- * Assigns a zero-based index to this disk, where 0 is reserved for the boot |
- * disk. For example, if you have many disks attached to an instance, each |
- * disk would have a unique index number. If not specified, the server will |
- * choose an appropriate value. |
+ * The type of configuration. The default and only option is ONE_TO_ONE_NAT. |
+ * Possible string values are: |
+ * - "ONE_TO_ONE_NAT" |
*/ |
- core.int index; |
- /** |
- * [Input Only] Specifies the parameters for a new disk that will be created |
- * alongside the new instance. Use initialization parameters to create boot |
- * disks or local SSDs attached to the new instance. |
- * |
- * This property is mutually exclusive with the source property; you can only |
- * define one or the other, but not both. |
+ core.String type; |
+ |
+ AccessConfig(); |
+ |
+ AccessConfig.fromJson(core.Map _json) { |
+ if (_json.containsKey("kind")) { |
+ kind = _json["kind"]; |
+ } |
+ if (_json.containsKey("name")) { |
+ name = _json["name"]; |
+ } |
+ if (_json.containsKey("natIP")) { |
+ natIP = _json["natIP"]; |
+ } |
+ if (_json.containsKey("type")) { |
+ type = _json["type"]; |
+ } |
+ } |
+ |
+ core.Map<core.String, core.Object> toJson() { |
+ final core.Map<core.String, core.Object> _json = new core.Map<core.String, core.Object>(); |
+ if (kind != null) { |
+ _json["kind"] = kind; |
+ } |
+ if (name != null) { |
+ _json["name"] = name; |
+ } |
+ if (natIP != null) { |
+ _json["natIP"] = natIP; |
+ } |
+ if (type != null) { |
+ _json["type"] = type; |
+ } |
+ return _json; |
+ } |
+} |
+ |
+/** A reserved address resource. */ |
+class Address { |
+ /** The static external IP address represented by this resource. */ |
+ core.String address; |
+ /** [Output Only] Creation timestamp in RFC3339 text format. */ |
+ core.String creationTimestamp; |
+ /** |
+ * An optional description of this resource. Provide this property when you |
+ * create the resource. |
*/ |
- AttachedDiskInitializeParams initializeParams; |
+ core.String description; |
/** |
- * Specifies the disk interface to use for attaching this disk, which is |
- * either SCSI or NVME. The default is SCSI. Persistent disks must always use |
- * SCSI and the request will fail if you attempt to attach a persistent disk |
- * in any other format than SCSI. Local SSDs can use either NVME or SCSI. For |
- * performance characteristics of SCSI over NVMe, see Local SSD performance. |
+ * [Output Only] The unique identifier for the resource. This identifier is |
+ * defined by the server. |
+ */ |
+ core.String id; |
+ /** |
+ * The IP Version that will be used by this address. Valid options are IPV4 or |
+ * IPV6. This can only be specified for a global address. |
* Possible string values are: |
- * - "NVME" |
- * - "SCSI" |
+ * - "IPV4" |
+ * - "IPV6" |
+ * - "UNSPECIFIED_VERSION" |
*/ |
- core.String interface; |
+ core.String ipVersion; |
/** |
- * [Output Only] Type of the resource. Always compute#attachedDisk for |
- * attached disks. |
+ * [Output Only] Type of the resource. Always compute#address for addresses. |
*/ |
core.String kind; |
- /** [Output Only] Any valid publicly visible licenses. */ |
- core.List<core.String> licenses; |
/** |
- * The mode in which to attach this disk, either READ_WRITE or READ_ONLY. If |
- * not specified, the default is to attach the disk in READ_WRITE mode. |
- * Possible string values are: |
- * - "READ_ONLY" |
- * - "READ_WRITE" |
+ * 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. |
*/ |
- core.String mode; |
+ core.String name; |
/** |
- * Specifies a valid partial or full URL to an existing Persistent Disk |
- * resource. When creating a new instance, one of initializeParams.sourceImage |
- * or disks.source is required. |
- * |
- * If desired, you can also attach existing non-root persistent disks using |
- * this property. This field is only applicable for persistent disks. |
- * |
- * Note that for InstanceTemplate, specify the disk name, not the URL for the |
- * disk. |
+ * [Output Only] URL of the region where the regional address resides. This |
+ * field is not applicable to global addresses. |
*/ |
- core.String source; |
+ core.String region; |
+ /** [Output Only] Server-defined URL for the resource. */ |
+ core.String selfLink; |
/** |
- * Specifies the type of the disk, either SCRATCH or PERSISTENT. If not |
- * specified, the default is PERSISTENT. |
+ * [Output Only] The status of the address, which can be either IN_USE or |
+ * RESERVED. An address that is RESERVED is currently reserved and available |
+ * to use. An IN_USE address is currently being used by another resource and |
+ * is not available. |
* Possible string values are: |
- * - "PERSISTENT" |
- * - "SCRATCH" |
+ * - "IN_USE" |
+ * - "RESERVED" |
*/ |
- core.String type; |
+ core.String status; |
+ /** [Output Only] The URLs of the resources that are using this address. */ |
+ core.List<core.String> users; |
- AttachedDisk(); |
+ Address(); |
- AttachedDisk.fromJson(core.Map _json) { |
- if (_json.containsKey("autoDelete")) { |
- autoDelete = _json["autoDelete"]; |
- } |
- if (_json.containsKey("boot")) { |
- boot = _json["boot"]; |
- } |
- if (_json.containsKey("deviceName")) { |
- deviceName = _json["deviceName"]; |
+ Address.fromJson(core.Map _json) { |
+ if (_json.containsKey("address")) { |
+ address = _json["address"]; |
} |
- if (_json.containsKey("diskEncryptionKey")) { |
- diskEncryptionKey = new CustomerEncryptionKey.fromJson(_json["diskEncryptionKey"]); |
+ if (_json.containsKey("creationTimestamp")) { |
+ creationTimestamp = _json["creationTimestamp"]; |
} |
- if (_json.containsKey("index")) { |
- index = _json["index"]; |
+ if (_json.containsKey("description")) { |
+ description = _json["description"]; |
} |
- if (_json.containsKey("initializeParams")) { |
- initializeParams = new AttachedDiskInitializeParams.fromJson(_json["initializeParams"]); |
+ if (_json.containsKey("id")) { |
+ id = _json["id"]; |
} |
- if (_json.containsKey("interface")) { |
- interface = _json["interface"]; |
+ if (_json.containsKey("ipVersion")) { |
+ ipVersion = _json["ipVersion"]; |
} |
if (_json.containsKey("kind")) { |
kind = _json["kind"]; |
} |
- if (_json.containsKey("licenses")) { |
- licenses = _json["licenses"]; |
+ if (_json.containsKey("name")) { |
+ name = _json["name"]; |
} |
- if (_json.containsKey("mode")) { |
- mode = _json["mode"]; |
+ if (_json.containsKey("region")) { |
+ region = _json["region"]; |
} |
- if (_json.containsKey("source")) { |
- source = _json["source"]; |
+ if (_json.containsKey("selfLink")) { |
+ selfLink = _json["selfLink"]; |
} |
- if (_json.containsKey("type")) { |
- type = _json["type"]; |
+ if (_json.containsKey("status")) { |
+ status = _json["status"]; |
+ } |
+ if (_json.containsKey("users")) { |
+ users = _json["users"]; |
} |
} |
core.Map<core.String, core.Object> toJson() { |
final core.Map<core.String, core.Object> _json = new core.Map<core.String, core.Object>(); |
- if (autoDelete != null) { |
- _json["autoDelete"] = autoDelete; |
- } |
- if (boot != null) { |
- _json["boot"] = boot; |
- } |
- if (deviceName != null) { |
- _json["deviceName"] = deviceName; |
+ if (address != null) { |
+ _json["address"] = address; |
} |
- if (diskEncryptionKey != null) { |
- _json["diskEncryptionKey"] = (diskEncryptionKey).toJson(); |
+ if (creationTimestamp != null) { |
+ _json["creationTimestamp"] = creationTimestamp; |
} |
- if (index != null) { |
- _json["index"] = index; |
+ if (description != null) { |
+ _json["description"] = description; |
} |
- if (initializeParams != null) { |
- _json["initializeParams"] = (initializeParams).toJson(); |
+ if (id != null) { |
+ _json["id"] = id; |
} |
- if (interface != null) { |
- _json["interface"] = interface; |
+ if (ipVersion != null) { |
+ _json["ipVersion"] = ipVersion; |
} |
if (kind != null) { |
_json["kind"] = kind; |
} |
- if (licenses != null) { |
- _json["licenses"] = licenses; |
+ if (name != null) { |
+ _json["name"] = name; |
} |
- if (mode != null) { |
- _json["mode"] = mode; |
+ if (region != null) { |
+ _json["region"] = region; |
} |
- if (source != null) { |
- _json["source"] = source; |
+ if (selfLink != null) { |
+ _json["selfLink"] = selfLink; |
} |
- if (type != null) { |
- _json["type"] = type; |
+ if (status != null) { |
+ _json["status"] = status; |
+ } |
+ if (users != null) { |
+ _json["users"] = users; |
} |
return _json; |
} |
} |
-/** |
- * [Input Only] Specifies the parameters for a new disk that will be created |
- * alongside the new instance. Use initialization parameters to create boot |
- * disks or local SSDs attached to the new instance. |
- * |
- * This property is mutually exclusive with the source property; you can only |
- * define one or the other, but not both. |
- */ |
-class AttachedDiskInitializeParams { |
+class AddressAggregatedList { |
/** |
- * Specifies the disk name. If not specified, the default is to use the name |
- * of the instance. |
+ * [Output Only] Unique identifier for the resource; defined by the server. |
*/ |
- core.String diskName; |
- /** Specifies the size of the disk in base-2 GB. */ |
- core.String diskSizeGb; |
+ core.String id; |
+ /** [Output Only] A map of scoped address lists. */ |
+ core.Map<core.String, AddressesScopedList> items; |
/** |
- * Specifies the disk type to use to create the instance. If not specified, |
- * the default is pd-standard, specified using the full URL. For example: |
- * |
- * https://www.googleapis.com/compute/v1/projects/project/zones/zone/diskTypes/pd-standard |
- * |
- * Other values include pd-ssd and local-ssd. If you define this field, you |
- * can provide either the full or partial URL. For example, the following are |
- * valid values: |
- * - |
- * https://www.googleapis.com/compute/v1/projects/project/zones/zone/diskTypes/diskType |
- * - projects/project/zones/zone/diskTypes/diskType |
- * - zones/zone/diskTypes/diskType Note that for InstanceTemplate, this is |
- * the name of the disk type, not URL. |
+ * [Output Only] Type of resource. Always compute#addressAggregatedList for |
+ * aggregated lists of addresses. |
*/ |
- core.String diskType; |
- /** |
- * The source image to create this disk. When creating a new instance, one of |
- * initializeParams.sourceImage or disks.source is required. |
- * |
- * To create a disk with one of the public operating system images, specify |
- * the image by its family name. For example, specify family/debian-8 to use |
- * the latest Debian 8 image: |
- * |
- * projects/debian-cloud/global/images/family/debian-8 |
- * |
- * Alternatively, use a specific version of a public operating system image: |
- * |
- * projects/debian-cloud/global/images/debian-8-jessie-vYYYYMMDD |
- * |
- * To create a disk with a private image that you created, specify the image |
- * name in the following format: |
- * |
- * global/images/my-private-image |
- * |
- * You can also specify a private image by its image family, which returns the |
- * latest version of the image in that family. Replace the image name with |
- * family/family-name: |
- * |
- * global/images/family/my-private-family |
- * |
- * If the source image is deleted later, this field will not be set. |
- */ |
- core.String sourceImage; |
- /** |
- * The customer-supplied encryption key of the source image. Required if the |
- * source image is protected by a customer-supplied encryption key. |
- * |
- * Instance templates do not store customer-supplied encryption keys, so you |
- * cannot create disks for instances in a managed instance group if the source |
- * images are encrypted with your own keys. |
- */ |
- CustomerEncryptionKey sourceImageEncryptionKey; |
- |
- AttachedDiskInitializeParams(); |
- |
- AttachedDiskInitializeParams.fromJson(core.Map _json) { |
- if (_json.containsKey("diskName")) { |
- diskName = _json["diskName"]; |
- } |
- if (_json.containsKey("diskSizeGb")) { |
- diskSizeGb = _json["diskSizeGb"]; |
- } |
- if (_json.containsKey("diskType")) { |
- diskType = _json["diskType"]; |
- } |
- if (_json.containsKey("sourceImage")) { |
- sourceImage = _json["sourceImage"]; |
- } |
- if (_json.containsKey("sourceImageEncryptionKey")) { |
- sourceImageEncryptionKey = new CustomerEncryptionKey.fromJson(_json["sourceImageEncryptionKey"]); |
- } |
- } |
- |
- core.Map<core.String, core.Object> toJson() { |
- final core.Map<core.String, core.Object> _json = new core.Map<core.String, core.Object>(); |
- if (diskName != null) { |
- _json["diskName"] = diskName; |
- } |
- if (diskSizeGb != null) { |
- _json["diskSizeGb"] = diskSizeGb; |
- } |
- if (diskType != null) { |
- _json["diskType"] = diskType; |
- } |
- if (sourceImage != null) { |
- _json["sourceImage"] = sourceImage; |
- } |
- if (sourceImageEncryptionKey != null) { |
- _json["sourceImageEncryptionKey"] = (sourceImageEncryptionKey).toJson(); |
- } |
- return _json; |
- } |
-} |
- |
-/** |
- * Represents an Autoscaler resource. Autoscalers allow you to automatically |
- * scale virtual machine instances in managed instance groups according to an |
- * autoscaling policy that you define. For more information, read Autoscaling |
- * Groups of Instances. |
- */ |
-class Autoscaler { |
- /** |
- * The configuration parameters for the autoscaling algorithm. You can define |
- * one or more of the policies for an autoscaler: cpuUtilization, |
- * customMetricUtilizations, and loadBalancingUtilization. |
- * |
- * If none of these are specified, the default will be to autoscale based on |
- * cpuUtilization to 0.6 or 60%. |
- */ |
- AutoscalingPolicy autoscalingPolicy; |
- /** [Output Only] Creation timestamp in RFC3339 text format. */ |
- core.String creationTimestamp; |
- /** |
- * An optional description of this resource. Provide this property when you |
- * create the resource. |
- */ |
- core.String description; |
- /** |
- * [Output Only] The unique identifier for the resource. This identifier is |
- * defined by the server. |
- */ |
- core.String id; |
- /** |
- * [Output Only] Type of the resource. Always compute#autoscaler for |
- * autoscalers. |
- */ |
- core.String kind; |
- /** |
- * 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. |
- */ |
- core.String name; |
- /** |
- * [Output Only] URL of the region where the instance group resides (for |
- * autoscalers living in regional scope). |
- */ |
- core.String region; |
- /** [Output Only] Server-defined URL for the resource. */ |
- core.String selfLink; |
- /** URL of the managed instance group that this autoscaler will scale. */ |
- core.String target; |
- /** |
- * [Output Only] URL of the zone where the instance group resides (for |
- * autoscalers living in zonal scope). |
- */ |
- core.String zone; |
- |
- Autoscaler(); |
- |
- Autoscaler.fromJson(core.Map _json) { |
- if (_json.containsKey("autoscalingPolicy")) { |
- autoscalingPolicy = new AutoscalingPolicy.fromJson(_json["autoscalingPolicy"]); |
- } |
- if (_json.containsKey("creationTimestamp")) { |
- creationTimestamp = _json["creationTimestamp"]; |
- } |
- if (_json.containsKey("description")) { |
- description = _json["description"]; |
- } |
- if (_json.containsKey("id")) { |
- id = _json["id"]; |
- } |
- if (_json.containsKey("kind")) { |
- kind = _json["kind"]; |
- } |
- if (_json.containsKey("name")) { |
- name = _json["name"]; |
- } |
- if (_json.containsKey("region")) { |
- region = _json["region"]; |
- } |
- if (_json.containsKey("selfLink")) { |
- selfLink = _json["selfLink"]; |
- } |
- if (_json.containsKey("target")) { |
- target = _json["target"]; |
- } |
- if (_json.containsKey("zone")) { |
- zone = _json["zone"]; |
- } |
- } |
- |
- core.Map<core.String, core.Object> toJson() { |
- final core.Map<core.String, core.Object> _json = new core.Map<core.String, core.Object>(); |
- if (autoscalingPolicy != null) { |
- _json["autoscalingPolicy"] = (autoscalingPolicy).toJson(); |
- } |
- if (creationTimestamp != null) { |
- _json["creationTimestamp"] = creationTimestamp; |
- } |
- if (description != null) { |
- _json["description"] = description; |
- } |
- if (id != null) { |
- _json["id"] = id; |
- } |
- if (kind != null) { |
- _json["kind"] = kind; |
- } |
- if (name != null) { |
- _json["name"] = name; |
- } |
- if (region != null) { |
- _json["region"] = region; |
- } |
- if (selfLink != null) { |
- _json["selfLink"] = selfLink; |
- } |
- if (target != null) { |
- _json["target"] = target; |
- } |
- if (zone != null) { |
- _json["zone"] = zone; |
- } |
- return _json; |
- } |
-} |
- |
-class AutoscalerAggregatedList { |
- /** |
- * [Output Only] The unique identifier for the resource. This identifier is |
- * defined by the server. |
- */ |
- core.String id; |
- /** A map of scoped autoscaler lists. */ |
- core.Map<core.String, AutoscalersScopedList> items; |
- /** |
- * [Output Only] Type of resource. Always compute#autoscalerAggregatedList for |
- * aggregated lists of autoscalers. |
- */ |
- core.String kind; |
+ core.String kind; |
/** |
* [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 |
@@ -19386,14 +19744,14 @@ class AutoscalerAggregatedList { |
/** [Output Only] Server-defined URL for this resource. */ |
core.String selfLink; |
- AutoscalerAggregatedList(); |
+ AddressAggregatedList(); |
- AutoscalerAggregatedList.fromJson(core.Map _json) { |
+ AddressAggregatedList.fromJson(core.Map _json) { |
if (_json.containsKey("id")) { |
id = _json["id"]; |
} |
if (_json.containsKey("items")) { |
- items = commons.mapMap<core.Map<core.String, core.Object>, AutoscalersScopedList>(_json["items"], (core.Map<core.String, core.Object> item) => new AutoscalersScopedList.fromJson(item)); |
+ items = commons.mapMap<core.Map<core.String, core.Object>, AddressesScopedList>(_json["items"], (core.Map<core.String, core.Object> item) => new AddressesScopedList.fromJson(item)); |
} |
if (_json.containsKey("kind")) { |
kind = _json["kind"]; |
@@ -19412,7 +19770,7 @@ class AutoscalerAggregatedList { |
_json["id"] = id; |
} |
if (items != null) { |
- _json["items"] = commons.mapMap<AutoscalersScopedList, core.Map<core.String, core.Object>>(items, (AutoscalersScopedList item) => (item).toJson()); |
+ _json["items"] = commons.mapMap<AddressesScopedList, core.Map<core.String, core.Object>>(items, (AddressesScopedList item) => (item).toJson()); |
} |
if (kind != null) { |
_json["kind"] = kind; |
@@ -19427,18 +19785,18 @@ class AutoscalerAggregatedList { |
} |
} |
-/** Contains a list of Autoscaler resources. */ |
-class AutoscalerList { |
+/** Contains a list of addresses. */ |
+class AddressList { |
/** |
* [Output Only] The unique identifier for the resource. This identifier is |
* defined by the server. |
*/ |
core.String id; |
- /** A list of Autoscaler resources. */ |
- core.List<Autoscaler> items; |
+ /** [Output Only] A list of addresses. */ |
+ core.List<Address> items; |
/** |
- * [Output Only] Type of resource. Always compute#autoscalerList for lists of |
- * autoscalers. |
+ * [Output Only] Type of resource. Always compute#addressList for lists of |
+ * addresses. |
*/ |
core.String kind; |
/** |
@@ -19449,17 +19807,17 @@ class AutoscalerList { |
* continue paging through the results. |
*/ |
core.String nextPageToken; |
- /** [Output Only] Server-defined URL for this resource. */ |
+ /** [Output Only] Server-defined URL for the resource. */ |
core.String selfLink; |
- AutoscalerList(); |
+ AddressList(); |
- AutoscalerList.fromJson(core.Map _json) { |
+ AddressList.fromJson(core.Map _json) { |
if (_json.containsKey("id")) { |
id = _json["id"]; |
} |
if (_json.containsKey("items")) { |
- items = _json["items"].map((value) => new Autoscaler.fromJson(value)).toList(); |
+ items = _json["items"].map((value) => new Address.fromJson(value)).toList(); |
} |
if (_json.containsKey("kind")) { |
kind = _json["kind"]; |
@@ -19493,7 +19851,7 @@ class AutoscalerList { |
} |
} |
-class AutoscalersScopedListWarningData { |
+class AddressesScopedListWarningData { |
/** |
* [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 |
@@ -19507,9 +19865,9 @@ class AutoscalersScopedListWarningData { |
/** [Output Only] A warning data value corresponding to the key. */ |
core.String value; |
- AutoscalersScopedListWarningData(); |
+ AddressesScopedListWarningData(); |
- AutoscalersScopedListWarningData.fromJson(core.Map _json) { |
+ AddressesScopedListWarningData.fromJson(core.Map _json) { |
if (_json.containsKey("key")) { |
key = _json["key"]; |
} |
@@ -19531,10 +19889,10 @@ class AutoscalersScopedListWarningData { |
} |
/** |
- * [Output Only] Informational warning which replaces the list of autoscalers |
- * when the list is empty. |
+ * [Output Only] Informational warning which replaces the list of addresses when |
+ * the list is empty. |
*/ |
-class AutoscalersScopedListWarning { |
+class AddressesScopedListWarning { |
/** |
* [Output Only] A warning code, if applicable. For example, Compute Engine |
* returns NO_RESULTS_ON_PAGE if there are no results in the response. |
@@ -19563,18 +19921,18 @@ class AutoscalersScopedListWarning { |
* example: |
* "data": [ { "key": "scope", "value": "zones/us-east1-d" } |
*/ |
- core.List<AutoscalersScopedListWarningData> data; |
+ core.List<AddressesScopedListWarningData> data; |
/** [Output Only] A human-readable description of the warning code. */ |
core.String message; |
- AutoscalersScopedListWarning(); |
+ AddressesScopedListWarning(); |
- AutoscalersScopedListWarning.fromJson(core.Map _json) { |
+ AddressesScopedListWarning.fromJson(core.Map _json) { |
if (_json.containsKey("code")) { |
code = _json["code"]; |
} |
if (_json.containsKey("data")) { |
- data = _json["data"].map((value) => new AutoscalersScopedListWarningData.fromJson(value)).toList(); |
+ data = _json["data"].map((value) => new AddressesScopedListWarningData.fromJson(value)).toList(); |
} |
if (_json.containsKey("message")) { |
message = _json["message"]; |
@@ -19596,30 +19954,30 @@ class AutoscalersScopedListWarning { |
} |
} |
-class AutoscalersScopedList { |
- /** [Output Only] List of autoscalers contained in this scope. */ |
- core.List<Autoscaler> autoscalers; |
+class AddressesScopedList { |
+ /** [Output Only] List of addresses contained in this scope. */ |
+ core.List<Address> addresses; |
/** |
- * [Output Only] Informational warning which replaces the list of autoscalers |
+ * [Output Only] Informational warning which replaces the list of addresses |
* when the list is empty. |
*/ |
- AutoscalersScopedListWarning warning; |
+ AddressesScopedListWarning warning; |
- AutoscalersScopedList(); |
+ AddressesScopedList(); |
- AutoscalersScopedList.fromJson(core.Map _json) { |
- if (_json.containsKey("autoscalers")) { |
- autoscalers = _json["autoscalers"].map((value) => new Autoscaler.fromJson(value)).toList(); |
+ AddressesScopedList.fromJson(core.Map _json) { |
+ if (_json.containsKey("addresses")) { |
+ addresses = _json["addresses"].map((value) => new Address.fromJson(value)).toList(); |
} |
if (_json.containsKey("warning")) { |
- warning = new AutoscalersScopedListWarning.fromJson(_json["warning"]); |
+ warning = new AddressesScopedListWarning.fromJson(_json["warning"]); |
} |
} |
core.Map<core.String, core.Object> toJson() { |
final core.Map<core.String, core.Object> _json = new core.Map<core.String, core.Object>(); |
- if (autoscalers != null) { |
- _json["autoscalers"] = autoscalers.map((value) => (value).toJson()).toList(); |
+ if (addresses != null) { |
+ _json["addresses"] = addresses.map((value) => (value).toJson()).toList(); |
} |
if (warning != null) { |
_json["warning"] = (warning).toJson(); |
@@ -19628,526 +19986,2031 @@ class AutoscalersScopedList { |
} |
} |
-/** Cloud Autoscaler policy. */ |
-class AutoscalingPolicy { |
+/** An instance-attached disk resource. */ |
+class AttachedDisk { |
/** |
- * The number of seconds that the autoscaler should wait before it starts |
- * collecting information from a new instance. This prevents the autoscaler |
- * from collecting information when the instance is initializing, during which |
- * the collected usage would not be reliable. The default time autoscaler |
- * waits is 60 seconds. |
+ * Specifies whether the disk will be auto-deleted when the instance is |
+ * deleted (but not when the disk is detached from the instance). |
+ */ |
+ core.bool autoDelete; |
+ /** |
+ * Indicates that this is a boot disk. The virtual machine will use the first |
+ * partition of the disk for its root filesystem. |
+ */ |
+ core.bool boot; |
+ /** |
+ * Specifies a unique device name of your choice that is reflected into the |
+ * /dev/disk/by-id/google-* tree of a Linux operating system running within |
+ * the instance. This name can be used to reference the device for mounting, |
+ * resizing, and so on, from within the instance. |
* |
- * Virtual machine initialization times might vary because of numerous |
- * factors. We recommend that you test how long an instance may take to |
- * initialize. To do this, create an instance and time the startup process. |
+ * If not specified, the server chooses a default device name to apply to this |
+ * disk, in the form persistent-disks-x, where x is a number assigned by |
+ * Google Compute Engine. This field is only applicable for persistent disks. |
*/ |
- core.int coolDownPeriodSec; |
+ core.String deviceName; |
/** |
- * Defines the CPU utilization policy that allows the autoscaler to scale |
- * based on the average CPU utilization of a managed instance group. |
+ * Encrypts or decrypts a disk using a customer-supplied encryption key. |
+ * |
+ * If you are creating a new disk, this field encrypts the new disk using an |
+ * encryption key that you provide. If you are attaching an existing disk that |
+ * is already encrypted, this field decrypts the disk using the |
+ * customer-supplied encryption key. |
+ * |
+ * If you encrypt a disk using a customer-supplied key, you must provide the |
+ * same key again when you attempt to use this resource at a later time. For |
+ * example, you must provide the key when you create a snapshot or an image |
+ * from the disk or when you attach the disk to a virtual machine instance. |
+ * |
+ * If you do not provide an encryption key, then the disk will be encrypted |
+ * using an automatically generated key and you do not need to provide a key |
+ * to use the disk later. |
+ * |
+ * Instance templates do not store customer-supplied encryption keys, so you |
+ * cannot use your own keys to encrypt disks in a managed instance group. |
*/ |
- AutoscalingPolicyCpuUtilization cpuUtilization; |
- /** Configuration parameters of autoscaling based on a custom metric. */ |
- core.List<AutoscalingPolicyCustomMetricUtilization> customMetricUtilizations; |
- /** Configuration parameters of autoscaling based on load balancer. */ |
- AutoscalingPolicyLoadBalancingUtilization loadBalancingUtilization; |
+ CustomerEncryptionKey diskEncryptionKey; |
/** |
- * The maximum number of instances that the autoscaler can scale up to. This |
- * is required when creating or updating an autoscaler. The maximum number of |
- * replicas should not be lower than minimal number of replicas. |
+ * Assigns a zero-based index to this disk, where 0 is reserved for the boot |
+ * disk. For example, if you have many disks attached to an instance, each |
+ * disk would have a unique index number. If not specified, the server will |
+ * choose an appropriate value. |
*/ |
- core.int maxNumReplicas; |
+ core.int index; |
/** |
- * The minimum number of replicas that the autoscaler can scale down to. This |
- * cannot be less than 0. If not provided, autoscaler will choose a default |
- * value depending on maximum number of instances allowed. |
+ * [Input Only] Specifies the parameters for a new disk that will be created |
+ * alongside the new instance. Use initialization parameters to create boot |
+ * disks or local SSDs attached to the new instance. |
+ * |
+ * This property is mutually exclusive with the source property; you can only |
+ * define one or the other, but not both. |
*/ |
- core.int minNumReplicas; |
+ AttachedDiskInitializeParams initializeParams; |
+ /** |
+ * Specifies the disk interface to use for attaching this disk, which is |
+ * either SCSI or NVME. The default is SCSI. Persistent disks must always use |
+ * SCSI and the request will fail if you attempt to attach a persistent disk |
+ * in any other format than SCSI. Local SSDs can use either NVME or SCSI. For |
+ * performance characteristics of SCSI over NVMe, see Local SSD performance. |
+ * Possible string values are: |
+ * - "NVME" |
+ * - "SCSI" |
+ */ |
+ core.String interface; |
+ /** |
+ * [Output Only] Type of the resource. Always compute#attachedDisk for |
+ * attached disks. |
+ */ |
+ core.String kind; |
+ /** [Output Only] Any valid publicly visible licenses. */ |
+ core.List<core.String> licenses; |
+ /** |
+ * The mode in which to attach this disk, either READ_WRITE or READ_ONLY. If |
+ * not specified, the default is to attach the disk in READ_WRITE mode. |
+ * Possible string values are: |
+ * - "READ_ONLY" |
+ * - "READ_WRITE" |
+ */ |
+ core.String mode; |
+ /** |
+ * Specifies a valid partial or full URL to an existing Persistent Disk |
+ * resource. When creating a new instance, one of initializeParams.sourceImage |
+ * or disks.source is required. |
+ * |
+ * If desired, you can also attach existing non-root persistent disks using |
+ * this property. This field is only applicable for persistent disks. |
+ * |
+ * Note that for InstanceTemplate, specify the disk name, not the URL for the |
+ * disk. |
+ */ |
+ core.String source; |
+ /** |
+ * Specifies the type of the disk, either SCRATCH or PERSISTENT. If not |
+ * specified, the default is PERSISTENT. |
+ * Possible string values are: |
+ * - "PERSISTENT" |
+ * - "SCRATCH" |
+ */ |
+ core.String type; |
- AutoscalingPolicy(); |
+ AttachedDisk(); |
- AutoscalingPolicy.fromJson(core.Map _json) { |
- if (_json.containsKey("coolDownPeriodSec")) { |
- coolDownPeriodSec = _json["coolDownPeriodSec"]; |
+ AttachedDisk.fromJson(core.Map _json) { |
+ if (_json.containsKey("autoDelete")) { |
+ autoDelete = _json["autoDelete"]; |
} |
- if (_json.containsKey("cpuUtilization")) { |
- cpuUtilization = new AutoscalingPolicyCpuUtilization.fromJson(_json["cpuUtilization"]); |
+ if (_json.containsKey("boot")) { |
+ boot = _json["boot"]; |
} |
- if (_json.containsKey("customMetricUtilizations")) { |
- customMetricUtilizations = _json["customMetricUtilizations"].map((value) => new AutoscalingPolicyCustomMetricUtilization.fromJson(value)).toList(); |
+ if (_json.containsKey("deviceName")) { |
+ deviceName = _json["deviceName"]; |
} |
- if (_json.containsKey("loadBalancingUtilization")) { |
- loadBalancingUtilization = new AutoscalingPolicyLoadBalancingUtilization.fromJson(_json["loadBalancingUtilization"]); |
+ if (_json.containsKey("diskEncryptionKey")) { |
+ diskEncryptionKey = new CustomerEncryptionKey.fromJson(_json["diskEncryptionKey"]); |
} |
- if (_json.containsKey("maxNumReplicas")) { |
- maxNumReplicas = _json["maxNumReplicas"]; |
+ if (_json.containsKey("index")) { |
+ index = _json["index"]; |
} |
- if (_json.containsKey("minNumReplicas")) { |
- minNumReplicas = _json["minNumReplicas"]; |
+ if (_json.containsKey("initializeParams")) { |
+ initializeParams = new AttachedDiskInitializeParams.fromJson(_json["initializeParams"]); |
+ } |
+ if (_json.containsKey("interface")) { |
+ interface = _json["interface"]; |
+ } |
+ if (_json.containsKey("kind")) { |
+ kind = _json["kind"]; |
+ } |
+ if (_json.containsKey("licenses")) { |
+ licenses = _json["licenses"]; |
+ } |
+ if (_json.containsKey("mode")) { |
+ mode = _json["mode"]; |
+ } |
+ if (_json.containsKey("source")) { |
+ source = _json["source"]; |
+ } |
+ if (_json.containsKey("type")) { |
+ type = _json["type"]; |
} |
} |
core.Map<core.String, core.Object> toJson() { |
final core.Map<core.String, core.Object> _json = new core.Map<core.String, core.Object>(); |
- if (coolDownPeriodSec != null) { |
- _json["coolDownPeriodSec"] = coolDownPeriodSec; |
+ if (autoDelete != null) { |
+ _json["autoDelete"] = autoDelete; |
} |
- if (cpuUtilization != null) { |
- _json["cpuUtilization"] = (cpuUtilization).toJson(); |
+ if (boot != null) { |
+ _json["boot"] = boot; |
} |
- if (customMetricUtilizations != null) { |
- _json["customMetricUtilizations"] = customMetricUtilizations.map((value) => (value).toJson()).toList(); |
+ if (deviceName != null) { |
+ _json["deviceName"] = deviceName; |
} |
- if (loadBalancingUtilization != null) { |
- _json["loadBalancingUtilization"] = (loadBalancingUtilization).toJson(); |
+ if (diskEncryptionKey != null) { |
+ _json["diskEncryptionKey"] = (diskEncryptionKey).toJson(); |
} |
- if (maxNumReplicas != null) { |
- _json["maxNumReplicas"] = maxNumReplicas; |
+ if (index != null) { |
+ _json["index"] = index; |
} |
- if (minNumReplicas != null) { |
- _json["minNumReplicas"] = minNumReplicas; |
+ if (initializeParams != null) { |
+ _json["initializeParams"] = (initializeParams).toJson(); |
+ } |
+ if (interface != null) { |
+ _json["interface"] = interface; |
+ } |
+ if (kind != null) { |
+ _json["kind"] = kind; |
+ } |
+ if (licenses != null) { |
+ _json["licenses"] = licenses; |
+ } |
+ if (mode != null) { |
+ _json["mode"] = mode; |
+ } |
+ if (source != null) { |
+ _json["source"] = source; |
+ } |
+ if (type != null) { |
+ _json["type"] = type; |
} |
return _json; |
} |
} |
-/** CPU utilization policy. */ |
-class AutoscalingPolicyCpuUtilization { |
+/** |
+ * [Input Only] Specifies the parameters for a new disk that will be created |
+ * alongside the new instance. Use initialization parameters to create boot |
+ * disks or local SSDs attached to the new instance. |
+ * |
+ * This property is mutually exclusive with the source property; you can only |
+ * define one or the other, but not both. |
+ */ |
+class AttachedDiskInitializeParams { |
/** |
- * The target CPU utilization that the autoscaler should maintain. Must be a |
- * float value in the range (0, 1]. If not specified, the default is 0.6. |
- * |
- * If the CPU level is below the target utilization, the autoscaler scales |
- * down the number of instances until it reaches the minimum number of |
- * instances you specified or until the average CPU of your instances reaches |
- * the target utilization. |
- * |
- * If the average CPU is above the target utilization, the autoscaler scales |
- * up until it reaches the maximum number of instances you specified or until |
- * the average utilization reaches the target utilization. |
+ * Specifies the disk name. If not specified, the default is to use the name |
+ * of the instance. |
*/ |
- core.double utilizationTarget; |
- |
- AutoscalingPolicyCpuUtilization(); |
- |
- AutoscalingPolicyCpuUtilization.fromJson(core.Map _json) { |
- if (_json.containsKey("utilizationTarget")) { |
- utilizationTarget = _json["utilizationTarget"]; |
- } |
- } |
- |
- core.Map<core.String, core.Object> toJson() { |
- final core.Map<core.String, core.Object> _json = new core.Map<core.String, core.Object>(); |
- if (utilizationTarget != null) { |
- _json["utilizationTarget"] = utilizationTarget; |
- } |
- return _json; |
- } |
-} |
- |
-/** Custom utilization metric policy. */ |
-class AutoscalingPolicyCustomMetricUtilization { |
+ core.String diskName; |
+ /** Specifies the size of the disk in base-2 GB. */ |
+ core.String diskSizeGb; |
/** |
- * The identifier (type) of the Stackdriver Monitoring metric. The metric |
- * cannot have negative values and should be a utilization metric, which means |
- * that the number of virtual machines handling requests should increase or |
- * decrease proportionally to the metric. |
+ * Specifies the disk type to use to create the instance. If not specified, |
+ * the default is pd-standard, specified using the full URL. For example: |
* |
- * The metric must have a value type of INT64 or DOUBLE. |
+ * https://www.googleapis.com/compute/v1/projects/project/zones/zone/diskTypes/pd-standard |
+ * |
+ * Other values include pd-ssd and local-ssd. If you define this field, you |
+ * can provide either the full or partial URL. For example, the following are |
+ * valid values: |
+ * - |
+ * https://www.googleapis.com/compute/v1/projects/project/zones/zone/diskTypes/diskType |
+ * - projects/project/zones/zone/diskTypes/diskType |
+ * - zones/zone/diskTypes/diskType Note that for InstanceTemplate, this is |
+ * the name of the disk type, not URL. |
*/ |
- core.String metric; |
+ core.String diskType; |
/** |
- * The target value of the metric that autoscaler should maintain. This must |
- * be a positive value. |
+ * The source image to create this disk. When creating a new instance, one of |
+ * initializeParams.sourceImage or disks.source is required. |
* |
- * For example, a good metric to use as a utilization_target is |
- * compute.googleapis.com/instance/network/received_bytes_count. The |
- * autoscaler will work to keep this value constant for each of the instances. |
+ * To create a disk with one of the public operating system images, specify |
+ * the image by its family name. For example, specify family/debian-8 to use |
+ * the latest Debian 8 image: |
+ * |
+ * projects/debian-cloud/global/images/family/debian-8 |
+ * |
+ * Alternatively, use a specific version of a public operating system image: |
+ * |
+ * projects/debian-cloud/global/images/debian-8-jessie-vYYYYMMDD |
+ * |
+ * To create a disk with a private image that you created, specify the image |
+ * name in the following format: |
+ * |
+ * global/images/my-private-image |
+ * |
+ * You can also specify a private image by its image family, which returns the |
+ * latest version of the image in that family. Replace the image name with |
+ * family/family-name: |
+ * |
+ * global/images/family/my-private-family |
+ * |
+ * If the source image is deleted later, this field will not be set. |
*/ |
- core.double utilizationTarget; |
+ core.String sourceImage; |
/** |
- * Defines how target utilization value is expressed for a Stackdriver |
- * Monitoring metric. Either GAUGE, DELTA_PER_SECOND, or DELTA_PER_MINUTE. If |
- * not specified, the default is GAUGE. |
- * Possible string values are: |
- * - "DELTA_PER_MINUTE" |
- * - "DELTA_PER_SECOND" |
- * - "GAUGE" |
+ * The customer-supplied encryption key of the source image. Required if the |
+ * source image is protected by a customer-supplied encryption key. |
+ * |
+ * Instance templates do not store customer-supplied encryption keys, so you |
+ * cannot create disks for instances in a managed instance group if the source |
+ * images are encrypted with your own keys. |
*/ |
- core.String utilizationTargetType; |
+ CustomerEncryptionKey sourceImageEncryptionKey; |
- AutoscalingPolicyCustomMetricUtilization(); |
+ AttachedDiskInitializeParams(); |
- AutoscalingPolicyCustomMetricUtilization.fromJson(core.Map _json) { |
- if (_json.containsKey("metric")) { |
- metric = _json["metric"]; |
+ AttachedDiskInitializeParams.fromJson(core.Map _json) { |
+ if (_json.containsKey("diskName")) { |
+ diskName = _json["diskName"]; |
} |
- if (_json.containsKey("utilizationTarget")) { |
- utilizationTarget = _json["utilizationTarget"]; |
+ if (_json.containsKey("diskSizeGb")) { |
+ diskSizeGb = _json["diskSizeGb"]; |
} |
- if (_json.containsKey("utilizationTargetType")) { |
- utilizationTargetType = _json["utilizationTargetType"]; |
+ if (_json.containsKey("diskType")) { |
+ diskType = _json["diskType"]; |
+ } |
+ if (_json.containsKey("sourceImage")) { |
+ sourceImage = _json["sourceImage"]; |
+ } |
+ if (_json.containsKey("sourceImageEncryptionKey")) { |
+ sourceImageEncryptionKey = new CustomerEncryptionKey.fromJson(_json["sourceImageEncryptionKey"]); |
} |
} |
core.Map<core.String, core.Object> toJson() { |
final core.Map<core.String, core.Object> _json = new core.Map<core.String, core.Object>(); |
- if (metric != null) { |
- _json["metric"] = metric; |
+ if (diskName != null) { |
+ _json["diskName"] = diskName; |
} |
- if (utilizationTarget != null) { |
- _json["utilizationTarget"] = utilizationTarget; |
+ if (diskSizeGb != null) { |
+ _json["diskSizeGb"] = diskSizeGb; |
} |
- if (utilizationTargetType != null) { |
- _json["utilizationTargetType"] = utilizationTargetType; |
+ if (diskType != null) { |
+ _json["diskType"] = diskType; |
} |
- return _json; |
- } |
-} |
- |
-/** Configuration parameters of autoscaling based on load balancing. */ |
-class AutoscalingPolicyLoadBalancingUtilization { |
- /** |
- * Fraction of backend capacity utilization (set in HTTP(s) load balancing |
- * configuration) that autoscaler should maintain. Must be a positive float |
- * value. If not defined, the default is 0.8. |
- */ |
- core.double utilizationTarget; |
- |
- AutoscalingPolicyLoadBalancingUtilization(); |
- |
- AutoscalingPolicyLoadBalancingUtilization.fromJson(core.Map _json) { |
- if (_json.containsKey("utilizationTarget")) { |
- utilizationTarget = _json["utilizationTarget"]; |
+ if (sourceImage != null) { |
+ _json["sourceImage"] = sourceImage; |
} |
- } |
- |
- core.Map<core.String, core.Object> toJson() { |
- final core.Map<core.String, core.Object> _json = new core.Map<core.String, core.Object>(); |
- if (utilizationTarget != null) { |
- _json["utilizationTarget"] = utilizationTarget; |
+ if (sourceImageEncryptionKey != null) { |
+ _json["sourceImageEncryptionKey"] = (sourceImageEncryptionKey).toJson(); |
} |
return _json; |
} |
} |
-/** Message containing information of one individual backend. */ |
-class Backend { |
- /** |
- * Specifies the balancing mode for this backend. For global HTTP(S) or |
- * TCP/SSL load balancing, the default is UTILIZATION. Valid values are |
- * UTILIZATION, RATE (for HTTP(S)) and CONNECTION (for TCP/SSL). |
- * |
- * This cannot be used for internal load balancing. |
- * Possible string values are: |
- * - "CONNECTION" |
- * - "RATE" |
- * - "UTILIZATION" |
- */ |
- core.String balancingMode; |
+/** |
+ * Represents an Autoscaler resource. Autoscalers allow you to automatically |
+ * scale virtual machine instances in managed instance groups according to an |
+ * autoscaling policy that you define. For more information, read Autoscaling |
+ * Groups of Instances. |
+ */ |
+class Autoscaler { |
/** |
- * A multiplier applied to the group'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,1.0]. |
+ * The configuration parameters for the autoscaling algorithm. You can define |
+ * one or more of the policies for an autoscaler: cpuUtilization, |
+ * customMetricUtilizations, and loadBalancingUtilization. |
* |
- * This cannot be used for internal load balancing. |
+ * If none of these are specified, the default will be to autoscale based on |
+ * cpuUtilization to 0.6 or 60%. |
*/ |
- core.double capacityScaler; |
+ AutoscalingPolicy autoscalingPolicy; |
+ /** [Output Only] Creation timestamp in RFC3339 text format. */ |
+ core.String creationTimestamp; |
/** |
* An optional description of this resource. Provide this property when you |
* create the resource. |
*/ |
core.String description; |
/** |
- * The fully-qualified URL of a zonal Instance Group resource. This instance |
- * group defines the list of instances that serve traffic. Member virtual |
- * machine instances from each instance group must live in the same zone as |
- * the instance group itself. No two backends in a backend service are allowed |
- * to use same Instance Group resource. |
- * |
- * Note that you must specify an Instance Group resource using the |
- * fully-qualified URL, rather than a partial URL. |
- * |
- * When the BackendService has load balancing scheme INTERNAL, the instance |
- * group must be in a zone within the same region as the BackendService. |
+ * [Output Only] The unique identifier for the resource. This identifier is |
+ * defined by the server. |
*/ |
- core.String group; |
+ core.String id; |
/** |
- * The max number of simultaneous connections for the group. Can be used with |
- * either CONNECTION or UTILIZATION balancing modes. For CONNECTION mode, |
- * either maxConnections or maxConnectionsPerInstance must be set. |
- * |
- * This cannot be used for internal load balancing. |
+ * [Output Only] Type of the resource. Always compute#autoscaler for |
+ * autoscalers. |
*/ |
- core.int maxConnections; |
+ core.String kind; |
/** |
- * The max number of simultaneous connections that a single backend instance |
- * can handle. This is used to calculate the capacity of the group. Can be |
- * used in either CONNECTION or UTILIZATION balancing modes. For CONNECTION |
- * mode, either maxConnections or maxConnectionsPerInstance must be set. |
- * |
- * This cannot be used for internal load balancing. |
+ * 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. |
*/ |
- core.int maxConnectionsPerInstance; |
+ core.String name; |
/** |
- * The max requests per second (RPS) of the group. Can be used with either |
- * RATE or UTILIZATION balancing modes, but required if RATE mode. For RATE |
- * mode, either maxRate or maxRatePerInstance must be set. |
- * |
- * This cannot be used for internal load balancing. |
+ * [Output Only] URL of the region where the instance group resides (for |
+ * autoscalers living in regional scope). |
*/ |
- core.int maxRate; |
+ core.String region; |
+ /** [Output Only] Server-defined URL for the resource. */ |
+ core.String selfLink; |
/** |
- * The max requests per second (RPS) that a single backend instance can |
- * handle. This is used to calculate the capacity of the group. Can be used in |
- * either balancing mode. For RATE mode, either maxRate or maxRatePerInstance |
- * must be set. |
- * |
- * This cannot be used for internal load balancing. |
+ * [Output Only] The status of the autoscaler configuration. |
+ * Possible string values are: |
+ * - "ACTIVE" |
+ * - "DELETING" |
+ * - "ERROR" |
+ * - "PENDING" |
*/ |
- core.double maxRatePerInstance; |
+ core.String status; |
/** |
- * Used when balancingMode is UTILIZATION. This ratio defines the CPU |
- * utilization target for the group. The default is 0.8. Valid range is [0.0, |
- * 1.0]. |
- * |
- * This cannot be used for internal load balancing. |
+ * [Output Only] Human-readable details about the current state of the |
+ * autoscaler. Read the documentation for Commonly returned status messages |
+ * for examples of status messages you might encounter. |
*/ |
- core.double maxUtilization; |
+ core.List<AutoscalerStatusDetails> statusDetails; |
+ /** URL of the managed instance group that this autoscaler will scale. */ |
+ core.String target; |
+ /** |
+ * [Output Only] URL of the zone where the instance group resides (for |
+ * autoscalers living in zonal scope). |
+ */ |
+ core.String zone; |
- Backend(); |
+ Autoscaler(); |
- Backend.fromJson(core.Map _json) { |
- if (_json.containsKey("balancingMode")) { |
- balancingMode = _json["balancingMode"]; |
+ Autoscaler.fromJson(core.Map _json) { |
+ if (_json.containsKey("autoscalingPolicy")) { |
+ autoscalingPolicy = new AutoscalingPolicy.fromJson(_json["autoscalingPolicy"]); |
} |
- if (_json.containsKey("capacityScaler")) { |
- capacityScaler = _json["capacityScaler"]; |
+ if (_json.containsKey("creationTimestamp")) { |
+ creationTimestamp = _json["creationTimestamp"]; |
} |
if (_json.containsKey("description")) { |
description = _json["description"]; |
} |
- if (_json.containsKey("group")) { |
- group = _json["group"]; |
+ if (_json.containsKey("id")) { |
+ id = _json["id"]; |
} |
- if (_json.containsKey("maxConnections")) { |
- maxConnections = _json["maxConnections"]; |
+ if (_json.containsKey("kind")) { |
+ kind = _json["kind"]; |
} |
- if (_json.containsKey("maxConnectionsPerInstance")) { |
- maxConnectionsPerInstance = _json["maxConnectionsPerInstance"]; |
+ if (_json.containsKey("name")) { |
+ name = _json["name"]; |
} |
- if (_json.containsKey("maxRate")) { |
- maxRate = _json["maxRate"]; |
+ if (_json.containsKey("region")) { |
+ region = _json["region"]; |
} |
- if (_json.containsKey("maxRatePerInstance")) { |
- maxRatePerInstance = _json["maxRatePerInstance"]; |
+ if (_json.containsKey("selfLink")) { |
+ selfLink = _json["selfLink"]; |
} |
- if (_json.containsKey("maxUtilization")) { |
- maxUtilization = _json["maxUtilization"]; |
+ if (_json.containsKey("status")) { |
+ status = _json["status"]; |
+ } |
+ if (_json.containsKey("statusDetails")) { |
+ statusDetails = _json["statusDetails"].map((value) => new AutoscalerStatusDetails.fromJson(value)).toList(); |
+ } |
+ if (_json.containsKey("target")) { |
+ target = _json["target"]; |
+ } |
+ if (_json.containsKey("zone")) { |
+ zone = _json["zone"]; |
} |
} |
core.Map<core.String, core.Object> toJson() { |
final core.Map<core.String, core.Object> _json = new core.Map<core.String, core.Object>(); |
- if (balancingMode != null) { |
- _json["balancingMode"] = balancingMode; |
+ if (autoscalingPolicy != null) { |
+ _json["autoscalingPolicy"] = (autoscalingPolicy).toJson(); |
} |
- if (capacityScaler != null) { |
- _json["capacityScaler"] = capacityScaler; |
+ if (creationTimestamp != null) { |
+ _json["creationTimestamp"] = creationTimestamp; |
} |
if (description != null) { |
_json["description"] = description; |
} |
- if (group != null) { |
- _json["group"] = group; |
+ if (id != null) { |
+ _json["id"] = id; |
} |
- if (maxConnections != null) { |
- _json["maxConnections"] = maxConnections; |
+ if (kind != null) { |
+ _json["kind"] = kind; |
} |
- if (maxConnectionsPerInstance != null) { |
- _json["maxConnectionsPerInstance"] = maxConnectionsPerInstance; |
+ if (name != null) { |
+ _json["name"] = name; |
} |
- if (maxRate != null) { |
- _json["maxRate"] = maxRate; |
+ if (region != null) { |
+ _json["region"] = region; |
} |
- if (maxRatePerInstance != null) { |
- _json["maxRatePerInstance"] = maxRatePerInstance; |
+ if (selfLink != null) { |
+ _json["selfLink"] = selfLink; |
} |
- if (maxUtilization != null) { |
- _json["maxUtilization"] = maxUtilization; |
+ if (status != null) { |
+ _json["status"] = status; |
+ } |
+ if (statusDetails != null) { |
+ _json["statusDetails"] = statusDetails.map((value) => (value).toJson()).toList(); |
+ } |
+ if (target != null) { |
+ _json["target"] = target; |
+ } |
+ if (zone != null) { |
+ _json["zone"] = zone; |
} |
return _json; |
} |
} |
-/** A BackendBucket resource. This resource defines a Cloud Storage bucket. */ |
-class BackendBucket { |
- /** Cloud Storage bucket name. */ |
- core.String bucketName; |
- /** [Output Only] Creation timestamp in RFC3339 text format. */ |
- core.String creationTimestamp; |
+class AutoscalerAggregatedList { |
/** |
- * An optional textual description of the resource; provided by the client |
- * when the resource is created. |
+ * [Output Only] The unique identifier for the resource. This identifier is |
+ * defined by the server. |
*/ |
- core.String description; |
- /** If true, enable Cloud CDN for this BackendBucket. */ |
- core.bool enableCdn; |
+ core.String id; |
+ /** A map of scoped autoscaler lists. */ |
+ core.Map<core.String, AutoscalersScopedList> items; |
/** |
- * [Output Only] Unique identifier for the resource; defined by the server. |
+ * [Output Only] Type of resource. Always compute#autoscalerAggregatedList for |
+ * aggregated lists of autoscalers. |
+ */ |
+ core.String kind; |
+ /** |
+ * [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. |
+ */ |
+ core.String nextPageToken; |
+ /** [Output Only] Server-defined URL for this resource. */ |
+ core.String selfLink; |
+ |
+ AutoscalerAggregatedList(); |
+ |
+ AutoscalerAggregatedList.fromJson(core.Map _json) { |
+ if (_json.containsKey("id")) { |
+ id = _json["id"]; |
+ } |
+ if (_json.containsKey("items")) { |
+ items = commons.mapMap<core.Map<core.String, core.Object>, AutoscalersScopedList>(_json["items"], (core.Map<core.String, core.Object> item) => new AutoscalersScopedList.fromJson(item)); |
+ } |
+ if (_json.containsKey("kind")) { |
+ kind = _json["kind"]; |
+ } |
+ if (_json.containsKey("nextPageToken")) { |
+ nextPageToken = _json["nextPageToken"]; |
+ } |
+ if (_json.containsKey("selfLink")) { |
+ selfLink = _json["selfLink"]; |
+ } |
+ } |
+ |
+ core.Map<core.String, core.Object> toJson() { |
+ final core.Map<core.String, core.Object> _json = new core.Map<core.String, core.Object>(); |
+ if (id != null) { |
+ _json["id"] = id; |
+ } |
+ if (items != null) { |
+ _json["items"] = commons.mapMap<AutoscalersScopedList, core.Map<core.String, core.Object>>(items, (AutoscalersScopedList item) => (item).toJson()); |
+ } |
+ if (kind != null) { |
+ _json["kind"] = kind; |
+ } |
+ if (nextPageToken != null) { |
+ _json["nextPageToken"] = nextPageToken; |
+ } |
+ if (selfLink != null) { |
+ _json["selfLink"] = selfLink; |
+ } |
+ return _json; |
+ } |
+} |
+ |
+/** Contains a list of Autoscaler resources. */ |
+class AutoscalerList { |
+ /** |
+ * [Output Only] The unique identifier for the resource. This identifier is |
+ * defined by the server. |
*/ |
core.String id; |
- /** Type of the resource. */ |
+ /** A list of Autoscaler resources. */ |
+ core.List<Autoscaler> items; |
+ /** |
+ * [Output Only] Type of resource. Always compute#autoscalerList for lists of |
+ * autoscalers. |
+ */ |
core.String kind; |
/** |
- * 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. |
+ * [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. |
+ */ |
+ core.String nextPageToken; |
+ /** [Output Only] Server-defined URL for this resource. */ |
+ core.String selfLink; |
+ |
+ AutoscalerList(); |
+ |
+ AutoscalerList.fromJson(core.Map _json) { |
+ if (_json.containsKey("id")) { |
+ id = _json["id"]; |
+ } |
+ if (_json.containsKey("items")) { |
+ items = _json["items"].map((value) => new Autoscaler.fromJson(value)).toList(); |
+ } |
+ if (_json.containsKey("kind")) { |
+ kind = _json["kind"]; |
+ } |
+ if (_json.containsKey("nextPageToken")) { |
+ nextPageToken = _json["nextPageToken"]; |
+ } |
+ if (_json.containsKey("selfLink")) { |
+ selfLink = _json["selfLink"]; |
+ } |
+ } |
+ |
+ core.Map<core.String, core.Object> toJson() { |
+ final core.Map<core.String, core.Object> _json = new core.Map<core.String, core.Object>(); |
+ if (id != null) { |
+ _json["id"] = id; |
+ } |
+ if (items != null) { |
+ _json["items"] = items.map((value) => (value).toJson()).toList(); |
+ } |
+ if (kind != null) { |
+ _json["kind"] = kind; |
+ } |
+ if (nextPageToken != null) { |
+ _json["nextPageToken"] = nextPageToken; |
+ } |
+ if (selfLink != null) { |
+ _json["selfLink"] = selfLink; |
+ } |
+ return _json; |
+ } |
+} |
+ |
+class AutoscalerStatusDetails { |
+ /** The status message. */ |
+ core.String message; |
+ /** |
+ * The type of error returned. |
+ * Possible string values are: |
+ * - "ALL_INSTANCES_UNHEALTHY" |
+ * - "BACKEND_SERVICE_DOES_NOT_EXIST" |
+ * - "CAPPED_AT_MAX_NUM_REPLICAS" |
+ * - "CUSTOM_METRIC_DATA_POINTS_TOO_SPARSE" |
+ * - "CUSTOM_METRIC_INVALID" |
+ * - "MIN_EQUALS_MAX" |
+ * - "MISSING_CUSTOM_METRIC_DATA_POINTS" |
+ * - "MISSING_LOAD_BALANCING_DATA_POINTS" |
+ * - "MORE_THAN_ONE_BACKEND_SERVICE" |
+ * - "NOT_ENOUGH_QUOTA_AVAILABLE" |
+ * - "REGION_RESOURCE_STOCKOUT" |
+ * - "SCALING_TARGET_DOES_NOT_EXIST" |
+ * - "UNKNOWN" |
+ * - "UNSUPPORTED_MAX_RATE_LOAD_BALANCING_CONFIGURATION" |
+ * - "ZONE_RESOURCE_STOCKOUT" |
+ */ |
+ core.String type; |
+ |
+ AutoscalerStatusDetails(); |
+ |
+ AutoscalerStatusDetails.fromJson(core.Map _json) { |
+ if (_json.containsKey("message")) { |
+ message = _json["message"]; |
+ } |
+ if (_json.containsKey("type")) { |
+ type = _json["type"]; |
+ } |
+ } |
+ |
+ core.Map<core.String, core.Object> toJson() { |
+ final core.Map<core.String, core.Object> _json = new core.Map<core.String, core.Object>(); |
+ if (message != null) { |
+ _json["message"] = message; |
+ } |
+ if (type != null) { |
+ _json["type"] = type; |
+ } |
+ return _json; |
+ } |
+} |
+ |
+class AutoscalersScopedListWarningData { |
+ /** |
+ * [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). |
+ */ |
+ core.String key; |
+ /** [Output Only] A warning data value corresponding to the key. */ |
+ core.String value; |
+ |
+ AutoscalersScopedListWarningData(); |
+ |
+ AutoscalersScopedListWarningData.fromJson(core.Map _json) { |
+ if (_json.containsKey("key")) { |
+ key = _json["key"]; |
+ } |
+ if (_json.containsKey("value")) { |
+ value = _json["value"]; |
+ } |
+ } |
+ |
+ core.Map<core.String, core.Object> toJson() { |
+ final core.Map<core.String, core.Object> _json = new core.Map<core.String, core.Object>(); |
+ if (key != null) { |
+ _json["key"] = key; |
+ } |
+ if (value != null) { |
+ _json["value"] = value; |
+ } |
+ return _json; |
+ } |
+} |
+ |
+/** |
+ * [Output Only] Informational warning which replaces the list of autoscalers |
+ * when the list is empty. |
+ */ |
+class AutoscalersScopedListWarning { |
+ /** |
+ * [Output Only] A warning code, if applicable. For example, Compute Engine |
+ * returns NO_RESULTS_ON_PAGE if there are no results in the response. |
+ * Possible string values are: |
+ * - "CLEANUP_FAILED" |
+ * - "DEPRECATED_RESOURCE_USED" |
+ * - "DISK_SIZE_LARGER_THAN_IMAGE_SIZE" |
+ * - "FIELD_VALUE_OVERRIDEN" |
+ * - "INJECTED_KERNELS_DEPRECATED" |
+ * - "NEXT_HOP_ADDRESS_NOT_ASSIGNED" |
+ * - "NEXT_HOP_CANNOT_IP_FORWARD" |
+ * - "NEXT_HOP_INSTANCE_NOT_FOUND" |
+ * - "NEXT_HOP_INSTANCE_NOT_ON_NETWORK" |
+ * - "NEXT_HOP_NOT_RUNNING" |
+ * - "NOT_CRITICAL_ERROR" |
+ * - "NO_RESULTS_ON_PAGE" |
+ * - "REQUIRED_TOS_AGREEMENT" |
+ * - "RESOURCE_IN_USE_BY_OTHER_RESOURCE_WARNING" |
+ * - "RESOURCE_NOT_DELETED" |
+ * - "SINGLE_INSTANCE_PROPERTY_TEMPLATE" |
+ * - "UNREACHABLE" |
+ */ |
+ core.String code; |
+ /** |
+ * [Output Only] Metadata about this warning in key: value format. For |
+ * example: |
+ * "data": [ { "key": "scope", "value": "zones/us-east1-d" } |
+ */ |
+ core.List<AutoscalersScopedListWarningData> data; |
+ /** [Output Only] A human-readable description of the warning code. */ |
+ core.String message; |
+ |
+ AutoscalersScopedListWarning(); |
+ |
+ AutoscalersScopedListWarning.fromJson(core.Map _json) { |
+ if (_json.containsKey("code")) { |
+ code = _json["code"]; |
+ } |
+ if (_json.containsKey("data")) { |
+ data = _json["data"].map((value) => new AutoscalersScopedListWarningData.fromJson(value)).toList(); |
+ } |
+ if (_json.containsKey("message")) { |
+ message = _json["message"]; |
+ } |
+ } |
+ |
+ core.Map<core.String, core.Object> toJson() { |
+ final core.Map<core.String, core.Object> _json = new core.Map<core.String, core.Object>(); |
+ if (code != null) { |
+ _json["code"] = code; |
+ } |
+ if (data != null) { |
+ _json["data"] = data.map((value) => (value).toJson()).toList(); |
+ } |
+ if (message != null) { |
+ _json["message"] = message; |
+ } |
+ return _json; |
+ } |
+} |
+ |
+class AutoscalersScopedList { |
+ /** [Output Only] List of autoscalers contained in this scope. */ |
+ core.List<Autoscaler> autoscalers; |
+ /** |
+ * [Output Only] Informational warning which replaces the list of autoscalers |
+ * when the list is empty. |
+ */ |
+ AutoscalersScopedListWarning warning; |
+ |
+ AutoscalersScopedList(); |
+ |
+ AutoscalersScopedList.fromJson(core.Map _json) { |
+ if (_json.containsKey("autoscalers")) { |
+ autoscalers = _json["autoscalers"].map((value) => new Autoscaler.fromJson(value)).toList(); |
+ } |
+ if (_json.containsKey("warning")) { |
+ warning = new AutoscalersScopedListWarning.fromJson(_json["warning"]); |
+ } |
+ } |
+ |
+ core.Map<core.String, core.Object> toJson() { |
+ final core.Map<core.String, core.Object> _json = new core.Map<core.String, core.Object>(); |
+ if (autoscalers != null) { |
+ _json["autoscalers"] = autoscalers.map((value) => (value).toJson()).toList(); |
+ } |
+ if (warning != null) { |
+ _json["warning"] = (warning).toJson(); |
+ } |
+ return _json; |
+ } |
+} |
+ |
+/** Cloud Autoscaler policy. */ |
+class AutoscalingPolicy { |
+ /** |
+ * The number of seconds that the autoscaler should wait before it starts |
+ * collecting information from a new instance. This prevents the autoscaler |
+ * from collecting information when the instance is initializing, during which |
+ * the collected usage would not be reliable. The default time autoscaler |
+ * waits is 60 seconds. |
+ * |
+ * Virtual machine initialization times might vary because of numerous |
+ * factors. We recommend that you test how long an instance may take to |
+ * initialize. To do this, create an instance and time the startup process. |
+ */ |
+ core.int coolDownPeriodSec; |
+ /** |
+ * Defines the CPU utilization policy that allows the autoscaler to scale |
+ * based on the average CPU utilization of a managed instance group. |
+ */ |
+ AutoscalingPolicyCpuUtilization cpuUtilization; |
+ /** Configuration parameters of autoscaling based on a custom metric. */ |
+ core.List<AutoscalingPolicyCustomMetricUtilization> customMetricUtilizations; |
+ /** Configuration parameters of autoscaling based on load balancer. */ |
+ AutoscalingPolicyLoadBalancingUtilization loadBalancingUtilization; |
+ /** |
+ * The maximum number of instances that the autoscaler can scale up to. This |
+ * is required when creating or updating an autoscaler. The maximum number of |
+ * replicas should not be lower than minimal number of replicas. |
+ */ |
+ core.int maxNumReplicas; |
+ /** |
+ * The minimum number of replicas that the autoscaler can scale down to. This |
+ * cannot be less than 0. If not provided, autoscaler will choose a default |
+ * value depending on maximum number of instances allowed. |
+ */ |
+ core.int minNumReplicas; |
+ |
+ AutoscalingPolicy(); |
+ |
+ AutoscalingPolicy.fromJson(core.Map _json) { |
+ if (_json.containsKey("coolDownPeriodSec")) { |
+ coolDownPeriodSec = _json["coolDownPeriodSec"]; |
+ } |
+ if (_json.containsKey("cpuUtilization")) { |
+ cpuUtilization = new AutoscalingPolicyCpuUtilization.fromJson(_json["cpuUtilization"]); |
+ } |
+ if (_json.containsKey("customMetricUtilizations")) { |
+ customMetricUtilizations = _json["customMetricUtilizations"].map((value) => new AutoscalingPolicyCustomMetricUtilization.fromJson(value)).toList(); |
+ } |
+ if (_json.containsKey("loadBalancingUtilization")) { |
+ loadBalancingUtilization = new AutoscalingPolicyLoadBalancingUtilization.fromJson(_json["loadBalancingUtilization"]); |
+ } |
+ if (_json.containsKey("maxNumReplicas")) { |
+ maxNumReplicas = _json["maxNumReplicas"]; |
+ } |
+ if (_json.containsKey("minNumReplicas")) { |
+ minNumReplicas = _json["minNumReplicas"]; |
+ } |
+ } |
+ |
+ core.Map<core.String, core.Object> toJson() { |
+ final core.Map<core.String, core.Object> _json = new core.Map<core.String, core.Object>(); |
+ if (coolDownPeriodSec != null) { |
+ _json["coolDownPeriodSec"] = coolDownPeriodSec; |
+ } |
+ if (cpuUtilization != null) { |
+ _json["cpuUtilization"] = (cpuUtilization).toJson(); |
+ } |
+ if (customMetricUtilizations != null) { |
+ _json["customMetricUtilizations"] = customMetricUtilizations.map((value) => (value).toJson()).toList(); |
+ } |
+ if (loadBalancingUtilization != null) { |
+ _json["loadBalancingUtilization"] = (loadBalancingUtilization).toJson(); |
+ } |
+ if (maxNumReplicas != null) { |
+ _json["maxNumReplicas"] = maxNumReplicas; |
+ } |
+ if (minNumReplicas != null) { |
+ _json["minNumReplicas"] = minNumReplicas; |
+ } |
+ return _json; |
+ } |
+} |
+ |
+/** CPU utilization policy. */ |
+class AutoscalingPolicyCpuUtilization { |
+ /** |
+ * The target CPU utilization that the autoscaler should maintain. Must be a |
+ * float value in the range (0, 1]. If not specified, the default is 0.6. |
+ * |
+ * If the CPU level is below the target utilization, the autoscaler scales |
+ * down the number of instances until it reaches the minimum number of |
+ * instances you specified or until the average CPU of your instances reaches |
+ * the target utilization. |
+ * |
+ * If the average CPU is above the target utilization, the autoscaler scales |
+ * up until it reaches the maximum number of instances you specified or until |
+ * the average utilization reaches the target utilization. |
+ */ |
+ core.double utilizationTarget; |
+ |
+ AutoscalingPolicyCpuUtilization(); |
+ |
+ AutoscalingPolicyCpuUtilization.fromJson(core.Map _json) { |
+ if (_json.containsKey("utilizationTarget")) { |
+ utilizationTarget = _json["utilizationTarget"]; |
+ } |
+ } |
+ |
+ core.Map<core.String, core.Object> toJson() { |
+ final core.Map<core.String, core.Object> _json = new core.Map<core.String, core.Object>(); |
+ if (utilizationTarget != null) { |
+ _json["utilizationTarget"] = utilizationTarget; |
+ } |
+ return _json; |
+ } |
+} |
+ |
+/** Custom utilization metric policy. */ |
+class AutoscalingPolicyCustomMetricUtilization { |
+ /** |
+ * The identifier (type) of the Stackdriver Monitoring metric. The metric |
+ * cannot have negative values and should be a utilization metric, which means |
+ * that the number of virtual machines handling requests should increase or |
+ * decrease proportionally to the metric. |
+ * |
+ * The metric must have a value type of INT64 or DOUBLE. |
+ */ |
+ core.String metric; |
+ /** |
+ * The target value of the metric that autoscaler should maintain. This must |
+ * be a positive value. |
+ * |
+ * For example, a good metric to use as a utilization_target is |
+ * compute.googleapis.com/instance/network/received_bytes_count. The |
+ * autoscaler will work to keep this value constant for each of the instances. |
+ */ |
+ core.double utilizationTarget; |
+ /** |
+ * Defines how target utilization value is expressed for a Stackdriver |
+ * Monitoring metric. Either GAUGE, DELTA_PER_SECOND, or DELTA_PER_MINUTE. If |
+ * not specified, the default is GAUGE. |
+ * Possible string values are: |
+ * - "DELTA_PER_MINUTE" |
+ * - "DELTA_PER_SECOND" |
+ * - "GAUGE" |
+ */ |
+ core.String utilizationTargetType; |
+ |
+ AutoscalingPolicyCustomMetricUtilization(); |
+ |
+ AutoscalingPolicyCustomMetricUtilization.fromJson(core.Map _json) { |
+ if (_json.containsKey("metric")) { |
+ metric = _json["metric"]; |
+ } |
+ if (_json.containsKey("utilizationTarget")) { |
+ utilizationTarget = _json["utilizationTarget"]; |
+ } |
+ if (_json.containsKey("utilizationTargetType")) { |
+ utilizationTargetType = _json["utilizationTargetType"]; |
+ } |
+ } |
+ |
+ core.Map<core.String, core.Object> toJson() { |
+ final core.Map<core.String, core.Object> _json = new core.Map<core.String, core.Object>(); |
+ if (metric != null) { |
+ _json["metric"] = metric; |
+ } |
+ if (utilizationTarget != null) { |
+ _json["utilizationTarget"] = utilizationTarget; |
+ } |
+ if (utilizationTargetType != null) { |
+ _json["utilizationTargetType"] = utilizationTargetType; |
+ } |
+ return _json; |
+ } |
+} |
+ |
+/** Configuration parameters of autoscaling based on load balancing. */ |
+class AutoscalingPolicyLoadBalancingUtilization { |
+ /** |
+ * Fraction of backend capacity utilization (set in HTTP(s) load balancing |
+ * configuration) that autoscaler should maintain. Must be a positive float |
+ * value. If not defined, the default is 0.8. |
+ */ |
+ core.double utilizationTarget; |
+ |
+ AutoscalingPolicyLoadBalancingUtilization(); |
+ |
+ AutoscalingPolicyLoadBalancingUtilization.fromJson(core.Map _json) { |
+ if (_json.containsKey("utilizationTarget")) { |
+ utilizationTarget = _json["utilizationTarget"]; |
+ } |
+ } |
+ |
+ core.Map<core.String, core.Object> toJson() { |
+ final core.Map<core.String, core.Object> _json = new core.Map<core.String, core.Object>(); |
+ if (utilizationTarget != null) { |
+ _json["utilizationTarget"] = utilizationTarget; |
+ } |
+ return _json; |
+ } |
+} |
+ |
+/** Message containing information of one individual backend. */ |
+class Backend { |
+ /** |
+ * Specifies the balancing mode for this backend. For global HTTP(S) or |
+ * TCP/SSL load balancing, the default is UTILIZATION. Valid values are |
+ * UTILIZATION, RATE (for HTTP(S)) and CONNECTION (for TCP/SSL). |
+ * |
+ * This cannot be used for internal load balancing. |
+ * Possible string values are: |
+ * - "CONNECTION" |
+ * - "RATE" |
+ * - "UTILIZATION" |
+ */ |
+ core.String balancingMode; |
+ /** |
+ * A multiplier applied to the group'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,1.0]. |
+ * |
+ * This cannot be used for internal load balancing. |
+ */ |
+ core.double capacityScaler; |
+ /** |
+ * An optional description of this resource. Provide this property when you |
+ * create the resource. |
+ */ |
+ core.String description; |
+ /** |
+ * The fully-qualified URL of a zonal Instance Group resource. This instance |
+ * group defines the list of instances that serve traffic. Member virtual |
+ * machine instances from each instance group must live in the same zone as |
+ * the instance group itself. No two backends in a backend service are allowed |
+ * to use same Instance Group resource. |
+ * |
+ * Note that you must specify an Instance Group resource using the |
+ * fully-qualified URL, rather than a partial URL. |
+ * |
+ * When the BackendService has load balancing scheme INTERNAL, the instance |
+ * group must be in a zone within the same region as the BackendService. |
+ */ |
+ core.String group; |
+ /** |
+ * The max number of simultaneous connections for the group. Can be used with |
+ * either CONNECTION or UTILIZATION balancing modes. For CONNECTION mode, |
+ * either maxConnections or maxConnectionsPerInstance must be set. |
+ * |
+ * This cannot be used for internal load balancing. |
+ */ |
+ core.int maxConnections; |
+ /** |
+ * The max number of simultaneous connections that a single backend instance |
+ * can handle. This is used to calculate the capacity of the group. Can be |
+ * used in either CONNECTION or UTILIZATION balancing modes. For CONNECTION |
+ * mode, either maxConnections or maxConnectionsPerInstance must be set. |
+ * |
+ * This cannot be used for internal load balancing. |
+ */ |
+ core.int maxConnectionsPerInstance; |
+ /** |
+ * The max requests per second (RPS) of the group. Can be used with either |
+ * RATE or UTILIZATION balancing modes, but required if RATE mode. For RATE |
+ * mode, either maxRate or maxRatePerInstance must be set. |
+ * |
+ * This cannot be used for internal load balancing. |
+ */ |
+ core.int maxRate; |
+ /** |
+ * The max requests per second (RPS) that a single backend instance can |
+ * handle. This is used to calculate the capacity of the group. Can be used in |
+ * either balancing mode. For RATE mode, either maxRate or maxRatePerInstance |
+ * must be set. |
+ * |
+ * This cannot be used for internal load balancing. |
+ */ |
+ core.double maxRatePerInstance; |
+ /** |
+ * Used when balancingMode is UTILIZATION. This ratio defines the CPU |
+ * utilization target for the group. The default is 0.8. Valid range is [0.0, |
+ * 1.0]. |
+ * |
+ * This cannot be used for internal load balancing. |
+ */ |
+ core.double maxUtilization; |
+ |
+ Backend(); |
+ |
+ Backend.fromJson(core.Map _json) { |
+ if (_json.containsKey("balancingMode")) { |
+ balancingMode = _json["balancingMode"]; |
+ } |
+ if (_json.containsKey("capacityScaler")) { |
+ capacityScaler = _json["capacityScaler"]; |
+ } |
+ if (_json.containsKey("description")) { |
+ description = _json["description"]; |
+ } |
+ if (_json.containsKey("group")) { |
+ group = _json["group"]; |
+ } |
+ if (_json.containsKey("maxConnections")) { |
+ maxConnections = _json["maxConnections"]; |
+ } |
+ if (_json.containsKey("maxConnectionsPerInstance")) { |
+ maxConnectionsPerInstance = _json["maxConnectionsPerInstance"]; |
+ } |
+ if (_json.containsKey("maxRate")) { |
+ maxRate = _json["maxRate"]; |
+ } |
+ if (_json.containsKey("maxRatePerInstance")) { |
+ maxRatePerInstance = _json["maxRatePerInstance"]; |
+ } |
+ if (_json.containsKey("maxUtilization")) { |
+ maxUtilization = _json["maxUtilization"]; |
+ } |
+ } |
+ |
+ core.Map<core.String, core.Object> toJson() { |
+ final core.Map<core.String, core.Object> _json = new core.Map<core.String, core.Object>(); |
+ if (balancingMode != null) { |
+ _json["balancingMode"] = balancingMode; |
+ } |
+ if (capacityScaler != null) { |
+ _json["capacityScaler"] = capacityScaler; |
+ } |
+ if (description != null) { |
+ _json["description"] = description; |
+ } |
+ if (group != null) { |
+ _json["group"] = group; |
+ } |
+ if (maxConnections != null) { |
+ _json["maxConnections"] = maxConnections; |
+ } |
+ if (maxConnectionsPerInstance != null) { |
+ _json["maxConnectionsPerInstance"] = maxConnectionsPerInstance; |
+ } |
+ if (maxRate != null) { |
+ _json["maxRate"] = maxRate; |
+ } |
+ if (maxRatePerInstance != null) { |
+ _json["maxRatePerInstance"] = maxRatePerInstance; |
+ } |
+ if (maxUtilization != null) { |
+ _json["maxUtilization"] = maxUtilization; |
+ } |
+ return _json; |
+ } |
+} |
+ |
+/** A BackendBucket resource. This resource defines a Cloud Storage bucket. */ |
+class BackendBucket { |
+ /** Cloud Storage bucket name. */ |
+ core.String bucketName; |
+ /** [Output Only] Creation timestamp in RFC3339 text format. */ |
+ core.String creationTimestamp; |
+ /** |
+ * An optional textual description of the resource; provided by the client |
+ * when the resource is created. |
+ */ |
+ core.String description; |
+ /** If true, enable Cloud CDN for this BackendBucket. */ |
+ core.bool enableCdn; |
+ /** |
+ * [Output Only] Unique identifier for the resource; defined by the server. |
+ */ |
+ core.String id; |
+ /** Type of the resource. */ |
+ core.String kind; |
+ /** |
+ * 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. |
+ */ |
+ core.String name; |
+ /** [Output Only] Server-defined URL for the resource. */ |
+ core.String selfLink; |
+ |
+ BackendBucket(); |
+ |
+ BackendBucket.fromJson(core.Map _json) { |
+ if (_json.containsKey("bucketName")) { |
+ bucketName = _json["bucketName"]; |
+ } |
+ if (_json.containsKey("creationTimestamp")) { |
+ creationTimestamp = _json["creationTimestamp"]; |
+ } |
+ if (_json.containsKey("description")) { |
+ description = _json["description"]; |
+ } |
+ if (_json.containsKey("enableCdn")) { |
+ enableCdn = _json["enableCdn"]; |
+ } |
+ if (_json.containsKey("id")) { |
+ id = _json["id"]; |
+ } |
+ if (_json.containsKey("kind")) { |
+ kind = _json["kind"]; |
+ } |
+ if (_json.containsKey("name")) { |
+ name = _json["name"]; |
+ } |
+ if (_json.containsKey("selfLink")) { |
+ selfLink = _json["selfLink"]; |
+ } |
+ } |
+ |
+ core.Map<core.String, core.Object> toJson() { |
+ final core.Map<core.String, core.Object> _json = new core.Map<core.String, core.Object>(); |
+ if (bucketName != null) { |
+ _json["bucketName"] = bucketName; |
+ } |
+ if (creationTimestamp != null) { |
+ _json["creationTimestamp"] = creationTimestamp; |
+ } |
+ if (description != null) { |
+ _json["description"] = description; |
+ } |
+ if (enableCdn != null) { |
+ _json["enableCdn"] = enableCdn; |
+ } |
+ if (id != null) { |
+ _json["id"] = id; |
+ } |
+ if (kind != null) { |
+ _json["kind"] = kind; |
+ } |
+ if (name != null) { |
+ _json["name"] = name; |
+ } |
+ if (selfLink != null) { |
+ _json["selfLink"] = selfLink; |
+ } |
+ return _json; |
+ } |
+} |
+ |
+/** Contains a list of BackendBucket resources. */ |
+class BackendBucketList { |
+ /** |
+ * [Output Only] Unique identifier for the resource; defined by the server. |
+ */ |
+ core.String id; |
+ /** A list of BackendBucket resources. */ |
+ core.List<BackendBucket> items; |
+ /** Type of resource. */ |
+ core.String kind; |
+ /** [Output Only] A token used to continue a truncated list request. */ |
+ core.String nextPageToken; |
+ /** [Output Only] Server-defined URL for this resource. */ |
+ core.String selfLink; |
+ |
+ BackendBucketList(); |
+ |
+ BackendBucketList.fromJson(core.Map _json) { |
+ if (_json.containsKey("id")) { |
+ id = _json["id"]; |
+ } |
+ if (_json.containsKey("items")) { |
+ items = _json["items"].map((value) => new BackendBucket.fromJson(value)).toList(); |
+ } |
+ if (_json.containsKey("kind")) { |
+ kind = _json["kind"]; |
+ } |
+ if (_json.containsKey("nextPageToken")) { |
+ nextPageToken = _json["nextPageToken"]; |
+ } |
+ if (_json.containsKey("selfLink")) { |
+ selfLink = _json["selfLink"]; |
+ } |
+ } |
+ |
+ core.Map<core.String, core.Object> toJson() { |
+ final core.Map<core.String, core.Object> _json = new core.Map<core.String, core.Object>(); |
+ if (id != null) { |
+ _json["id"] = id; |
+ } |
+ if (items != null) { |
+ _json["items"] = items.map((value) => (value).toJson()).toList(); |
+ } |
+ if (kind != null) { |
+ _json["kind"] = kind; |
+ } |
+ if (nextPageToken != null) { |
+ _json["nextPageToken"] = nextPageToken; |
+ } |
+ if (selfLink != null) { |
+ _json["selfLink"] = selfLink; |
+ } |
+ return _json; |
+ } |
+} |
+ |
+/** |
+ * A BackendService resource. This resource defines a group of backend virtual |
+ * machines and their serving capacity. |
+ */ |
+class BackendService { |
+ /** |
+ * Lifetime of cookies in seconds if session_affinity is GENERATED_COOKIE. 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 for TTL is one |
+ * day. |
+ * |
+ * When the load balancing scheme is INTERNAL, this field is not used. |
+ */ |
+ core.int affinityCookieTtlSec; |
+ /** The list of backends that serve this BackendService. */ |
+ core.List<Backend> backends; |
+ /** Cloud CDN configuration for this BackendService. */ |
+ BackendServiceCdnPolicy cdnPolicy; |
+ ConnectionDraining connectionDraining; |
+ /** [Output Only] Creation timestamp in RFC3339 text format. */ |
+ core.String creationTimestamp; |
+ /** |
+ * An optional description of this resource. Provide this property when you |
+ * create the resource. |
+ */ |
+ core.String description; |
+ /** |
+ * If true, enable Cloud CDN for this BackendService. |
+ * |
+ * When the load balancing scheme is INTERNAL, this field is not used. |
+ */ |
+ core.bool enableCDN; |
+ /** |
+ * 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. |
+ */ |
+ core.String fingerprint; |
+ core.List<core.int> get fingerprintAsBytes { |
+ return convert.BASE64.decode(fingerprint); |
+ } |
+ |
+ void set fingerprintAsBytes(core.List<core.int> _bytes) { |
+ fingerprint = convert.BASE64.encode(_bytes).replaceAll("/", "_").replaceAll("+", "-"); |
+ } |
+ /** |
+ * The list of URLs to the HttpHealthCheck or HttpsHealthCheck resource for |
+ * health checking this BackendService. Currently at most one health check can |
+ * be specified, and a health check is required for GCE backend services. A |
+ * health check must not be specified for GAE app backend and Cloud Function |
+ * backend. |
+ * |
+ * For internal load balancing, a URL to a HealthCheck resource must be |
+ * specified instead. |
+ */ |
+ core.List<core.String> healthChecks; |
+ BackendServiceIAP iap; |
+ /** |
+ * [Output Only] The unique identifier for the resource. This identifier is |
+ * defined by the server. |
+ */ |
+ core.String id; |
+ /** |
+ * [Output Only] Type of resource. Always compute#backendService for backend |
+ * services. |
+ */ |
+ core.String kind; |
+ /** |
+ * |
+ * Possible string values are: |
+ * - "EXTERNAL" |
+ * - "INTERNAL" |
+ * - "INVALID_LOAD_BALANCING_SCHEME" |
+ */ |
+ core.String loadBalancingScheme; |
+ /** |
+ * 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. |
+ */ |
+ core.String name; |
+ /** |
+ * Deprecated in favor of portName. The TCP port to connect on the backend. |
+ * The default value is 80. |
+ * |
+ * This cannot be used for internal load balancing. |
+ */ |
+ core.int port; |
+ /** |
+ * Name of backend port. The same name should appear in the instance groups |
+ * referenced by this service. Required when the load balancing scheme is |
+ * EXTERNAL. |
+ * |
+ * When the load balancing scheme is INTERNAL, this field is not used. |
+ */ |
+ core.String portName; |
+ /** |
+ * The protocol this BackendService uses to communicate with backends. |
+ * |
+ * Possible values are HTTP, HTTPS, TCP, and SSL. The default is HTTP. |
+ * |
+ * For internal load balancing, the possible values are TCP and UDP, and the |
+ * default is TCP. |
+ * Possible string values are: |
+ * - "HTTP" |
+ * - "HTTPS" |
+ * - "SSL" |
+ * - "TCP" |
+ * - "UDP" |
+ */ |
+ core.String protocol; |
+ /** |
+ * [Output Only] URL of the region where the regional backend service resides. |
+ * This field is not applicable to global backend services. |
+ */ |
+ core.String region; |
+ /** [Output Only] Server-defined URL for the resource. */ |
+ core.String selfLink; |
+ /** |
+ * Type of session affinity to use. The default is NONE. |
+ * |
+ * When the load balancing scheme is EXTERNAL, can be NONE, CLIENT_IP, or |
+ * GENERATED_COOKIE. |
+ * |
+ * When the load balancing scheme is INTERNAL, can be NONE, CLIENT_IP, |
+ * CLIENT_IP_PROTO, or CLIENT_IP_PORT_PROTO. |
+ * |
+ * When the protocol is UDP, this field is not used. |
+ * Possible string values are: |
+ * - "CLIENT_IP" |
+ * - "CLIENT_IP_PORT_PROTO" |
+ * - "CLIENT_IP_PROTO" |
+ * - "GENERATED_COOKIE" |
+ * - "NONE" |
+ */ |
+ core.String sessionAffinity; |
+ /** |
+ * How many seconds to wait for the backend before considering it a failed |
+ * request. Default is 30 seconds. |
+ */ |
+ core.int timeoutSec; |
+ |
+ BackendService(); |
+ |
+ BackendService.fromJson(core.Map _json) { |
+ if (_json.containsKey("affinityCookieTtlSec")) { |
+ affinityCookieTtlSec = _json["affinityCookieTtlSec"]; |
+ } |
+ if (_json.containsKey("backends")) { |
+ backends = _json["backends"].map((value) => new Backend.fromJson(value)).toList(); |
+ } |
+ if (_json.containsKey("cdnPolicy")) { |
+ cdnPolicy = new BackendServiceCdnPolicy.fromJson(_json["cdnPolicy"]); |
+ } |
+ if (_json.containsKey("connectionDraining")) { |
+ connectionDraining = new ConnectionDraining.fromJson(_json["connectionDraining"]); |
+ } |
+ if (_json.containsKey("creationTimestamp")) { |
+ creationTimestamp = _json["creationTimestamp"]; |
+ } |
+ if (_json.containsKey("description")) { |
+ description = _json["description"]; |
+ } |
+ if (_json.containsKey("enableCDN")) { |
+ enableCDN = _json["enableCDN"]; |
+ } |
+ if (_json.containsKey("fingerprint")) { |
+ fingerprint = _json["fingerprint"]; |
+ } |
+ if (_json.containsKey("healthChecks")) { |
+ healthChecks = _json["healthChecks"]; |
+ } |
+ if (_json.containsKey("iap")) { |
+ iap = new BackendServiceIAP.fromJson(_json["iap"]); |
+ } |
+ if (_json.containsKey("id")) { |
+ id = _json["id"]; |
+ } |
+ if (_json.containsKey("kind")) { |
+ kind = _json["kind"]; |
+ } |
+ if (_json.containsKey("loadBalancingScheme")) { |
+ loadBalancingScheme = _json["loadBalancingScheme"]; |
+ } |
+ if (_json.containsKey("name")) { |
+ name = _json["name"]; |
+ } |
+ if (_json.containsKey("port")) { |
+ port = _json["port"]; |
+ } |
+ if (_json.containsKey("portName")) { |
+ portName = _json["portName"]; |
+ } |
+ if (_json.containsKey("protocol")) { |
+ protocol = _json["protocol"]; |
+ } |
+ if (_json.containsKey("region")) { |
+ region = _json["region"]; |
+ } |
+ if (_json.containsKey("selfLink")) { |
+ selfLink = _json["selfLink"]; |
+ } |
+ if (_json.containsKey("sessionAffinity")) { |
+ sessionAffinity = _json["sessionAffinity"]; |
+ } |
+ if (_json.containsKey("timeoutSec")) { |
+ timeoutSec = _json["timeoutSec"]; |
+ } |
+ } |
+ |
+ core.Map<core.String, core.Object> toJson() { |
+ final core.Map<core.String, core.Object> _json = new core.Map<core.String, core.Object>(); |
+ if (affinityCookieTtlSec != null) { |
+ _json["affinityCookieTtlSec"] = affinityCookieTtlSec; |
+ } |
+ if (backends != null) { |
+ _json["backends"] = backends.map((value) => (value).toJson()).toList(); |
+ } |
+ if (cdnPolicy != null) { |
+ _json["cdnPolicy"] = (cdnPolicy).toJson(); |
+ } |
+ if (connectionDraining != null) { |
+ _json["connectionDraining"] = (connectionDraining).toJson(); |
+ } |
+ if (creationTimestamp != null) { |
+ _json["creationTimestamp"] = creationTimestamp; |
+ } |
+ if (description != null) { |
+ _json["description"] = description; |
+ } |
+ if (enableCDN != null) { |
+ _json["enableCDN"] = enableCDN; |
+ } |
+ if (fingerprint != null) { |
+ _json["fingerprint"] = fingerprint; |
+ } |
+ if (healthChecks != null) { |
+ _json["healthChecks"] = healthChecks; |
+ } |
+ if (iap != null) { |
+ _json["iap"] = (iap).toJson(); |
+ } |
+ if (id != null) { |
+ _json["id"] = id; |
+ } |
+ if (kind != null) { |
+ _json["kind"] = kind; |
+ } |
+ if (loadBalancingScheme != null) { |
+ _json["loadBalancingScheme"] = loadBalancingScheme; |
+ } |
+ if (name != null) { |
+ _json["name"] = name; |
+ } |
+ if (port != null) { |
+ _json["port"] = port; |
+ } |
+ if (portName != null) { |
+ _json["portName"] = portName; |
+ } |
+ if (protocol != null) { |
+ _json["protocol"] = protocol; |
+ } |
+ if (region != null) { |
+ _json["region"] = region; |
+ } |
+ if (selfLink != null) { |
+ _json["selfLink"] = selfLink; |
+ } |
+ if (sessionAffinity != null) { |
+ _json["sessionAffinity"] = sessionAffinity; |
+ } |
+ if (timeoutSec != null) { |
+ _json["timeoutSec"] = timeoutSec; |
+ } |
+ return _json; |
+ } |
+} |
+ |
+/** Contains a list of BackendServicesScopedList. */ |
+class BackendServiceAggregatedList { |
+ /** |
+ * [Output Only] Unique identifier for the resource; defined by the server. |
+ */ |
+ core.String id; |
+ /** A map of scoped BackendService lists. */ |
+ core.Map<core.String, BackendServicesScopedList> items; |
+ /** Type of resource. */ |
+ core.String kind; |
+ /** [Output Only] A token used to continue a truncated list request. */ |
+ core.String nextPageToken; |
+ /** [Output Only] Server-defined URL for this resource. */ |
+ core.String selfLink; |
+ |
+ BackendServiceAggregatedList(); |
+ |
+ BackendServiceAggregatedList.fromJson(core.Map _json) { |
+ if (_json.containsKey("id")) { |
+ id = _json["id"]; |
+ } |
+ if (_json.containsKey("items")) { |
+ items = commons.mapMap<core.Map<core.String, core.Object>, BackendServicesScopedList>(_json["items"], (core.Map<core.String, core.Object> item) => new BackendServicesScopedList.fromJson(item)); |
+ } |
+ if (_json.containsKey("kind")) { |
+ kind = _json["kind"]; |
+ } |
+ if (_json.containsKey("nextPageToken")) { |
+ nextPageToken = _json["nextPageToken"]; |
+ } |
+ if (_json.containsKey("selfLink")) { |
+ selfLink = _json["selfLink"]; |
+ } |
+ } |
+ |
+ core.Map<core.String, core.Object> toJson() { |
+ final core.Map<core.String, core.Object> _json = new core.Map<core.String, core.Object>(); |
+ if (id != null) { |
+ _json["id"] = id; |
+ } |
+ if (items != null) { |
+ _json["items"] = commons.mapMap<BackendServicesScopedList, core.Map<core.String, core.Object>>(items, (BackendServicesScopedList item) => (item).toJson()); |
+ } |
+ if (kind != null) { |
+ _json["kind"] = kind; |
+ } |
+ if (nextPageToken != null) { |
+ _json["nextPageToken"] = nextPageToken; |
+ } |
+ if (selfLink != null) { |
+ _json["selfLink"] = selfLink; |
+ } |
+ return _json; |
+ } |
+} |
+ |
+/** Message containing Cloud CDN configuration for a backend service. */ |
+class BackendServiceCdnPolicy { |
+ /** The CacheKeyPolicy for this CdnPolicy. */ |
+ CacheKeyPolicy cacheKeyPolicy; |
+ |
+ BackendServiceCdnPolicy(); |
+ |
+ BackendServiceCdnPolicy.fromJson(core.Map _json) { |
+ if (_json.containsKey("cacheKeyPolicy")) { |
+ cacheKeyPolicy = new CacheKeyPolicy.fromJson(_json["cacheKeyPolicy"]); |
+ } |
+ } |
+ |
+ core.Map<core.String, core.Object> toJson() { |
+ final core.Map<core.String, core.Object> _json = new core.Map<core.String, core.Object>(); |
+ if (cacheKeyPolicy != null) { |
+ _json["cacheKeyPolicy"] = (cacheKeyPolicy).toJson(); |
+ } |
+ return _json; |
+ } |
+} |
+ |
+class BackendServiceGroupHealth { |
+ core.List<HealthStatus> healthStatus; |
+ /** |
+ * [Output Only] Type of resource. Always compute#backendServiceGroupHealth |
+ * for the health of backend services. |
+ */ |
+ core.String kind; |
+ |
+ BackendServiceGroupHealth(); |
+ |
+ BackendServiceGroupHealth.fromJson(core.Map _json) { |
+ if (_json.containsKey("healthStatus")) { |
+ healthStatus = _json["healthStatus"].map((value) => new HealthStatus.fromJson(value)).toList(); |
+ } |
+ if (_json.containsKey("kind")) { |
+ kind = _json["kind"]; |
+ } |
+ } |
+ |
+ core.Map<core.String, core.Object> toJson() { |
+ final core.Map<core.String, core.Object> _json = new core.Map<core.String, core.Object>(); |
+ if (healthStatus != null) { |
+ _json["healthStatus"] = healthStatus.map((value) => (value).toJson()).toList(); |
+ } |
+ if (kind != null) { |
+ _json["kind"] = kind; |
+ } |
+ return _json; |
+ } |
+} |
+ |
+/** Identity-Aware Proxy */ |
+class BackendServiceIAP { |
+ core.bool enabled; |
+ core.String oauth2ClientId; |
+ core.String oauth2ClientSecret; |
+ /** |
+ * [Output Only] SHA256 hash value for the field oauth2_client_secret above. |
+ */ |
+ core.String oauth2ClientSecretSha256; |
+ |
+ BackendServiceIAP(); |
+ |
+ BackendServiceIAP.fromJson(core.Map _json) { |
+ if (_json.containsKey("enabled")) { |
+ enabled = _json["enabled"]; |
+ } |
+ if (_json.containsKey("oauth2ClientId")) { |
+ oauth2ClientId = _json["oauth2ClientId"]; |
+ } |
+ if (_json.containsKey("oauth2ClientSecret")) { |
+ oauth2ClientSecret = _json["oauth2ClientSecret"]; |
+ } |
+ if (_json.containsKey("oauth2ClientSecretSha256")) { |
+ oauth2ClientSecretSha256 = _json["oauth2ClientSecretSha256"]; |
+ } |
+ } |
+ |
+ core.Map<core.String, core.Object> toJson() { |
+ final core.Map<core.String, core.Object> _json = new core.Map<core.String, core.Object>(); |
+ if (enabled != null) { |
+ _json["enabled"] = enabled; |
+ } |
+ if (oauth2ClientId != null) { |
+ _json["oauth2ClientId"] = oauth2ClientId; |
+ } |
+ if (oauth2ClientSecret != null) { |
+ _json["oauth2ClientSecret"] = oauth2ClientSecret; |
+ } |
+ if (oauth2ClientSecretSha256 != null) { |
+ _json["oauth2ClientSecretSha256"] = oauth2ClientSecretSha256; |
+ } |
+ return _json; |
+ } |
+} |
+ |
+/** Contains a list of BackendService resources. */ |
+class BackendServiceList { |
+ /** |
+ * [Output Only] Unique identifier for the resource; defined by the server. |
+ */ |
+ core.String id; |
+ /** A list of BackendService resources. */ |
+ core.List<BackendService> items; |
+ /** |
+ * [Output Only] Type of resource. Always compute#backendServiceList for lists |
+ * of backend services. |
+ */ |
+ core.String kind; |
+ /** |
+ * [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. |
+ */ |
+ core.String nextPageToken; |
+ /** [Output Only] Server-defined URL for this resource. */ |
+ core.String selfLink; |
+ |
+ BackendServiceList(); |
+ |
+ BackendServiceList.fromJson(core.Map _json) { |
+ if (_json.containsKey("id")) { |
+ id = _json["id"]; |
+ } |
+ if (_json.containsKey("items")) { |
+ items = _json["items"].map((value) => new BackendService.fromJson(value)).toList(); |
+ } |
+ if (_json.containsKey("kind")) { |
+ kind = _json["kind"]; |
+ } |
+ if (_json.containsKey("nextPageToken")) { |
+ nextPageToken = _json["nextPageToken"]; |
+ } |
+ if (_json.containsKey("selfLink")) { |
+ selfLink = _json["selfLink"]; |
+ } |
+ } |
+ |
+ core.Map<core.String, core.Object> toJson() { |
+ final core.Map<core.String, core.Object> _json = new core.Map<core.String, core.Object>(); |
+ if (id != null) { |
+ _json["id"] = id; |
+ } |
+ if (items != null) { |
+ _json["items"] = items.map((value) => (value).toJson()).toList(); |
+ } |
+ if (kind != null) { |
+ _json["kind"] = kind; |
+ } |
+ if (nextPageToken != null) { |
+ _json["nextPageToken"] = nextPageToken; |
+ } |
+ if (selfLink != null) { |
+ _json["selfLink"] = selfLink; |
+ } |
+ return _json; |
+ } |
+} |
+ |
+class BackendServicesScopedListWarningData { |
+ /** |
+ * [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). |
+ */ |
+ core.String key; |
+ /** [Output Only] A warning data value corresponding to the key. */ |
+ core.String value; |
+ |
+ BackendServicesScopedListWarningData(); |
+ |
+ BackendServicesScopedListWarningData.fromJson(core.Map _json) { |
+ if (_json.containsKey("key")) { |
+ key = _json["key"]; |
+ } |
+ if (_json.containsKey("value")) { |
+ value = _json["value"]; |
+ } |
+ } |
+ |
+ core.Map<core.String, core.Object> toJson() { |
+ final core.Map<core.String, core.Object> _json = new core.Map<core.String, core.Object>(); |
+ if (key != null) { |
+ _json["key"] = key; |
+ } |
+ if (value != null) { |
+ _json["value"] = value; |
+ } |
+ return _json; |
+ } |
+} |
+ |
+/** |
+ * Informational warning which replaces the list of backend services when the |
+ * list is empty. |
+ */ |
+class BackendServicesScopedListWarning { |
+ /** |
+ * [Output Only] A warning code, if applicable. For example, Compute Engine |
+ * returns NO_RESULTS_ON_PAGE if there are no results in the response. |
+ * Possible string values are: |
+ * - "CLEANUP_FAILED" |
+ * - "DEPRECATED_RESOURCE_USED" |
+ * - "DISK_SIZE_LARGER_THAN_IMAGE_SIZE" |
+ * - "FIELD_VALUE_OVERRIDEN" |
+ * - "INJECTED_KERNELS_DEPRECATED" |
+ * - "NEXT_HOP_ADDRESS_NOT_ASSIGNED" |
+ * - "NEXT_HOP_CANNOT_IP_FORWARD" |
+ * - "NEXT_HOP_INSTANCE_NOT_FOUND" |
+ * - "NEXT_HOP_INSTANCE_NOT_ON_NETWORK" |
+ * - "NEXT_HOP_NOT_RUNNING" |
+ * - "NOT_CRITICAL_ERROR" |
+ * - "NO_RESULTS_ON_PAGE" |
+ * - "REQUIRED_TOS_AGREEMENT" |
+ * - "RESOURCE_IN_USE_BY_OTHER_RESOURCE_WARNING" |
+ * - "RESOURCE_NOT_DELETED" |
+ * - "SINGLE_INSTANCE_PROPERTY_TEMPLATE" |
+ * - "UNREACHABLE" |
+ */ |
+ core.String code; |
+ /** |
+ * [Output Only] Metadata about this warning in key: value format. For |
+ * example: |
+ * "data": [ { "key": "scope", "value": "zones/us-east1-d" } |
*/ |
- core.String name; |
- /** [Output Only] Server-defined URL for the resource. */ |
- core.String selfLink; |
+ core.List<BackendServicesScopedListWarningData> data; |
+ /** [Output Only] A human-readable description of the warning code. */ |
+ core.String message; |
- BackendBucket(); |
+ BackendServicesScopedListWarning(); |
- BackendBucket.fromJson(core.Map _json) { |
- if (_json.containsKey("bucketName")) { |
- bucketName = _json["bucketName"]; |
+ BackendServicesScopedListWarning.fromJson(core.Map _json) { |
+ if (_json.containsKey("code")) { |
+ code = _json["code"]; |
} |
- if (_json.containsKey("creationTimestamp")) { |
- creationTimestamp = _json["creationTimestamp"]; |
+ if (_json.containsKey("data")) { |
+ data = _json["data"].map((value) => new BackendServicesScopedListWarningData.fromJson(value)).toList(); |
} |
- if (_json.containsKey("description")) { |
- description = _json["description"]; |
+ if (_json.containsKey("message")) { |
+ message = _json["message"]; |
} |
- if (_json.containsKey("enableCdn")) { |
- enableCdn = _json["enableCdn"]; |
+ } |
+ |
+ core.Map<core.String, core.Object> toJson() { |
+ final core.Map<core.String, core.Object> _json = new core.Map<core.String, core.Object>(); |
+ if (code != null) { |
+ _json["code"] = code; |
} |
- if (_json.containsKey("id")) { |
- id = _json["id"]; |
+ if (data != null) { |
+ _json["data"] = data.map((value) => (value).toJson()).toList(); |
} |
- if (_json.containsKey("kind")) { |
- kind = _json["kind"]; |
+ if (message != null) { |
+ _json["message"] = message; |
} |
- if (_json.containsKey("name")) { |
- name = _json["name"]; |
+ return _json; |
+ } |
+} |
+ |
+class BackendServicesScopedList { |
+ /** List of BackendServices contained in this scope. */ |
+ core.List<BackendService> backendServices; |
+ /** |
+ * Informational warning which replaces the list of backend services when the |
+ * list is empty. |
+ */ |
+ BackendServicesScopedListWarning warning; |
+ |
+ BackendServicesScopedList(); |
+ |
+ BackendServicesScopedList.fromJson(core.Map _json) { |
+ if (_json.containsKey("backendServices")) { |
+ backendServices = _json["backendServices"].map((value) => new BackendService.fromJson(value)).toList(); |
} |
- if (_json.containsKey("selfLink")) { |
- selfLink = _json["selfLink"]; |
+ if (_json.containsKey("warning")) { |
+ warning = new BackendServicesScopedListWarning.fromJson(_json["warning"]); |
} |
} |
core.Map<core.String, core.Object> toJson() { |
final core.Map<core.String, core.Object> _json = new core.Map<core.String, core.Object>(); |
- if (bucketName != null) { |
- _json["bucketName"] = bucketName; |
- } |
- if (creationTimestamp != null) { |
- _json["creationTimestamp"] = creationTimestamp; |
- } |
- if (description != null) { |
- _json["description"] = description; |
+ if (backendServices != null) { |
+ _json["backendServices"] = backendServices.map((value) => (value).toJson()).toList(); |
} |
- if (enableCdn != null) { |
- _json["enableCdn"] = enableCdn; |
+ if (warning != null) { |
+ _json["warning"] = (warning).toJson(); |
} |
- if (id != null) { |
- _json["id"] = id; |
+ return _json; |
+ } |
+} |
+ |
+class CacheInvalidationRule { |
+ /** |
+ * If set, this invalidation rule will only apply to requests with a Host |
+ * header matching host. |
+ */ |
+ core.String host; |
+ core.String path; |
+ |
+ CacheInvalidationRule(); |
+ |
+ CacheInvalidationRule.fromJson(core.Map _json) { |
+ if (_json.containsKey("host")) { |
+ host = _json["host"]; |
} |
- if (kind != null) { |
- _json["kind"] = kind; |
+ if (_json.containsKey("path")) { |
+ path = _json["path"]; |
} |
- if (name != null) { |
- _json["name"] = name; |
+ } |
+ |
+ core.Map<core.String, core.Object> toJson() { |
+ final core.Map<core.String, core.Object> _json = new core.Map<core.String, core.Object>(); |
+ if (host != null) { |
+ _json["host"] = host; |
} |
- if (selfLink != null) { |
- _json["selfLink"] = selfLink; |
+ if (path != null) { |
+ _json["path"] = path; |
} |
return _json; |
} |
} |
-/** Contains a list of BackendBucket resources. */ |
-class BackendBucketList { |
+/** |
+ * Message containing what to include in the cache key for a request for Cloud |
+ * CDN. |
+ */ |
+class CacheKeyPolicy { |
+ /** If true, requests to different hosts will be cached separately. */ |
+ core.bool includeHost; |
+ /** If true, http and https requests will be cached separately. */ |
+ core.bool includeProtocol; |
/** |
- * [Output Only] Unique identifier for the resource; defined by the server. |
+ * 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. |
*/ |
- core.String id; |
- /** A list of BackendBucket resources. */ |
- core.List<BackendBucket> items; |
- /** Type of resource. */ |
- core.String kind; |
- /** [Output Only] A token used to continue a truncated list request. */ |
- core.String nextPageToken; |
- /** [Output Only] Server-defined URL for this resource. */ |
- core.String selfLink; |
+ core.bool includeQueryString; |
+ /** |
+ * 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. '&' and '=' will be percent encoded and |
+ * not treated as delimiters. |
+ */ |
+ core.List<core.String> queryStringBlacklist; |
+ /** |
+ * 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. '&' and '=' will be percent encoded and |
+ * not treated as delimiters. |
+ */ |
+ core.List<core.String> queryStringWhitelist; |
- BackendBucketList(); |
+ CacheKeyPolicy(); |
- BackendBucketList.fromJson(core.Map _json) { |
- if (_json.containsKey("id")) { |
- id = _json["id"]; |
+ CacheKeyPolicy.fromJson(core.Map _json) { |
+ if (_json.containsKey("includeHost")) { |
+ includeHost = _json["includeHost"]; |
} |
- if (_json.containsKey("items")) { |
- items = _json["items"].map((value) => new BackendBucket.fromJson(value)).toList(); |
+ if (_json.containsKey("includeProtocol")) { |
+ includeProtocol = _json["includeProtocol"]; |
} |
- if (_json.containsKey("kind")) { |
- kind = _json["kind"]; |
+ if (_json.containsKey("includeQueryString")) { |
+ includeQueryString = _json["includeQueryString"]; |
} |
- if (_json.containsKey("nextPageToken")) { |
- nextPageToken = _json["nextPageToken"]; |
+ if (_json.containsKey("queryStringBlacklist")) { |
+ queryStringBlacklist = _json["queryStringBlacklist"]; |
} |
- if (_json.containsKey("selfLink")) { |
- selfLink = _json["selfLink"]; |
+ if (_json.containsKey("queryStringWhitelist")) { |
+ queryStringWhitelist = _json["queryStringWhitelist"]; |
} |
} |
core.Map<core.String, core.Object> toJson() { |
final core.Map<core.String, core.Object> _json = new core.Map<core.String, core.Object>(); |
- if (id != null) { |
- _json["id"] = id; |
+ if (includeHost != null) { |
+ _json["includeHost"] = includeHost; |
} |
- if (items != null) { |
- _json["items"] = items.map((value) => (value).toJson()).toList(); |
+ if (includeProtocol != null) { |
+ _json["includeProtocol"] = includeProtocol; |
} |
- if (kind != null) { |
- _json["kind"] = kind; |
+ if (includeQueryString != null) { |
+ _json["includeQueryString"] = includeQueryString; |
} |
- if (nextPageToken != null) { |
- _json["nextPageToken"] = nextPageToken; |
+ if (queryStringBlacklist != null) { |
+ _json["queryStringBlacklist"] = queryStringBlacklist; |
} |
- if (selfLink != null) { |
- _json["selfLink"] = selfLink; |
+ if (queryStringWhitelist != null) { |
+ _json["queryStringWhitelist"] = queryStringWhitelist; |
} |
return _json; |
} |
} |
/** |
- * A BackendService resource. This resource defines a group of backend virtual |
- * machines and their serving capacity. |
+ * Represents a Commitment resource. Creating a Commitment resource means that |
+ * you are purchasing a committed use contract with an explicit start and end |
+ * time. You can create commitments based on vCPUs and memory usage and receive |
+ * discounted rates. For full details, read Signing Up for Committed Use |
+ * Discounts. |
+ * |
+ * Committed use discounts are subject to Google Cloud Platform's Service |
+ * Specific Terms. By purchasing a committed use discount, you agree to these |
+ * terms. Committed use discounts will not renew, so you must purchase a new |
+ * commitment to continue receiving discounts. |
*/ |
-class BackendService { |
- /** |
- * Lifetime of cookies in seconds if session_affinity is GENERATED_COOKIE. 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 for TTL is one |
- * day. |
- * |
- * When the load balancing scheme is INTERNAL, this field is not used. |
- */ |
- core.int affinityCookieTtlSec; |
- /** The list of backends that serve this BackendService. */ |
- core.List<Backend> backends; |
- /** Cloud CDN configuration for this BackendService. */ |
- BackendServiceCdnPolicy cdnPolicy; |
- ConnectionDraining connectionDraining; |
+class Commitment { |
/** [Output Only] Creation timestamp in RFC3339 text format. */ |
core.String creationTimestamp; |
/** |
@@ -20155,54 +22018,18 @@ class BackendService { |
* create the resource. |
*/ |
core.String description; |
- /** |
- * If true, enable Cloud CDN for this BackendService. |
- * |
- * When the load balancing scheme is INTERNAL, this field is not used. |
- */ |
- core.bool enableCDN; |
- /** |
- * 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. |
- */ |
- core.String fingerprint; |
- core.List<core.int> get fingerprintAsBytes { |
- return convert.BASE64.decode(fingerprint); |
- } |
- |
- void set fingerprintAsBytes(core.List<core.int> _bytes) { |
- fingerprint = convert.BASE64.encode(_bytes).replaceAll("/", "_").replaceAll("+", "-"); |
- } |
- /** |
- * The list of URLs to the HttpHealthCheck or HttpsHealthCheck resource for |
- * health checking this BackendService. Currently at most one health check can |
- * be specified, and a health check is required. |
- * |
- * For internal load balancing, a URL to a HealthCheck resource must be |
- * specified instead. |
- */ |
- core.List<core.String> healthChecks; |
- BackendServiceIAP iap; |
+ /** [Output Only] Commitment end time in RFC3339 text format. */ |
+ core.String endTimestamp; |
/** |
* [Output Only] The unique identifier for the resource. This identifier is |
- * defined by the server. |
- */ |
- core.String id; |
- /** |
- * [Output Only] Type of resource. Always compute#backendService for backend |
- * services. |
- */ |
- core.String kind; |
- /** |
- * |
- * Possible string values are: |
- * - "EXTERNAL" |
- * - "INTERNAL" |
- * - "INVALID_LOAD_BALANCING_SCHEME" |
+ * defined by the server. |
*/ |
- core.String loadBalancingScheme; |
+ core.String id; |
+ /** |
+ * [Output Only] Type of the resource. Always compute#commitment for |
+ * commitments. |
+ */ |
+ core.String kind; |
/** |
* 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. |
@@ -20214,98 +22041,51 @@ class BackendService { |
*/ |
core.String name; |
/** |
- * Deprecated in favor of portName. The TCP port to connect on the backend. |
- * The default value is 80. |
- * |
- * This cannot be used for internal load balancing. |
- */ |
- core.int port; |
- /** |
- * Name of backend port. The same name should appear in the instance groups |
- * referenced by this service. Required when the load balancing scheme is |
- * EXTERNAL. |
- * |
- * When the load balancing scheme is INTERNAL, this field is not used. |
- */ |
- core.String portName; |
- /** |
- * The protocol this BackendService uses to communicate with backends. |
- * |
- * Possible values are HTTP, HTTPS, TCP, and SSL. The default is HTTP. |
- * |
- * For internal load balancing, the possible values are TCP and UDP, and the |
- * default is TCP. |
+ * The plan for this commitment, which determines duration and discount rate. |
+ * The currently supported plans are TWELVE_MONTH (1 year), and |
+ * THIRTY_SIX_MONTH (3 years). |
* Possible string values are: |
- * - "HTTP" |
- * - "HTTPS" |
- * - "SSL" |
- * - "TCP" |
- * - "UDP" |
+ * - "INVALID" |
+ * - "THIRTY_SIX_MONTH" |
+ * - "TWELVE_MONTH" |
*/ |
- core.String protocol; |
+ core.String plan; |
+ /** [Output Only] URL of the region where this commitment may be used. */ |
+ core.String region; |
/** |
- * [Output Only] URL of the region where the regional backend service resides. |
- * This field is not applicable to global backend services. |
+ * List of commitment amounts for particular resources. Note that VCPU and |
+ * MEMORY resource commitments must occur together. |
*/ |
- core.String region; |
+ core.List<ResourceCommitment> resources; |
/** [Output Only] Server-defined URL for the resource. */ |
core.String selfLink; |
+ /** [Output Only] Commitment start time in RFC3339 text format. */ |
+ core.String startTimestamp; |
/** |
- * Type of session affinity to use. The default is NONE. |
- * |
- * When the load balancing scheme is EXTERNAL, can be NONE, CLIENT_IP, or |
- * GENERATED_COOKIE. |
- * |
- * When the load balancing scheme is INTERNAL, can be NONE, CLIENT_IP, |
- * CLIENT_IP_PROTO, or CLIENT_IP_PORT_PROTO. |
- * |
- * When the protocol is UDP, this field is not used. |
+ * [Output Only] Status of the commitment with regards to eventual expiration |
+ * (each commitment has an end date defined). One of the following values: |
+ * NOT_YET_ACTIVE, ACTIVE, EXPIRED. |
* Possible string values are: |
- * - "CLIENT_IP" |
- * - "CLIENT_IP_PORT_PROTO" |
- * - "CLIENT_IP_PROTO" |
- * - "GENERATED_COOKIE" |
- * - "NONE" |
- */ |
- core.String sessionAffinity; |
- /** |
- * How many seconds to wait for the backend before considering it a failed |
- * request. Default is 30 seconds. |
+ * - "ACTIVE" |
+ * - "CREATING" |
+ * - "EXPIRED" |
+ * - "NOT_YET_ACTIVE" |
*/ |
- core.int timeoutSec; |
+ core.String status; |
+ /** [Output Only] An optional, human-readable explanation of the status. */ |
+ core.String statusMessage; |
- BackendService(); |
+ Commitment(); |
- BackendService.fromJson(core.Map _json) { |
- if (_json.containsKey("affinityCookieTtlSec")) { |
- affinityCookieTtlSec = _json["affinityCookieTtlSec"]; |
- } |
- if (_json.containsKey("backends")) { |
- backends = _json["backends"].map((value) => new Backend.fromJson(value)).toList(); |
- } |
- if (_json.containsKey("cdnPolicy")) { |
- cdnPolicy = new BackendServiceCdnPolicy.fromJson(_json["cdnPolicy"]); |
- } |
- if (_json.containsKey("connectionDraining")) { |
- connectionDraining = new ConnectionDraining.fromJson(_json["connectionDraining"]); |
- } |
+ Commitment.fromJson(core.Map _json) { |
if (_json.containsKey("creationTimestamp")) { |
creationTimestamp = _json["creationTimestamp"]; |
} |
if (_json.containsKey("description")) { |
description = _json["description"]; |
} |
- if (_json.containsKey("enableCDN")) { |
- enableCDN = _json["enableCDN"]; |
- } |
- if (_json.containsKey("fingerprint")) { |
- fingerprint = _json["fingerprint"]; |
- } |
- if (_json.containsKey("healthChecks")) { |
- healthChecks = _json["healthChecks"]; |
- } |
- if (_json.containsKey("iap")) { |
- iap = new BackendServiceIAP.fromJson(_json["iap"]); |
+ if (_json.containsKey("endTimestamp")) { |
+ endTimestamp = _json["endTimestamp"]; |
} |
if (_json.containsKey("id")) { |
id = _json["id"]; |
@@ -20313,66 +22093,42 @@ class BackendService { |
if (_json.containsKey("kind")) { |
kind = _json["kind"]; |
} |
- if (_json.containsKey("loadBalancingScheme")) { |
- loadBalancingScheme = _json["loadBalancingScheme"]; |
- } |
if (_json.containsKey("name")) { |
name = _json["name"]; |
} |
- if (_json.containsKey("port")) { |
- port = _json["port"]; |
- } |
- if (_json.containsKey("portName")) { |
- portName = _json["portName"]; |
- } |
- if (_json.containsKey("protocol")) { |
- protocol = _json["protocol"]; |
+ if (_json.containsKey("plan")) { |
+ plan = _json["plan"]; |
} |
if (_json.containsKey("region")) { |
region = _json["region"]; |
} |
+ if (_json.containsKey("resources")) { |
+ resources = _json["resources"].map((value) => new ResourceCommitment.fromJson(value)).toList(); |
+ } |
if (_json.containsKey("selfLink")) { |
selfLink = _json["selfLink"]; |
} |
- if (_json.containsKey("sessionAffinity")) { |
- sessionAffinity = _json["sessionAffinity"]; |
+ if (_json.containsKey("startTimestamp")) { |
+ startTimestamp = _json["startTimestamp"]; |
} |
- if (_json.containsKey("timeoutSec")) { |
- timeoutSec = _json["timeoutSec"]; |
+ if (_json.containsKey("status")) { |
+ status = _json["status"]; |
+ } |
+ if (_json.containsKey("statusMessage")) { |
+ statusMessage = _json["statusMessage"]; |
} |
} |
core.Map<core.String, core.Object> toJson() { |
final core.Map<core.String, core.Object> _json = new core.Map<core.String, core.Object>(); |
- if (affinityCookieTtlSec != null) { |
- _json["affinityCookieTtlSec"] = affinityCookieTtlSec; |
- } |
- if (backends != null) { |
- _json["backends"] = backends.map((value) => (value).toJson()).toList(); |
- } |
- if (cdnPolicy != null) { |
- _json["cdnPolicy"] = (cdnPolicy).toJson(); |
- } |
- if (connectionDraining != null) { |
- _json["connectionDraining"] = (connectionDraining).toJson(); |
- } |
if (creationTimestamp != null) { |
_json["creationTimestamp"] = creationTimestamp; |
} |
if (description != null) { |
_json["description"] = description; |
} |
- if (enableCDN != null) { |
- _json["enableCDN"] = enableCDN; |
- } |
- if (fingerprint != null) { |
- _json["fingerprint"] = fingerprint; |
- } |
- if (healthChecks != null) { |
- _json["healthChecks"] = healthChecks; |
- } |
- if (iap != null) { |
- _json["iap"] = (iap).toJson(); |
+ if (endTimestamp != null) { |
+ _json["endTimestamp"] = endTimestamp; |
} |
if (id != null) { |
_json["id"] = id; |
@@ -20380,202 +22136,111 @@ class BackendService { |
if (kind != null) { |
_json["kind"] = kind; |
} |
- if (loadBalancingScheme != null) { |
- _json["loadBalancingScheme"] = loadBalancingScheme; |
- } |
if (name != null) { |
_json["name"] = name; |
} |
- if (port != null) { |
- _json["port"] = port; |
- } |
- if (portName != null) { |
- _json["portName"] = portName; |
- } |
- if (protocol != null) { |
- _json["protocol"] = protocol; |
+ if (plan != null) { |
+ _json["plan"] = plan; |
} |
if (region != null) { |
_json["region"] = region; |
} |
- if (selfLink != null) { |
- _json["selfLink"] = selfLink; |
- } |
- if (sessionAffinity != null) { |
- _json["sessionAffinity"] = sessionAffinity; |
- } |
- if (timeoutSec != null) { |
- _json["timeoutSec"] = timeoutSec; |
- } |
- return _json; |
- } |
-} |
- |
-/** Contains a list of BackendServicesScopedList. */ |
-class BackendServiceAggregatedList { |
- /** |
- * [Output Only] Unique identifier for the resource; defined by the server. |
- */ |
- core.String id; |
- /** A map of scoped BackendService lists. */ |
- core.Map<core.String, BackendServicesScopedList> items; |
- /** Type of resource. */ |
- core.String kind; |
- /** [Output Only] A token used to continue a truncated list request. */ |
- core.String nextPageToken; |
- /** [Output Only] Server-defined URL for this resource. */ |
- core.String selfLink; |
- |
- BackendServiceAggregatedList(); |
- |
- BackendServiceAggregatedList.fromJson(core.Map _json) { |
- if (_json.containsKey("id")) { |
- id = _json["id"]; |
- } |
- if (_json.containsKey("items")) { |
- items = commons.mapMap<core.Map<core.String, core.Object>, BackendServicesScopedList>(_json["items"], (core.Map<core.String, core.Object> item) => new BackendServicesScopedList.fromJson(item)); |
- } |
- if (_json.containsKey("kind")) { |
- kind = _json["kind"]; |
- } |
- if (_json.containsKey("nextPageToken")) { |
- nextPageToken = _json["nextPageToken"]; |
- } |
- if (_json.containsKey("selfLink")) { |
- selfLink = _json["selfLink"]; |
- } |
- } |
- |
- core.Map<core.String, core.Object> toJson() { |
- final core.Map<core.String, core.Object> _json = new core.Map<core.String, core.Object>(); |
- if (id != null) { |
- _json["id"] = id; |
- } |
- if (items != null) { |
- _json["items"] = commons.mapMap<BackendServicesScopedList, core.Map<core.String, core.Object>>(items, (BackendServicesScopedList item) => (item).toJson()); |
- } |
- if (kind != null) { |
- _json["kind"] = kind; |
- } |
- if (nextPageToken != null) { |
- _json["nextPageToken"] = nextPageToken; |
+ if (resources != null) { |
+ _json["resources"] = resources.map((value) => (value).toJson()).toList(); |
} |
if (selfLink != null) { |
_json["selfLink"] = selfLink; |
} |
- return _json; |
- } |
-} |
- |
-/** Message containing Cloud CDN configuration for a backend service. */ |
-class BackendServiceCdnPolicy { |
- /** The CacheKeyPolicy for this CdnPolicy. */ |
- CacheKeyPolicy cacheKeyPolicy; |
- |
- BackendServiceCdnPolicy(); |
- |
- BackendServiceCdnPolicy.fromJson(core.Map _json) { |
- if (_json.containsKey("cacheKeyPolicy")) { |
- cacheKeyPolicy = new CacheKeyPolicy.fromJson(_json["cacheKeyPolicy"]); |
- } |
- } |
- |
- core.Map<core.String, core.Object> toJson() { |
- final core.Map<core.String, core.Object> _json = new core.Map<core.String, core.Object>(); |
- if (cacheKeyPolicy != null) { |
- _json["cacheKeyPolicy"] = (cacheKeyPolicy).toJson(); |
- } |
- return _json; |
- } |
-} |
- |
-class BackendServiceGroupHealth { |
- core.List<HealthStatus> healthStatus; |
- /** |
- * [Output Only] Type of resource. Always compute#backendServiceGroupHealth |
- * for the health of backend services. |
- */ |
- core.String kind; |
- |
- BackendServiceGroupHealth(); |
- |
- BackendServiceGroupHealth.fromJson(core.Map _json) { |
- if (_json.containsKey("healthStatus")) { |
- healthStatus = _json["healthStatus"].map((value) => new HealthStatus.fromJson(value)).toList(); |
- } |
- if (_json.containsKey("kind")) { |
- kind = _json["kind"]; |
- } |
- } |
- |
- core.Map<core.String, core.Object> toJson() { |
- final core.Map<core.String, core.Object> _json = new core.Map<core.String, core.Object>(); |
- if (healthStatus != null) { |
- _json["healthStatus"] = healthStatus.map((value) => (value).toJson()).toList(); |
+ if (startTimestamp != null) { |
+ _json["startTimestamp"] = startTimestamp; |
} |
- if (kind != null) { |
- _json["kind"] = kind; |
+ if (status != null) { |
+ _json["status"] = status; |
+ } |
+ if (statusMessage != null) { |
+ _json["statusMessage"] = statusMessage; |
} |
return _json; |
} |
} |
-/** Identity-Aware Proxy */ |
-class BackendServiceIAP { |
- core.bool enabled; |
- core.String oauth2ClientId; |
- core.String oauth2ClientSecret; |
+class CommitmentAggregatedList { |
/** |
- * [Output Only] SHA256 hash value for the field oauth2_client_secret above. |
+ * [Output Only] The unique identifier for the resource. This identifier is |
+ * defined by the server. |
*/ |
- core.String oauth2ClientSecretSha256; |
+ core.String id; |
+ /** Commitments by scope. */ |
+ core.Map<core.String, CommitmentsScopedList> items; |
+ /** |
+ * [Output Only] Type of resource. Always compute#commitmentAggregatedList for |
+ * aggregated lists of commitments. |
+ */ |
+ core.String kind; |
+ /** |
+ * [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. |
+ */ |
+ core.String nextPageToken; |
+ /** [Output Only] Server-defined URL for this resource. */ |
+ core.String selfLink; |
- BackendServiceIAP(); |
+ CommitmentAggregatedList(); |
- BackendServiceIAP.fromJson(core.Map _json) { |
- if (_json.containsKey("enabled")) { |
- enabled = _json["enabled"]; |
+ CommitmentAggregatedList.fromJson(core.Map _json) { |
+ if (_json.containsKey("id")) { |
+ id = _json["id"]; |
} |
- if (_json.containsKey("oauth2ClientId")) { |
- oauth2ClientId = _json["oauth2ClientId"]; |
+ if (_json.containsKey("items")) { |
+ items = commons.mapMap<core.Map<core.String, core.Object>, CommitmentsScopedList>(_json["items"], (core.Map<core.String, core.Object> item) => new CommitmentsScopedList.fromJson(item)); |
} |
- if (_json.containsKey("oauth2ClientSecret")) { |
- oauth2ClientSecret = _json["oauth2ClientSecret"]; |
+ if (_json.containsKey("kind")) { |
+ kind = _json["kind"]; |
} |
- if (_json.containsKey("oauth2ClientSecretSha256")) { |
- oauth2ClientSecretSha256 = _json["oauth2ClientSecretSha256"]; |
+ if (_json.containsKey("nextPageToken")) { |
+ nextPageToken = _json["nextPageToken"]; |
+ } |
+ if (_json.containsKey("selfLink")) { |
+ selfLink = _json["selfLink"]; |
} |
} |
core.Map<core.String, core.Object> toJson() { |
final core.Map<core.String, core.Object> _json = new core.Map<core.String, core.Object>(); |
- if (enabled != null) { |
- _json["enabled"] = enabled; |
+ if (id != null) { |
+ _json["id"] = id; |
} |
- if (oauth2ClientId != null) { |
- _json["oauth2ClientId"] = oauth2ClientId; |
+ if (items != null) { |
+ _json["items"] = commons.mapMap<CommitmentsScopedList, core.Map<core.String, core.Object>>(items, (CommitmentsScopedList item) => (item).toJson()); |
} |
- if (oauth2ClientSecret != null) { |
- _json["oauth2ClientSecret"] = oauth2ClientSecret; |
+ if (kind != null) { |
+ _json["kind"] = kind; |
} |
- if (oauth2ClientSecretSha256 != null) { |
- _json["oauth2ClientSecretSha256"] = oauth2ClientSecretSha256; |
+ if (nextPageToken != null) { |
+ _json["nextPageToken"] = nextPageToken; |
+ } |
+ if (selfLink != null) { |
+ _json["selfLink"] = selfLink; |
} |
return _json; |
} |
} |
-/** Contains a list of BackendService resources. */ |
-class BackendServiceList { |
+/** Contains a list of Commitment resources. */ |
+class CommitmentList { |
/** |
- * [Output Only] Unique identifier for the resource; defined by the server. |
+ * [Output Only] The unique identifier for the resource. This identifier is |
+ * defined by the server. |
*/ |
core.String id; |
- /** A list of BackendService resources. */ |
- core.List<BackendService> items; |
+ /** A list of Commitment resources. */ |
+ core.List<Commitment> items; |
/** |
- * [Output Only] Type of resource. Always compute#backendServiceList for lists |
- * of backend services. |
+ * [Output Only] Type of resource. Always compute#commitmentList for lists of |
+ * commitments. |
*/ |
core.String kind; |
/** |
@@ -20589,14 +22254,14 @@ class BackendServiceList { |
/** [Output Only] Server-defined URL for this resource. */ |
core.String selfLink; |
- BackendServiceList(); |
+ CommitmentList(); |
- BackendServiceList.fromJson(core.Map _json) { |
+ CommitmentList.fromJson(core.Map _json) { |
if (_json.containsKey("id")) { |
id = _json["id"]; |
} |
if (_json.containsKey("items")) { |
- items = _json["items"].map((value) => new BackendService.fromJson(value)).toList(); |
+ items = _json["items"].map((value) => new Commitment.fromJson(value)).toList(); |
} |
if (_json.containsKey("kind")) { |
kind = _json["kind"]; |
@@ -20630,7 +22295,7 @@ class BackendServiceList { |
} |
} |
-class BackendServicesScopedListWarningData { |
+class CommitmentsScopedListWarningData { |
/** |
* [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 |
@@ -20644,9 +22309,9 @@ class BackendServicesScopedListWarningData { |
/** [Output Only] A warning data value corresponding to the key. */ |
core.String value; |
- BackendServicesScopedListWarningData(); |
+ CommitmentsScopedListWarningData(); |
- BackendServicesScopedListWarningData.fromJson(core.Map _json) { |
+ CommitmentsScopedListWarningData.fromJson(core.Map _json) { |
if (_json.containsKey("key")) { |
key = _json["key"]; |
} |
@@ -20668,10 +22333,10 @@ class BackendServicesScopedListWarningData { |
} |
/** |
- * Informational warning which replaces the list of backend services when the |
- * list is empty. |
+ * [Output Only] Informational warning which replaces the list of commitments |
+ * when the list is empty. |
*/ |
-class BackendServicesScopedListWarning { |
+class CommitmentsScopedListWarning { |
/** |
* [Output Only] A warning code, if applicable. For example, Compute Engine |
* returns NO_RESULTS_ON_PAGE if there are no results in the response. |
@@ -20700,18 +22365,18 @@ class BackendServicesScopedListWarning { |
* example: |
* "data": [ { "key": "scope", "value": "zones/us-east1-d" } |
*/ |
- core.List<BackendServicesScopedListWarningData> data; |
+ core.List<CommitmentsScopedListWarningData> data; |
/** [Output Only] A human-readable description of the warning code. */ |
core.String message; |
- BackendServicesScopedListWarning(); |
+ CommitmentsScopedListWarning(); |
- BackendServicesScopedListWarning.fromJson(core.Map _json) { |
+ CommitmentsScopedListWarning.fromJson(core.Map _json) { |
if (_json.containsKey("code")) { |
code = _json["code"]; |
} |
if (_json.containsKey("data")) { |
- data = _json["data"].map((value) => new BackendServicesScopedListWarningData.fromJson(value)).toList(); |
+ data = _json["data"].map((value) => new CommitmentsScopedListWarningData.fromJson(value)).toList(); |
} |
if (_json.containsKey("message")) { |
message = _json["message"]; |
@@ -20733,30 +22398,30 @@ class BackendServicesScopedListWarning { |
} |
} |
-class BackendServicesScopedList { |
- /** List of BackendServices contained in this scope. */ |
- core.List<BackendService> backendServices; |
+class CommitmentsScopedList { |
+ /** [Output Only] List of commitments contained in this scope. */ |
+ core.List<Commitment> commitments; |
/** |
- * Informational warning which replaces the list of backend services when the |
- * list is empty. |
+ * [Output Only] Informational warning which replaces the list of commitments |
+ * when the list is empty. |
*/ |
- BackendServicesScopedListWarning warning; |
+ CommitmentsScopedListWarning warning; |
- BackendServicesScopedList(); |
+ CommitmentsScopedList(); |
- BackendServicesScopedList.fromJson(core.Map _json) { |
- if (_json.containsKey("backendServices")) { |
- backendServices = _json["backendServices"].map((value) => new BackendService.fromJson(value)).toList(); |
+ CommitmentsScopedList.fromJson(core.Map _json) { |
+ if (_json.containsKey("commitments")) { |
+ commitments = _json["commitments"].map((value) => new Commitment.fromJson(value)).toList(); |
} |
if (_json.containsKey("warning")) { |
- warning = new BackendServicesScopedListWarning.fromJson(_json["warning"]); |
+ warning = new CommitmentsScopedListWarning.fromJson(_json["warning"]); |
} |
} |
core.Map<core.String, core.Object> toJson() { |
final core.Map<core.String, core.Object> _json = new core.Map<core.String, core.Object>(); |
- if (backendServices != null) { |
- _json["backendServices"] = backendServices.map((value) => (value).toJson()).toList(); |
+ if (commitments != null) { |
+ _json["commitments"] = commitments.map((value) => (value).toJson()).toList(); |
} |
if (warning != null) { |
_json["warning"] = (warning).toJson(); |
@@ -20765,109 +22430,6 @@ class BackendServicesScopedList { |
} |
} |
-class CacheInvalidationRule { |
- /** |
- * If set, this invalidation rule will only apply to requests with a Host |
- * header matching host. |
- */ |
- core.String host; |
- core.String path; |
- |
- CacheInvalidationRule(); |
- |
- CacheInvalidationRule.fromJson(core.Map _json) { |
- if (_json.containsKey("host")) { |
- host = _json["host"]; |
- } |
- if (_json.containsKey("path")) { |
- path = _json["path"]; |
- } |
- } |
- |
- core.Map<core.String, core.Object> toJson() { |
- final core.Map<core.String, core.Object> _json = new core.Map<core.String, core.Object>(); |
- if (host != null) { |
- _json["host"] = host; |
- } |
- if (path != null) { |
- _json["path"] = path; |
- } |
- return _json; |
- } |
-} |
- |
-/** |
- * Message containing what to include in the cache key for a request for Cloud |
- * CDN. |
- */ |
-class CacheKeyPolicy { |
- /** If true, requests to different hosts will be cached separately. */ |
- core.bool includeHost; |
- /** If true, http and https requests will be cached separately. */ |
- core.bool includeProtocol; |
- /** |
- * 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. |
- */ |
- core.bool includeQueryString; |
- /** |
- * 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. '&' and '=' will be percent encoded and |
- * not treated as delimiters. |
- */ |
- core.List<core.String> queryStringBlacklist; |
- /** |
- * 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. '&' and '=' will be percent encoded and |
- * not treated as delimiters. |
- */ |
- core.List<core.String> queryStringWhitelist; |
- |
- CacheKeyPolicy(); |
- |
- CacheKeyPolicy.fromJson(core.Map _json) { |
- if (_json.containsKey("includeHost")) { |
- includeHost = _json["includeHost"]; |
- } |
- if (_json.containsKey("includeProtocol")) { |
- includeProtocol = _json["includeProtocol"]; |
- } |
- if (_json.containsKey("includeQueryString")) { |
- includeQueryString = _json["includeQueryString"]; |
- } |
- if (_json.containsKey("queryStringBlacklist")) { |
- queryStringBlacklist = _json["queryStringBlacklist"]; |
- } |
- if (_json.containsKey("queryStringWhitelist")) { |
- queryStringWhitelist = _json["queryStringWhitelist"]; |
- } |
- } |
- |
- core.Map<core.String, core.Object> toJson() { |
- final core.Map<core.String, core.Object> _json = new core.Map<core.String, core.Object>(); |
- if (includeHost != null) { |
- _json["includeHost"] = includeHost; |
- } |
- if (includeProtocol != null) { |
- _json["includeProtocol"] = includeProtocol; |
- } |
- if (includeQueryString != null) { |
- _json["includeQueryString"] = includeQueryString; |
- } |
- if (queryStringBlacklist != null) { |
- _json["queryStringBlacklist"] = queryStringBlacklist; |
- } |
- if (queryStringWhitelist != null) { |
- _json["queryStringWhitelist"] = queryStringWhitelist; |
- } |
- return _json; |
- } |
-} |
- |
/** Message containing connection draining configuration. */ |
class ConnectionDraining { |
/** |
@@ -22906,7 +24468,7 @@ class GlobalSetLabelsRequest { |
/** Guest OS features. */ |
class GuestOsFeature { |
/** |
- * The type of supported feature. Currenty only VIRTIO_SCSI_MULTIQUEUE is |
+ * The type of supported feature. Currently only VIRTIO_SCSI_MULTIQUEUE is |
* supported. For newer Windows images, the server might also populate this |
* property with the value WINDOWS to indicate that this is a Windows image. |
* This value is purely informational and does not enable or disable any |
@@ -24293,6 +25855,10 @@ class Instance { |
* created before you can assign them. |
*/ |
core.List<AttachedDisk> disks; |
+ /** |
+ * List of the type and count of accelerator cards attached to the instance. |
+ */ |
+ core.List<AcceleratorConfig> guestAccelerators; |
/** |
* [Output Only] The unique identifier for the resource. This identifier is |
* defined by the server. |
@@ -24430,6 +25996,9 @@ class Instance { |
if (_json.containsKey("disks")) { |
disks = _json["disks"].map((value) => new AttachedDisk.fromJson(value)).toList(); |
} |
+ if (_json.containsKey("guestAccelerators")) { |
+ guestAccelerators = _json["guestAccelerators"].map((value) => new AcceleratorConfig.fromJson(value)).toList(); |
+ } |
if (_json.containsKey("id")) { |
id = _json["id"]; |
} |
@@ -24497,6 +26066,9 @@ class Instance { |
if (disks != null) { |
_json["disks"] = disks.map((value) => (value).toJson()).toList(); |
} |
+ if (guestAccelerators != null) { |
+ _json["guestAccelerators"] = guestAccelerators.map((value) => (value).toJson()).toList(); |
+ } |
if (id != null) { |
_json["id"] = id; |
} |
@@ -26117,6 +27689,11 @@ class InstanceProperties { |
* from this template. |
*/ |
core.List<AttachedDisk> disks; |
+ /** |
+ * A list of guest accelerator cards' type and count to use for instances |
+ * created from the instance template. |
+ */ |
+ core.List<AcceleratorConfig> guestAccelerators; |
/** Labels to apply to instances that are created from this template. */ |
core.Map<core.String, core.String> labels; |
/** |
@@ -26163,6 +27740,9 @@ class InstanceProperties { |
if (_json.containsKey("disks")) { |
disks = _json["disks"].map((value) => new AttachedDisk.fromJson(value)).toList(); |
} |
+ if (_json.containsKey("guestAccelerators")) { |
+ guestAccelerators = _json["guestAccelerators"].map((value) => new AcceleratorConfig.fromJson(value)).toList(); |
+ } |
if (_json.containsKey("labels")) { |
labels = _json["labels"]; |
} |
@@ -26197,6 +27777,9 @@ class InstanceProperties { |
if (disks != null) { |
_json["disks"] = disks.map((value) => (value).toJson()).toList(); |
} |
+ if (guestAccelerators != null) { |
+ _json["guestAccelerators"] = guestAccelerators.map((value) => (value).toJson()).toList(); |
+ } |
if (labels != null) { |
_json["labels"] = labels; |
} |
@@ -26627,6 +28210,29 @@ class InstancesSetLabelsRequest { |
} |
} |
+class InstancesSetMachineResourcesRequest { |
+ /** |
+ * List of the type and count of accelerator cards attached to the instance. |
+ */ |
+ core.List<AcceleratorConfig> guestAccelerators; |
+ |
+ InstancesSetMachineResourcesRequest(); |
+ |
+ InstancesSetMachineResourcesRequest.fromJson(core.Map _json) { |
+ if (_json.containsKey("guestAccelerators")) { |
+ guestAccelerators = _json["guestAccelerators"].map((value) => new AcceleratorConfig.fromJson(value)).toList(); |
+ } |
+ } |
+ |
+ core.Map<core.String, core.Object> toJson() { |
+ final core.Map<core.String, core.Object> _json = new core.Map<core.String, core.Object>(); |
+ if (guestAccelerators != null) { |
+ _json["guestAccelerators"] = guestAccelerators.map((value) => (value).toJson()).toList(); |
+ } |
+ return _json; |
+ } |
+} |
+ |
class InstancesSetMachineTypeRequest { |
/** |
* Full or partial URL of the machine type resource. See Machine Types for a |
@@ -29037,6 +30643,7 @@ class Quota { |
* - "AUTOSCALERS" |
* - "BACKEND_BUCKETS" |
* - "BACKEND_SERVICES" |
+ * - "COMMITMENTS" |
* - "CPUS" |
* - "CPUS_ALL_REGIONS" |
* - "DISKS_TOTAL_GB" |
@@ -29769,6 +31376,51 @@ class RegionList { |
} |
} |
+/** |
+ * Commitment for a particular resource (a Commitment is composed of one or more |
+ * of these). |
+ */ |
+class ResourceCommitment { |
+ /** |
+ * The amount of the resource purchased (in a type-dependent unit, such as |
+ * bytes). For vCPUs, this can just be an integer. For memory, this must be |
+ * provided in MB. Memory must be a multiple of 256 MB, with up to 6.5GB of |
+ * memory per every vCPU. |
+ */ |
+ core.String amount; |
+ /** |
+ * Type of resource for which this commitment applies. Possible values are |
+ * VCPU and MEMORY |
+ * Possible string values are: |
+ * - "MEMORY" |
+ * - "UNSPECIFIED" |
+ * - "VCPU" |
+ */ |
+ core.String type; |
+ |
+ ResourceCommitment(); |
+ |
+ ResourceCommitment.fromJson(core.Map _json) { |
+ if (_json.containsKey("amount")) { |
+ amount = _json["amount"]; |
+ } |
+ if (_json.containsKey("type")) { |
+ type = _json["type"]; |
+ } |
+ } |
+ |
+ core.Map<core.String, core.Object> toJson() { |
+ final core.Map<core.String, core.Object> _json = new core.Map<core.String, core.Object>(); |
+ if (amount != null) { |
+ _json["amount"] = amount; |
+ } |
+ if (type != null) { |
+ _json["type"] = type; |
+ } |
+ return _json; |
+ } |
+} |
+ |
class ResourceGroupReference { |
/** |
* A URI referencing one of the instance groups listed in the backend service. |