You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
* <p>Lists log events from the specified log group. You can list all the log events or filter the results
32
-
* using a filter pattern, a time range, and the name of the log stream.</p>
32
+
* using one or more of the following:</p>
33
+
* <ul>
34
+
* <li>
35
+
* <p>A filter pattern</p>
36
+
* </li>
37
+
* <li>
38
+
* <p>A time range</p>
39
+
* </li>
40
+
* <li>
41
+
* <p>The log stream name, or a log stream name prefix that matches mutltiple log streams</p>
42
+
* </li>
43
+
* </ul>
33
44
* <p>You must have the <code>logs:FilterLogEvents</code> permission to perform this operation.</p>
34
45
* <p>You can specify the log group to search by using either <code>logGroupIdentifier</code> or <code>logGroupName</code>.
35
46
* You must include one of these two parameters, but you can't include both.
36
47
* </p>
37
-
* <p>By default, this operation returns as many log events as can fit in 1 MB (up to 10,000
38
-
* log events) or all the events found within the specified time range. If the results include a
39
-
* token, that means there are more log events available. You can get additional results by
40
-
* specifying the token in a subsequent call. This operation can return empty results while there
41
-
* are more log events available through the token.</p>
48
+
* <p>
49
+
* <code>FilterLogEvents</code> is a paginated operation. Each page returned can contain up to 1 MB of log events or up to 10,000 log events. A returned page might only be partially full, or even empty.
50
+
* For example, if the result of a query would return 15,000 log events, the first page isn't guaranteed to have 10,000 log events even if they all fit into 1 MB.</p>
51
+
* <p>Partially full or empty pages
52
+
* don't necessarily mean that pagination is finished. If the results include a <code>nextToken</code>, there might be more log events available. You can return these additional log events by providing the nextToken in a subsequent
53
+
* <code>FilterLogEvents</code> operation. If the results don't include a <code>nextToken</code>, then pagination is finished. </p>
54
+
* <note>
55
+
* <p>If you set <code>startFromHead</code> to <code>true</code> and you don’t include <code>endTime</code> in your request, you can end up in a situation where the pagination doesn't terminate.
56
+
* This can happen when the new log events are being added to the target log streams
57
+
* faster than they are being read. This situation is a good use case for the CloudWatch Logs <a href="https://docs.aws.amazon.com/AmazonCloudWatch/latest/logs/CloudWatchLogs_LiveTail.html">Live Tail</a> feature.</p>
58
+
* </note>
42
59
* <p>The returned log events are sorted by event timestamp, the timestamp when the event was ingested
43
60
* by CloudWatch Logs, and the ID of the <code>PutLogEvents</code> request.</p>
44
61
* <p>If you are using CloudWatch cross-account observability, you can use this operation in a monitoring account and
45
62
* view data from the linked source accounts. For more information, see
* <p>If you are using <a href="https://docs.aws.amazon.com/AmazonCloudWatch/latest/logs/CloudWatch-Logs-Transformation.html">log transformation</a>, the <code>FilterLogEvents</code> operation returns only the original versions of log events, before they
66
+
* were transformed. To view the transformed versions, you must use a <a href="https://docs.aws.amazon.com/AmazonCloudWatch/latest/logs/AnalyzingLogData.html">CloudWatch Logs query.</a>
67
+
* </p>
68
+
* </note>
47
69
* @example
48
70
* Use a bare-bones client and the command you need to make an API call.
* <p>Lists log events from the specified log stream. You can list all of the log events or
32
32
* filter using a time range.</p>
33
-
* <p>By default, this operation returns as many log events as can fit in a response size of 1MB (up to 10,000 log events).
34
-
* You can get additional log events by specifying one of the tokens in a subsequent call.
35
-
* This operation can return empty results while there are more log events available through the token.</p>
33
+
* <p>
34
+
* <code>GetLogEvents</code> is a paginated operation. Each page returned can contain up to 1 MB of log events or up to 10,000 log events. A returned page might only be partially full, or even empty.
35
+
* For example, if the result of a query would return 15,000 log events, the first page isn't guaranteed to have 10,000 log events even if they all fit into 1 MB.</p>
36
+
* <p>Partially full or empty pages
37
+
* don't necessarily mean that pagination is finished. As long as the <code>nextBackwardToken</code> or <code>nextForwardToken</code> returned is NOT equal to the <code>nextToken</code>
38
+
* that you passed into the API call, there might be more
39
+
* log events available. The token that you use depends on the direction you want to move in along the log stream. The returned tokens are never null.</p>
40
+
* <note>
41
+
* <p>If you set <code>startFromHead</code> to <code>true</code> and you don’t include <code>endTime</code> in your request, you can end up in a situation where the pagination doesn't terminate.
42
+
* This can happen when the new log events are being added to the target log streams
43
+
* faster than they are being read. This situation is a good use case for the CloudWatch Logs <a href="https://docs.aws.amazon.com/AmazonCloudWatch/latest/logs/CloudWatchLogs_LiveTail.html">Live Tail</a> feature.</p>
44
+
* </note>
36
45
* <p>If you are using CloudWatch cross-account observability, you can use this operation in a monitoring account and
37
46
* view data from the linked source accounts. For more information, see
* <p>You can specify the log group to search by using either <code>logGroupIdentifier</code> or <code>logGroupName</code>.
40
49
* You must include one of these two parameters, but you can't include both.
41
50
* </p>
51
+
* <note>
52
+
* <p>If you are using <a href="https://docs.aws.amazon.com/AmazonCloudWatch/latest/logs/CloudWatch-Logs-Transformation.html">log transformation</a>, the <code>GetLogEvents</code> operation returns only the original versions of log events, before they
53
+
* were transformed. To view the transformed versions, you must use a <a href="https://docs.aws.amazon.com/AmazonCloudWatch/latest/logs/AnalyzingLogData.html">CloudWatch Logs query.</a>
54
+
* </p>
55
+
* </note>
42
56
* @example
43
57
* Use a bare-bones client and the command you need to make an API call.
* assigned, the anomalies found and the model used by this detector are encrypted at rest with the key. If
1196
1196
* a key is assigned to an anomaly detector, a user must have permissions for both this key and for the
1197
1197
* anomaly detector to retrieve information about the anomalies that it finds.</p>
1198
-
* <p>For more information about using a KMS key and to see the required IAM
1198
+
* <p> Make sure the value provided is a valid KMS key ARN. For more information about using a KMS key and to see the required IAM
1199
1199
* policy, see <a href="https://docs.aws.amazon.com/AmazonCloudWatch/latest/logs/LogsAnomalyDetection-KMS.html">Use a KMS key with an anomaly detector</a>.</p>
0 commit comments