Deletes a deployment strategy.
Parameters:
-
deployment_strategy_id
(DeploymentStrategyId)
–
The ID of the deployment strategy you want to delete.
Raises:
Examples:
To delete a deployment strategy
The following delete-deployment-strategy example deletes the specified deployment strategy.
>>> client.delete_deployment_strategy(deployment_strategy_id='1225qzk')
Source code in docs_src/capo_appconfig/_services/app_config.py
| def delete_deployment_strategy(
self,
deployment_strategy_id: "capo_appconfig.types.deployment_strategy_id.DeploymentStrategyId",
*,
config_overrides: Optional[AppConfigClientConfig] = None,
) -> None:
"""<p>Deletes a deployment strategy.</p>
Args:
deployment_strategy_id: <p>The ID of the deployment strategy you want to delete.</p>
Raises:
capo_appconfig.errors.bad_request_exception.BadRequestException: <p>The input fails to satisfy the constraints specified by an Amazon Web Services service.</p>
capo_appconfig.errors.internal_server_exception.InternalServerException: <p>There was an internal failure in the AppConfig service.</p>
capo_appconfig.errors.resource_not_found_exception.ResourceNotFoundException: <p>The requested resource could not be found.</p>
capo_appconfig.errors.UnknownServiceError: The service returned an error code this client does not model.
Examples:
To delete a deployment strategy
The following delete-deployment-strategy example deletes the specified deployment strategy.
>>> client.delete_deployment_strategy(deployment_strategy_id='1225qzk')
"""
def _handler(
req: "OperationRequest[capo_appconfig.types.delete_deployment_strategy_request.DeleteDeploymentStrategyRequest]",
) -> OperationResponse[None]:
import capo_appconfig._operations.amazon_app_config.delete_deployment_strategy
output, http_response = (
capo_appconfig._operations.amazon_app_config.delete_deployment_strategy.delete_deployment_strategy(
req.options, req.input
)
)
return OperationResponse(output=output, response=http_response)
interceptors_, options_ = self.operation_options(
config_overrides, OperationLogging("DeleteDeploymentStrategy")
)
input_: capo_appconfig.types.delete_deployment_strategy_request.DeleteDeploymentStrategyRequest = {
"deployment_strategy_id": deployment_strategy_id
}
response = execute_pipeline(
OperationRequest(input=input_, options=options_),
handler=_handler,
interceptors=list(interceptors_),
)
response.response.close()
return response.output
|