describe_queries
async
¶
describe_queries(
*,
config_overrides: Optional[AsyncCloudWatchLogsClientConfig] = None,
log_group_name: Optional[LogGroupName] = None,
status: Optional[QueryStatus] = None,
max_results: Optional[DescribeQueriesMaxResults] = None,
next_token: Optional[NextToken] = None,
query_language: Optional[QueryLanguage] = None,
) -> DescribeQueriesResponse
Returns a list of CloudWatch Logs Insights queries that are scheduled, running, or have been run recently in this account. You can request all queries or limit it to queries of a specific log group or queries with a certain status.
This operation includes both interactive queries started directly by users and automated queries executed by scheduled query configurations. Scheduled query executions appear in the results alongside manually initiated queries, providing visibility into all query activity in your account.
Parameters:
-
log_group_name(Optional[LogGroupName], default:None) –Limits the returned queries to only those for the specified log group.
-
status(Optional[QueryStatus], default:None) –Limits the returned queries to only those that have the specified status. Valid values are
Cancelled,Complete,Failed,Running, andScheduled. -
max_results(Optional[DescribeQueriesMaxResults], default:None) –Limits the number of returned queries to the specified number.
-
query_language(Optional[QueryLanguage], default:None) –Limits the returned queries to only the queries that use the specified query language.
Raises:
-
InvalidParameterException–A parameter is specified incorrectly.
-
ResourceNotFoundException–The specified resource does not exist.
-
ServiceUnavailableException–The service cannot complete the request.
-
UnknownServiceError–The service returned an error code this client does not model.
Source code in docs_src/capo_cloudwatch_logs/_services/async_cloud_watch_logs.py
3675 3676 3677 3678 3679 3680 3681 3682 3683 3684 3685 3686 3687 3688 3689 3690 3691 3692 3693 3694 3695 3696 3697 3698 3699 3700 3701 3702 3703 3704 3705 3706 3707 3708 3709 3710 3711 3712 3713 3714 3715 3716 3717 3718 3719 3720 3721 3722 3723 3724 3725 3726 3727 3728 3729 3730 3731 3732 3733 3734 3735 3736 3737 3738 3739 3740 3741 3742 | |