Deletes the integration between CloudWatch Logs and OpenSearch Service. If your integration has active vended logs dashboards, you must specify true for the force parameter, otherwise the operation will fail. If you delete the integration by setting force to true, all your vended logs dashboards powered by OpenSearch Service will be deleted and the data that was on them will no longer be accessible.
Parameters:
-
integration_name
(IntegrationName)
–
The name of the integration to delete. To find the name of your integration, use ListIntegrations.
-
force
(Optional[Force], default:
None
)
–
Specify true to force the deletion of the integration even if vended logs dashboards currently exist.
The default is false.
Raises:
Source code in docs_src/capo_cloudwatch_logs/_services/async_cloud_watch_logs.py
| async def delete_integration(
self,
integration_name: "capo_cloudwatch_logs.types.integration_name.IntegrationName",
*,
config_overrides: Optional[AsyncCloudWatchLogsClientConfig] = None,
force: Optional["capo_cloudwatch_logs.types.force.Force"] = None,
) -> "capo_cloudwatch_logs.types.delete_integration_response.DeleteIntegrationResponse":
"""<p>Deletes the integration between CloudWatch Logs and OpenSearch Service. If your integration has active vended logs dashboards, you must specify <code>true</code> for the <code>force</code> parameter, otherwise the operation will fail. If you delete the integration by setting <code>force</code> to <code>true</code>, all your vended logs dashboards powered by OpenSearch Service will be deleted and the data that was on them will no longer be accessible.</p>
Args:
integration_name: <p>The name of the integration to delete. To find the name of your integration, use <a href="https://docs.aws.amazon.com/AmazonCloudWatchLogs/latest/APIReference/API_ListIntegrations.html">ListIntegrations</a>.</p>
force: <p>Specify <code>true</code> to force the deletion of the integration even if vended logs dashboards currently exist.</p> <p>The default is <code>false</code>.</p>
Raises:
capo_cloudwatch_logs.errors.invalid_parameter_exception.InvalidParameterException: <p>A parameter is specified incorrectly.</p>
capo_cloudwatch_logs.errors.resource_not_found_exception.ResourceNotFoundException: <p>The specified resource does not exist.</p>
capo_cloudwatch_logs.errors.service_unavailable_exception.ServiceUnavailableException: <p>The service cannot complete the request.</p>
capo_cloudwatch_logs.errors.validation_exception.ValidationException: <p>One of the parameters for the request is not valid.</p>
capo_cloudwatch_logs.errors.UnknownServiceError: The service returned an error code this client does not model.
"""
async def _handler(
req: "AsyncOperationRequest[capo_cloudwatch_logs.types.delete_integration_request.DeleteIntegrationRequest]",
) -> AsyncOperationResponse[
"capo_cloudwatch_logs.types.delete_integration_response.DeleteIntegrationResponse"
]:
import capo_cloudwatch_logs._operations.logs_20140328.delete_integration
(
output,
http_response,
) = await capo_cloudwatch_logs._operations.logs_20140328.delete_integration.async_delete_integration(
req.options, req.input
)
return AsyncOperationResponse(output=output, response=http_response)
interceptors_, options_ = self.operation_options(
config_overrides, OperationLogging("DeleteIntegration")
)
input_: capo_cloudwatch_logs.types.delete_integration_request.DeleteIntegrationRequest = {
"integration_name": integration_name
}
if force is not None:
input_["force"] = force
response = await aexecute_pipeline(
AsyncOperationRequest(input=input_, options=options_),
handler=_handler,
interceptors=list(interceptors_),
)
await response.response.aclose()
return response.output
|