Deploys multiple groups in one operation. This action starts the bulk deployment of a specified set of group versions. Each group version deployment will be triggered with an adaptive rate that has a fixed upper limit. We recommend that you include an ''X-Amzn-Client-Token'' token in every ''StartBulkDeployment'' request. These requests are idempotent with respect to the token and the request parameters.
Parameters:
-
amzn_client_token
(Optional[__string], default:
None
)
–
A client token used to correlate requests and responses.
-
execution_role_arn
(Optional[__string], default:
None
)
–
The ARN of the execution role to associate with the bulk deployment operation. This IAM role must allow the ''greengrass:CreateDeployment'' action for all group versions that are listed in the input file. This IAM role must have access to the S3 bucket containing the input file.
-
input_file_uri
(Optional[__string], default:
None
)
–
The URI of the input file contained in the S3 bucket. The execution role must have ''getObject'' permissions on this bucket to access the input file. The input file is a JSON-serialized, line delimited file with UTF-8 encoding that provides a list of group and version IDs and the deployment type. This file must be less than 100 MB. Currently, AWS IoT Greengrass supports only ''NewDeployment'' deployment types.
-
tags
(Optional[Tags], default:
None
)
–
Tag(s) to add to the new resource.
Raises:
Source code in docs_src/capo_greengrass/_services/greengrass.py
| def start_bulk_deployment(
self,
*,
config_overrides: Optional[GreengrassClientConfig] = None,
amzn_client_token: Optional["capo_greengrass.types.__string.__string"] = None,
execution_role_arn: Optional["capo_greengrass.types.__string.__string"] = None,
input_file_uri: Optional["capo_greengrass.types.__string.__string"] = None,
tags: Optional["capo_greengrass.types.tags.Tags"] = None,
) -> "capo_greengrass.types.start_bulk_deployment_response.StartBulkDeploymentResponse":
"""Deploys multiple groups in one operation. This action starts the bulk deployment of a specified set of group versions. Each group version deployment will be triggered with an adaptive rate that has a fixed upper limit. We recommend that you include an ''X-Amzn-Client-Token'' token in every ''StartBulkDeployment'' request. These requests are idempotent with respect to the token and the request parameters.
Args:
amzn_client_token: A client token used to correlate requests and responses.
execution_role_arn: The ARN of the execution role to associate with the bulk deployment operation. This IAM role must allow the ''greengrass:CreateDeployment'' action for all group versions that are listed in the input file. This IAM role must have access to the S3 bucket containing the input file.
input_file_uri: The URI of the input file contained in the S3 bucket. The execution role must have ''getObject'' permissions on this bucket to access the input file. The input file is a JSON-serialized, line delimited file with UTF-8 encoding that provides a list of group and version IDs and the deployment type. This file must be less than 100 MB. Currently, AWS IoT Greengrass supports only ''NewDeployment'' deployment types.
tags: Tag(s) to add to the new resource.
Raises:
capo_greengrass.errors.bad_request_exception.BadRequestException: General error information.
capo_greengrass.errors.UnknownServiceError: The service returned an error code this client does not model.
"""
def _handler(
req: "OperationRequest[capo_greengrass.types.start_bulk_deployment_request.StartBulkDeploymentRequest]",
) -> OperationResponse[
"capo_greengrass.types.start_bulk_deployment_response.StartBulkDeploymentResponse"
]:
import capo_greengrass._operations.greengrass.start_bulk_deployment
output, http_response = (
capo_greengrass._operations.greengrass.start_bulk_deployment.start_bulk_deployment(
req.options, req.input
)
)
return OperationResponse(output=output, response=http_response)
interceptors_, options_ = self.operation_options(
config_overrides, OperationLogging("StartBulkDeployment")
)
input_: capo_greengrass.types.start_bulk_deployment_request.StartBulkDeploymentRequest = {}
if amzn_client_token is not None:
input_["amzn_client_token"] = amzn_client_token
if execution_role_arn is not None:
input_["execution_role_arn"] = execution_role_arn
if input_file_uri is not None:
input_["input_file_uri"] = input_file_uri
if tags is not None:
input_["tags"] = tags
response = execute_pipeline(
OperationRequest(input=input_, options=options_),
handler=_handler,
interceptors=list(interceptors_),
)
response.response.close()
return response.output
|