Stops an in-progress operation on a StackSet and its associated stack instances. StackSets will cancel all the unstarted stack instance deployments and wait for those are in-progress to complete.
Parameters:
-
stack_set_name
(Optional[StackSetName], default:
None
)
–
The name or unique ID of the StackSet that you want to stop the operation for.
-
operation_id
(Optional[ClientRequestToken], default:
None
)
–
The ID of the stack operation.
-
call_as
(Optional[CallAs], default:
None
)
–
Specifies whether you are acting as an account administrator in the organization's management account or as a delegated administrator in a member account. Valid only if the StackSet uses service-managed permissions.
By default, SELF is specified. Use SELF for StackSets with self-managed permissions.
-
If you are signed in to the management account, specify SELF.
-
If you are signed in to a delegated administrator account, specify DELEGATED_ADMIN.
Your Amazon Web Services account must be registered as a delegated administrator in the management account. For more information, see Register a delegated administrator in the CloudFormation User Guide.
Raises:
Source code in docs_src/capo_cloudformation/_services/async_cloud_formation.py
| async def stop_stack_set_operation(
self,
*,
config_overrides: Optional[AsyncCloudFormationClientConfig] = None,
stack_set_name: Optional[
"capo_cloudformation.types.stack_set_name.StackSetName"
] = None,
operation_id: Optional[
"capo_cloudformation.types.client_request_token.ClientRequestToken"
] = None,
call_as: Optional["capo_cloudformation.types.call_as.CallAs"] = None,
) -> "capo_cloudformation.types.stop_stack_set_operation_output.StopStackSetOperationOutput":
"""<p>Stops an in-progress operation on a StackSet and its associated stack instances. StackSets will cancel all the unstarted stack instance deployments and wait for those are in-progress to complete.</p>
Args:
stack_set_name: <p>The name or unique ID of the StackSet that you want to stop the operation for.</p>
operation_id: <p>The ID of the stack operation.</p>
call_as: <p>Specifies whether you are acting as an account administrator in the organization's management account or as a delegated administrator in a member account. Valid only if the StackSet uses service-managed permissions.</p> <p>By default, <code>SELF</code> is specified. Use <code>SELF</code> for StackSets with self-managed permissions.</p> <ul> <li> <p>If you are signed in to the management account, specify <code>SELF</code>.</p> </li> <li> <p>If you are signed in to a delegated administrator account, specify <code>DELEGATED_ADMIN</code>.</p> <p>Your Amazon Web Services account must be registered as a delegated administrator in the management account. For more information, see <a href="https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/stacksets-orgs-delegated-admin.html">Register a delegated administrator</a> in the <i>CloudFormation User Guide</i>.</p> </li> </ul>
Raises:
capo_cloudformation.errors.invalid_operation_exception.InvalidOperationException: <p>The specified operation isn't valid.</p>
capo_cloudformation.errors.operation_not_found_exception.OperationNotFoundException: <p>The specified ID refers to an operation that doesn't exist.</p>
capo_cloudformation.errors.stack_set_not_found_exception.StackSetNotFoundException: <p>The specified StackSet doesn't exist.</p>
capo_cloudformation.errors.UnknownServiceError: The service returned an error code this client does not model.
"""
async def _handler(
req: "AsyncOperationRequest[capo_cloudformation.types.stop_stack_set_operation_input.StopStackSetOperationInput]",
) -> AsyncOperationResponse[
"capo_cloudformation.types.stop_stack_set_operation_output.StopStackSetOperationOutput"
]:
import capo_cloudformation._operations.cloud_formation.stop_stack_set_operation
(
output,
http_response,
) = await capo_cloudformation._operations.cloud_formation.stop_stack_set_operation.async_stop_stack_set_operation(
req.options, req.input
)
return AsyncOperationResponse(output=output, response=http_response)
interceptors_, options_ = self.operation_options(
config_overrides, OperationLogging("StopStackSetOperation")
)
input_: capo_cloudformation.types.stop_stack_set_operation_input.StopStackSetOperationInput = {}
if stack_set_name is not None:
input_["stack_set_name"] = stack_set_name
if operation_id is not None:
input_["operation_id"] = operation_id
if call_as is not None:
input_["call_as"] = call_as
response = await aexecute_pipeline(
AsyncOperationRequest(input=input_, options=options_),
handler=_handler,
interceptors=list(interceptors_),
)
await response.response.aclose()
return response.output
|