Cancel a zonal shift in Amazon Application Recovery Controller. To cancel the zonal shift, specify the zonal shift ID.
A zonal shift can be one that you've started for a resource in your Amazon Web Services account in an Amazon Web Services Region, or it can be a zonal shift started by a practice run with zonal autoshift.
Parameters:
-
zonal_shift_id
(ZonalShiftId)
–
The internally-generated identifier of a zonal shift.
Raises:
Source code in docs_src/capo_arc_zonal_shift/_services/async_arc_zonal_shift.py
| async def cancel_zonal_shift(
self,
zonal_shift_id: "capo_arc_zonal_shift.types.zonal_shift_id.ZonalShiftId",
*,
config_overrides: Optional[AsyncARCZonalShiftClientConfig] = None,
) -> "capo_arc_zonal_shift.types.zonal_shift.ZonalShift":
"""<p>Cancel a zonal shift in Amazon Application Recovery Controller. To cancel the zonal shift, specify the zonal shift ID.</p> <p>A zonal shift can be one that you've started for a resource in your Amazon Web Services account in an Amazon Web Services Region, or it can be a zonal shift started by a practice run with zonal autoshift. </p>
Args:
zonal_shift_id: <p>The internally-generated identifier of a zonal shift.</p>
Raises:
capo_arc_zonal_shift.errors.access_denied_exception.AccessDeniedException: <p>You do not have sufficient access to perform this action.</p>
capo_arc_zonal_shift.errors.conflict_exception.ConflictException: <p>The request could not be processed because of conflict in the current state of the resource.</p>
capo_arc_zonal_shift.errors.internal_server_exception.InternalServerException: <p>There was an internal server error.</p>
capo_arc_zonal_shift.errors.resource_not_found_exception.ResourceNotFoundException: <p>The input requested a resource that was not found.</p>
capo_arc_zonal_shift.errors.throttling_exception.ThrottlingException: <p>The request was denied due to request throttling.</p>
capo_arc_zonal_shift.errors.validation_exception.ValidationException: <p>The input fails to satisfy the constraints specified by an Amazon Web Services service.</p>
capo_arc_zonal_shift.errors.UnknownServiceError: The service returned an error code this client does not model.
"""
async def _handler(
req: "AsyncOperationRequest[capo_arc_zonal_shift.types.cancel_zonal_shift_request.CancelZonalShiftRequest]",
) -> AsyncOperationResponse[
"capo_arc_zonal_shift.types.zonal_shift.ZonalShift"
]:
import capo_arc_zonal_shift._operations.perc_data_plane.cancel_zonal_shift
(
output,
http_response,
) = await capo_arc_zonal_shift._operations.perc_data_plane.cancel_zonal_shift.async_cancel_zonal_shift(
req.options, req.input
)
return AsyncOperationResponse(output=output, response=http_response)
interceptors_, options_ = self.operation_options(
config_overrides, OperationLogging("CancelZonalShift")
)
input_: capo_arc_zonal_shift.types.cancel_zonal_shift_request.CancelZonalShiftRequest = {
"zonal_shift_id": zonal_shift_id
}
response = await aexecute_pipeline(
AsyncOperationRequest(input=input_, options=options_),
handler=_handler,
interceptors=list(interceptors_),
)
await response.response.aclose()
return response.output
|