aws-sdk-cloudwatchlogs 1.73.0 → 1.75.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/CHANGELOG.md +10 -0
- data/VERSION +1 -1
- data/lib/aws-sdk-cloudwatchlogs/client.rb +499 -6
- data/lib/aws-sdk-cloudwatchlogs/client_api.rb +271 -0
- data/lib/aws-sdk-cloudwatchlogs/endpoints.rb +98 -0
- data/lib/aws-sdk-cloudwatchlogs/plugins/endpoints.rb +17 -2
- data/lib/aws-sdk-cloudwatchlogs/types.rb +727 -8
- data/lib/aws-sdk-cloudwatchlogs.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 4834aeed0119f7fd349d6f28f756486f7a93db73d017fcbc6dfab6eb4190db3f
|
4
|
+
data.tar.gz: bbc5c111dd70c79b1767111afa2c2928f5912db98b3ddf8aadaa14203b666a37
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 1e0cb9f4a280f0d85b6de5c26cf085623046dff290134a97dca432799c72b39a831dbb88a338495f1d6b24bd52c13c2ca7aa24975f89020889a12c5f821a46bb
|
7
|
+
data.tar.gz: 28e52242c28c4327728a46f0ca78e5525d88f9c61085471c9157e7b1f879ff87e6eab3111d73f0080616cc2d7343f78c1f58adce8b2464c1e0e96a1ed8e78282
|
data/CHANGELOG.md
CHANGED
@@ -1,6 +1,16 @@
|
|
1
1
|
Unreleased Changes
|
2
2
|
------------------
|
3
3
|
|
4
|
+
1.75.0 (2023-11-28)
|
5
|
+
------------------
|
6
|
+
|
7
|
+
* Feature - Code Generated Changes, see `./build_tools` or `aws-sdk-core`'s CHANGELOG.md for details.
|
8
|
+
|
9
|
+
1.74.0 (2023-11-27)
|
10
|
+
------------------
|
11
|
+
|
12
|
+
* Feature - Added APIs to Create, Update, Get, List and Delete LogAnomalyDetectors and List and Update Anomalies in Detector. Added LogGroupClass attribute for LogGroups to classify loggroup as Standard loggroup with all capabilities or InfrequentAccess loggroup with limited capabilities.
|
13
|
+
|
4
14
|
1.73.0 (2023-11-22)
|
5
15
|
------------------
|
6
16
|
|
data/VERSION
CHANGED
@@ -1 +1 @@
|
|
1
|
-
1.
|
1
|
+
1.75.0
|
@@ -589,7 +589,7 @@ module Aws::CloudWatchLogs
|
|
589
589
|
#
|
590
590
|
#
|
591
591
|
#
|
592
|
-
# [1]: https://docs.aws.amazon.com/
|
592
|
+
# [1]: https://docs.aws.amazon.com/AmazonCloudWatch/latest/logs/AWS-logs-and-resource-policy.html
|
593
593
|
# [2]: https://docs.aws.amazon.com/AmazonCloudWatchLogs/latest/APIReference/API_PutDeliverySource.html
|
594
594
|
# [3]: https://docs.aws.amazon.com/AmazonCloudWatchLogs/latest/APIReference/API_PutDeliveryDestination.html
|
595
595
|
# [4]: https://docs.aws.amazon.com/AmazonCloudWatchLogs/latest/APIReference/API_PutDeliveryDestinationolicy.html
|
@@ -738,6 +738,132 @@ module Aws::CloudWatchLogs
|
|
738
738
|
req.send_request(options)
|
739
739
|
end
|
740
740
|
|
741
|
+
# Creates an *anomaly detector* that regularly scans one or more log
|
742
|
+
# groups and look for patterns and anomalies in the logs.
|
743
|
+
#
|
744
|
+
# An anomaly detector can help surface issues by automatically
|
745
|
+
# discovering anomalies in your log event traffic. An anomaly detector
|
746
|
+
# uses machine learning algorithms to scan log events and find
|
747
|
+
# *patterns*. A pattern is a shared text structure that recurs among
|
748
|
+
# your log fields. Patterns provide a useful tool for analyzing large
|
749
|
+
# sets of logs because a large number of log events can often be
|
750
|
+
# compressed into a few patterns.
|
751
|
+
#
|
752
|
+
# The anomaly detector uses pattern recognition to find `anomalies`,
|
753
|
+
# which are unusual log events. It uses the `evaluationFrequency` to
|
754
|
+
# compare current log events and patterns with trained baselines.
|
755
|
+
#
|
756
|
+
# Fields within a pattern are called *tokens*. Fields that vary within a
|
757
|
+
# pattern, such as a request ID or timestamp, are referred to as
|
758
|
+
# *dynamic tokens* and represented by `<*>`.
|
759
|
+
#
|
760
|
+
# The following is an example of a pattern:
|
761
|
+
#
|
762
|
+
# `[INFO] Request time: <*> ms`
|
763
|
+
#
|
764
|
+
# This pattern represents log events like `[INFO] Request time: 327 ms`
|
765
|
+
# and other similar log events that differ only by the number, in this
|
766
|
+
# csse 327. When the pattern is displayed, the different numbers are
|
767
|
+
# replaced by `<*>`
|
768
|
+
#
|
769
|
+
# <note markdown="1"> Any parts of log events that are masked as sensitive data are not
|
770
|
+
# scanned for anomalies. For more information about masking sensitive
|
771
|
+
# data, see [Help protect sensitive log data with masking][1].
|
772
|
+
#
|
773
|
+
# </note>
|
774
|
+
#
|
775
|
+
#
|
776
|
+
#
|
777
|
+
# [1]: https://docs.aws.amazon.com/AmazonCloudWatch/latest/logs/mask-sensitive-log-data.html
|
778
|
+
#
|
779
|
+
# @option params [required, Array<String>] :log_group_arn_list
|
780
|
+
# An array containing the ARNs of the log groups that this anomaly
|
781
|
+
# detector will watch. You must specify at least one ARN.
|
782
|
+
#
|
783
|
+
# @option params [String] :detector_name
|
784
|
+
# A name for this anomaly detector.
|
785
|
+
#
|
786
|
+
# @option params [String] :evaluation_frequency
|
787
|
+
# Specifies how often the anomaly detector is to run and look for
|
788
|
+
# anomalies. Set this value according to the frequency that the log
|
789
|
+
# group receives new logs. For example, if the log group receives new
|
790
|
+
# log events every 10 minutes, then 15 minutes might be a good setting
|
791
|
+
# for `evaluationFrequency` .
|
792
|
+
#
|
793
|
+
# @option params [String] :filter_pattern
|
794
|
+
# You can use this parameter to limit the anomaly detection model to
|
795
|
+
# examine only log events that match the pattern you specify here. For
|
796
|
+
# more information, see [Filter and Pattern Syntax][1].
|
797
|
+
#
|
798
|
+
#
|
799
|
+
#
|
800
|
+
# [1]: https://docs.aws.amazon.com/AmazonCloudWatch/latest/logs/FilterAndPatternSyntax.html
|
801
|
+
#
|
802
|
+
# @option params [String] :kms_key_id
|
803
|
+
# Optionally assigns a KMS key to secure this anomaly detector and its
|
804
|
+
# findings. If a key is assigned, the anomalies found and the model used
|
805
|
+
# by this detector are encrypted at rest with the key. If a key is
|
806
|
+
# assigned to an anomaly detector, a user must have permissions for both
|
807
|
+
# this key and for the anomaly detector to retrieve information about
|
808
|
+
# the anomalies that it finds.
|
809
|
+
#
|
810
|
+
# For more information about using a KMS key and to see the required IAM
|
811
|
+
# policy, see [Use a KMS key with an anomaly detector][1].
|
812
|
+
#
|
813
|
+
#
|
814
|
+
#
|
815
|
+
# [1]: https://docs.aws.amazon.com/AmazonCloudWatch/latest/logs/LogsAnomalyDetection-KMS.html
|
816
|
+
#
|
817
|
+
# @option params [Integer] :anomaly_visibility_time
|
818
|
+
# The number of days to have visibility on an anomaly. After this time
|
819
|
+
# period has elapsed for an anomaly, it will be automatically baselined
|
820
|
+
# and the anomaly detector will treat new occurrences of a similar
|
821
|
+
# anomaly as normal. Therefore, if you do not correct the cause of an
|
822
|
+
# anomaly during the time period specified in `anomalyVisibilityTime`,
|
823
|
+
# it will be considered normal going forward and will not be detected as
|
824
|
+
# an anomaly.
|
825
|
+
#
|
826
|
+
# @option params [Hash<String,String>] :tags
|
827
|
+
# An optional list of key-value pairs to associate with the resource.
|
828
|
+
#
|
829
|
+
# For more information about tagging, see [Tagging Amazon Web Services
|
830
|
+
# resources][1]
|
831
|
+
#
|
832
|
+
#
|
833
|
+
#
|
834
|
+
# [1]: https://docs.aws.amazon.com/general/latest/gr/aws_tagging.html
|
835
|
+
#
|
836
|
+
# @return [Types::CreateLogAnomalyDetectorResponse] Returns a {Seahorse::Client::Response response} object which responds to the following methods:
|
837
|
+
#
|
838
|
+
# * {Types::CreateLogAnomalyDetectorResponse#anomaly_detector_arn #anomaly_detector_arn} => String
|
839
|
+
#
|
840
|
+
# @example Request syntax with placeholder values
|
841
|
+
#
|
842
|
+
# resp = client.create_log_anomaly_detector({
|
843
|
+
# log_group_arn_list: ["LogGroupArn"], # required
|
844
|
+
# detector_name: "DetectorName",
|
845
|
+
# evaluation_frequency: "ONE_MIN", # accepts ONE_MIN, FIVE_MIN, TEN_MIN, FIFTEEN_MIN, THIRTY_MIN, ONE_HOUR
|
846
|
+
# filter_pattern: "FilterPattern",
|
847
|
+
# kms_key_id: "KmsKeyId",
|
848
|
+
# anomaly_visibility_time: 1,
|
849
|
+
# tags: {
|
850
|
+
# "TagKey" => "TagValue",
|
851
|
+
# },
|
852
|
+
# })
|
853
|
+
#
|
854
|
+
# @example Response structure
|
855
|
+
#
|
856
|
+
# resp.anomaly_detector_arn #=> String
|
857
|
+
#
|
858
|
+
# @see http://docs.aws.amazon.com/goto/WebAPI/logs-2014-03-28/CreateLogAnomalyDetector AWS API Documentation
|
859
|
+
#
|
860
|
+
# @overload create_log_anomaly_detector(params = {})
|
861
|
+
# @param [Hash] params ({})
|
862
|
+
def create_log_anomaly_detector(params = {}, options = {})
|
863
|
+
req = build_request(:create_log_anomaly_detector, params)
|
864
|
+
req.send_request(options)
|
865
|
+
end
|
866
|
+
|
741
867
|
# Creates a log group with the specified name. You can create up to
|
742
868
|
# 1,000,000 log groups per Region per account.
|
743
869
|
#
|
@@ -775,7 +901,7 @@ module Aws::CloudWatchLogs
|
|
775
901
|
# [2]: https://docs.aws.amazon.com/kms/latest/developerguide/symmetric-asymmetric.html
|
776
902
|
#
|
777
903
|
# @option params [required, String] :log_group_name
|
778
|
-
#
|
904
|
+
# A name for the log group.
|
779
905
|
#
|
780
906
|
# @option params [String] :kms_key_id
|
781
907
|
# The Amazon Resource Name (ARN) of the KMS key to use when encrypting
|
@@ -802,6 +928,24 @@ module Aws::CloudWatchLogs
|
|
802
928
|
# [1]: https://docs.aws.amazon.com/general/latest/gr/aws_tagging.html
|
803
929
|
# [2]: https://docs.aws.amazon.com/IAM/latest/UserGuide/access_tags.html
|
804
930
|
#
|
931
|
+
# @option params [String] :log_group_class
|
932
|
+
# Use this parameter to specify the log group class for this log group.
|
933
|
+
# There are two classes:
|
934
|
+
#
|
935
|
+
# * The `Standard` log class supports all CloudWatch Logs features.
|
936
|
+
#
|
937
|
+
# * The `Infrequent Access` log class supports a subset of CloudWatch
|
938
|
+
# Logs features and incurs lower costs.
|
939
|
+
#
|
940
|
+
# If you omit this parameter, the default of `STANDARD` is used.
|
941
|
+
#
|
942
|
+
# For details about the features supported by each class, see [Log
|
943
|
+
# classes][1]
|
944
|
+
#
|
945
|
+
#
|
946
|
+
#
|
947
|
+
# [1]: https://docs.aws.amazon.com/AmazonCloudWatch/latest/logs/CloudWatch_Logs_Log_Classes.html
|
948
|
+
#
|
805
949
|
# @return [Struct] Returns an empty {Seahorse::Client::Response response}.
|
806
950
|
#
|
807
951
|
# @example Request syntax with placeholder values
|
@@ -812,6 +956,7 @@ module Aws::CloudWatchLogs
|
|
812
956
|
# tags: {
|
813
957
|
# "TagKey" => "TagValue",
|
814
958
|
# },
|
959
|
+
# log_group_class: "STANDARD", # accepts STANDARD, INFREQUENT_ACCESS
|
815
960
|
# })
|
816
961
|
#
|
817
962
|
# @see http://docs.aws.amazon.com/goto/WebAPI/logs-2014-03-28/CreateLogGroup AWS API Documentation
|
@@ -1077,6 +1222,34 @@ module Aws::CloudWatchLogs
|
|
1077
1222
|
req.send_request(options)
|
1078
1223
|
end
|
1079
1224
|
|
1225
|
+
# Deletes the specified CloudWatch Logs anomaly detector.
|
1226
|
+
#
|
1227
|
+
# @option params [required, String] :anomaly_detector_arn
|
1228
|
+
# The ARN of the anomaly detector to delete. You can find the ARNs of
|
1229
|
+
# log anomaly detectors in your account by using the
|
1230
|
+
# [ListLogAnomalyDetectors][1] operation.
|
1231
|
+
#
|
1232
|
+
#
|
1233
|
+
#
|
1234
|
+
# [1]: https://docs.aws.amazon.com/AmazonCloudWatchLogs/latest/APIReference/API_ListLogAnomalyDetectors.html
|
1235
|
+
#
|
1236
|
+
# @return [Struct] Returns an empty {Seahorse::Client::Response response}.
|
1237
|
+
#
|
1238
|
+
# @example Request syntax with placeholder values
|
1239
|
+
#
|
1240
|
+
# resp = client.delete_log_anomaly_detector({
|
1241
|
+
# anomaly_detector_arn: "AnomalyDetectorArn", # required
|
1242
|
+
# })
|
1243
|
+
#
|
1244
|
+
# @see http://docs.aws.amazon.com/goto/WebAPI/logs-2014-03-28/DeleteLogAnomalyDetector AWS API Documentation
|
1245
|
+
#
|
1246
|
+
# @overload delete_log_anomaly_detector(params = {})
|
1247
|
+
# @param [Hash] params ({})
|
1248
|
+
def delete_log_anomaly_detector(params = {}, options = {})
|
1249
|
+
req = build_request(:delete_log_anomaly_detector, params)
|
1250
|
+
req.send_request(options)
|
1251
|
+
end
|
1252
|
+
|
1080
1253
|
# Deletes the specified log group and permanently deletes all the
|
1081
1254
|
# archived log events associated with the log group.
|
1082
1255
|
#
|
@@ -1635,6 +1808,22 @@ module Aws::CloudWatchLogs
|
|
1635
1808
|
# account and all log groups in all source accounts that are linked to
|
1636
1809
|
# the monitoring account.
|
1637
1810
|
#
|
1811
|
+
# @option params [String] :log_group_class
|
1812
|
+
# Specifies the log group class for this log group. There are two
|
1813
|
+
# classes:
|
1814
|
+
#
|
1815
|
+
# * The `Standard` log class supports all CloudWatch Logs features.
|
1816
|
+
#
|
1817
|
+
# * The `Infrequent Access` log class supports a subset of CloudWatch
|
1818
|
+
# Logs features and incurs lower costs.
|
1819
|
+
#
|
1820
|
+
# For details about the features supported by each class, see [Log
|
1821
|
+
# classes][1]
|
1822
|
+
#
|
1823
|
+
#
|
1824
|
+
#
|
1825
|
+
# [1]: https://docs.aws.amazon.com/AmazonCloudWatch/latest/logs/CloudWatch_Logs_Log_Classes.html
|
1826
|
+
#
|
1638
1827
|
# @return [Types::DescribeLogGroupsResponse] Returns a {Seahorse::Client::Response response} object which responds to the following methods:
|
1639
1828
|
#
|
1640
1829
|
# * {Types::DescribeLogGroupsResponse#log_groups #log_groups} => Array<Types::LogGroup>
|
@@ -1651,6 +1840,7 @@ module Aws::CloudWatchLogs
|
|
1651
1840
|
# next_token: "NextToken",
|
1652
1841
|
# limit: 1,
|
1653
1842
|
# include_linked_accounts: false,
|
1843
|
+
# log_group_class: "STANDARD", # accepts STANDARD, INFREQUENT_ACCESS
|
1654
1844
|
# })
|
1655
1845
|
#
|
1656
1846
|
# @example Response structure
|
@@ -1666,6 +1856,7 @@ module Aws::CloudWatchLogs
|
|
1666
1856
|
# resp.log_groups[0].data_protection_status #=> String, one of "ACTIVATED", "DELETED", "ARCHIVED", "DISABLED"
|
1667
1857
|
# resp.log_groups[0].inherited_properties #=> Array
|
1668
1858
|
# resp.log_groups[0].inherited_properties[0] #=> String, one of "ACCOUNT_DATA_PROTECTION"
|
1859
|
+
# resp.log_groups[0].log_group_class #=> String, one of "STANDARD", "INFREQUENT_ACCESS"
|
1669
1860
|
# resp.next_token #=> String
|
1670
1861
|
#
|
1671
1862
|
# @see http://docs.aws.amazon.com/goto/WebAPI/logs-2014-03-28/DescribeLogGroups AWS API Documentation
|
@@ -2482,6 +2673,57 @@ module Aws::CloudWatchLogs
|
|
2482
2673
|
req.send_request(options)
|
2483
2674
|
end
|
2484
2675
|
|
2676
|
+
# Retrieves information about the log anomaly detector that you specify.
|
2677
|
+
#
|
2678
|
+
# @option params [required, String] :anomaly_detector_arn
|
2679
|
+
# The ARN of the anomaly detector to retrieve information about. You can
|
2680
|
+
# find the ARNs of log anomaly detectors in your account by using the
|
2681
|
+
# [ListLogAnomalyDetectors][1] operation.
|
2682
|
+
#
|
2683
|
+
#
|
2684
|
+
#
|
2685
|
+
# [1]: https://docs.aws.amazon.com/AmazonCloudWatchLogs/latest/APIReference/API_ListLogAnomalyDetectors.html
|
2686
|
+
#
|
2687
|
+
# @return [Types::GetLogAnomalyDetectorResponse] Returns a {Seahorse::Client::Response response} object which responds to the following methods:
|
2688
|
+
#
|
2689
|
+
# * {Types::GetLogAnomalyDetectorResponse#detector_name #detector_name} => String
|
2690
|
+
# * {Types::GetLogAnomalyDetectorResponse#log_group_arn_list #log_group_arn_list} => Array<String>
|
2691
|
+
# * {Types::GetLogAnomalyDetectorResponse#evaluation_frequency #evaluation_frequency} => String
|
2692
|
+
# * {Types::GetLogAnomalyDetectorResponse#filter_pattern #filter_pattern} => String
|
2693
|
+
# * {Types::GetLogAnomalyDetectorResponse#anomaly_detector_status #anomaly_detector_status} => String
|
2694
|
+
# * {Types::GetLogAnomalyDetectorResponse#kms_key_id #kms_key_id} => String
|
2695
|
+
# * {Types::GetLogAnomalyDetectorResponse#creation_time_stamp #creation_time_stamp} => Integer
|
2696
|
+
# * {Types::GetLogAnomalyDetectorResponse#last_modified_time_stamp #last_modified_time_stamp} => Integer
|
2697
|
+
# * {Types::GetLogAnomalyDetectorResponse#anomaly_visibility_time #anomaly_visibility_time} => Integer
|
2698
|
+
#
|
2699
|
+
# @example Request syntax with placeholder values
|
2700
|
+
#
|
2701
|
+
# resp = client.get_log_anomaly_detector({
|
2702
|
+
# anomaly_detector_arn: "AnomalyDetectorArn", # required
|
2703
|
+
# })
|
2704
|
+
#
|
2705
|
+
# @example Response structure
|
2706
|
+
#
|
2707
|
+
# resp.detector_name #=> String
|
2708
|
+
# resp.log_group_arn_list #=> Array
|
2709
|
+
# resp.log_group_arn_list[0] #=> String
|
2710
|
+
# resp.evaluation_frequency #=> String, one of "ONE_MIN", "FIVE_MIN", "TEN_MIN", "FIFTEEN_MIN", "THIRTY_MIN", "ONE_HOUR"
|
2711
|
+
# resp.filter_pattern #=> String
|
2712
|
+
# resp.anomaly_detector_status #=> String, one of "INITIALIZING", "TRAINING", "ANALYZING", "FAILED", "DELETED", "PAUSED"
|
2713
|
+
# resp.kms_key_id #=> String
|
2714
|
+
# resp.creation_time_stamp #=> Integer
|
2715
|
+
# resp.last_modified_time_stamp #=> Integer
|
2716
|
+
# resp.anomaly_visibility_time #=> Integer
|
2717
|
+
#
|
2718
|
+
# @see http://docs.aws.amazon.com/goto/WebAPI/logs-2014-03-28/GetLogAnomalyDetector AWS API Documentation
|
2719
|
+
#
|
2720
|
+
# @overload get_log_anomaly_detector(params = {})
|
2721
|
+
# @param [Hash] params ({})
|
2722
|
+
def get_log_anomaly_detector(params = {}, options = {})
|
2723
|
+
req = build_request(:get_log_anomaly_detector, params)
|
2724
|
+
req.send_request(options)
|
2725
|
+
end
|
2726
|
+
|
2485
2727
|
# Lists log events from the specified log stream. You can list all of
|
2486
2728
|
# the log events or filter using a time range.
|
2487
2729
|
#
|
@@ -2793,6 +3035,137 @@ module Aws::CloudWatchLogs
|
|
2793
3035
|
req.send_request(options)
|
2794
3036
|
end
|
2795
3037
|
|
3038
|
+
# Returns a list of anomalies that log anomaly detectors have found. For
|
3039
|
+
# details about the structure format of each anomaly object that is
|
3040
|
+
# returned, see the example in this section.
|
3041
|
+
#
|
3042
|
+
# @option params [String] :anomaly_detector_arn
|
3043
|
+
# Use this to optionally limit the results to only the anomalies found
|
3044
|
+
# by a certain anomaly detector.
|
3045
|
+
#
|
3046
|
+
# @option params [String] :suppression_state
|
3047
|
+
# You can specify this parameter if you want to the operation to return
|
3048
|
+
# only anomalies that are currently either suppressed or unsuppressed.
|
3049
|
+
#
|
3050
|
+
# @option params [Integer] :limit
|
3051
|
+
# The maximum number of items to return. If you don't specify a value,
|
3052
|
+
# the default maximum value of 50 items is used.
|
3053
|
+
#
|
3054
|
+
# @option params [String] :next_token
|
3055
|
+
# The token for the next set of items to return. The token expires after
|
3056
|
+
# 24 hours.
|
3057
|
+
#
|
3058
|
+
# @return [Types::ListAnomaliesResponse] Returns a {Seahorse::Client::Response response} object which responds to the following methods:
|
3059
|
+
#
|
3060
|
+
# * {Types::ListAnomaliesResponse#anomalies #anomalies} => Array<Types::Anomaly>
|
3061
|
+
# * {Types::ListAnomaliesResponse#next_token #next_token} => String
|
3062
|
+
#
|
3063
|
+
# The returned {Seahorse::Client::Response response} is a pageable response and is Enumerable. For details on usage see {Aws::PageableResponse PageableResponse}.
|
3064
|
+
#
|
3065
|
+
# @example Request syntax with placeholder values
|
3066
|
+
#
|
3067
|
+
# resp = client.list_anomalies({
|
3068
|
+
# anomaly_detector_arn: "AnomalyDetectorArn",
|
3069
|
+
# suppression_state: "SUPPRESSED", # accepts SUPPRESSED, UNSUPPRESSED
|
3070
|
+
# limit: 1,
|
3071
|
+
# next_token: "NextToken",
|
3072
|
+
# })
|
3073
|
+
#
|
3074
|
+
# @example Response structure
|
3075
|
+
#
|
3076
|
+
# resp.anomalies #=> Array
|
3077
|
+
# resp.anomalies[0].anomaly_id #=> String
|
3078
|
+
# resp.anomalies[0].pattern_id #=> String
|
3079
|
+
# resp.anomalies[0].anomaly_detector_arn #=> String
|
3080
|
+
# resp.anomalies[0].pattern_string #=> String
|
3081
|
+
# resp.anomalies[0].pattern_regex #=> String
|
3082
|
+
# resp.anomalies[0].priority #=> String
|
3083
|
+
# resp.anomalies[0].first_seen #=> Integer
|
3084
|
+
# resp.anomalies[0].last_seen #=> Integer
|
3085
|
+
# resp.anomalies[0].description #=> String
|
3086
|
+
# resp.anomalies[0].active #=> Boolean
|
3087
|
+
# resp.anomalies[0].state #=> String, one of "Active", "Suppressed", "Baseline"
|
3088
|
+
# resp.anomalies[0].histogram #=> Hash
|
3089
|
+
# resp.anomalies[0].histogram["Time"] #=> Integer
|
3090
|
+
# resp.anomalies[0].log_samples #=> Array
|
3091
|
+
# resp.anomalies[0].log_samples[0] #=> String
|
3092
|
+
# resp.anomalies[0].pattern_tokens #=> Array
|
3093
|
+
# resp.anomalies[0].pattern_tokens[0].dynamic_token_position #=> Integer
|
3094
|
+
# resp.anomalies[0].pattern_tokens[0].is_dynamic #=> Boolean
|
3095
|
+
# resp.anomalies[0].pattern_tokens[0].token_string #=> String
|
3096
|
+
# resp.anomalies[0].pattern_tokens[0].enumerations #=> Hash
|
3097
|
+
# resp.anomalies[0].pattern_tokens[0].enumerations["TokenString"] #=> Integer
|
3098
|
+
# resp.anomalies[0].log_group_arn_list #=> Array
|
3099
|
+
# resp.anomalies[0].log_group_arn_list[0] #=> String
|
3100
|
+
# resp.anomalies[0].suppressed #=> Boolean
|
3101
|
+
# resp.anomalies[0].suppressed_date #=> Integer
|
3102
|
+
# resp.anomalies[0].suppressed_until #=> Integer
|
3103
|
+
# resp.anomalies[0].is_pattern_level_suppression #=> Boolean
|
3104
|
+
# resp.next_token #=> String
|
3105
|
+
#
|
3106
|
+
# @see http://docs.aws.amazon.com/goto/WebAPI/logs-2014-03-28/ListAnomalies AWS API Documentation
|
3107
|
+
#
|
3108
|
+
# @overload list_anomalies(params = {})
|
3109
|
+
# @param [Hash] params ({})
|
3110
|
+
def list_anomalies(params = {}, options = {})
|
3111
|
+
req = build_request(:list_anomalies, params)
|
3112
|
+
req.send_request(options)
|
3113
|
+
end
|
3114
|
+
|
3115
|
+
# Retrieves a list of the log anomaly detectors in the account.
|
3116
|
+
#
|
3117
|
+
# @option params [String] :filter_log_group_arn
|
3118
|
+
# Use this to optionally filter the results to only include anomaly
|
3119
|
+
# detectors that are associated with the specified log group.
|
3120
|
+
#
|
3121
|
+
# @option params [Integer] :limit
|
3122
|
+
# The maximum number of items to return. If you don't specify a value,
|
3123
|
+
# the default maximum value of 50 items is used.
|
3124
|
+
#
|
3125
|
+
# @option params [String] :next_token
|
3126
|
+
# The token for the next set of items to return. The token expires after
|
3127
|
+
# 24 hours.
|
3128
|
+
#
|
3129
|
+
# @return [Types::ListLogAnomalyDetectorsResponse] Returns a {Seahorse::Client::Response response} object which responds to the following methods:
|
3130
|
+
#
|
3131
|
+
# * {Types::ListLogAnomalyDetectorsResponse#anomaly_detectors #anomaly_detectors} => Array<Types::AnomalyDetector>
|
3132
|
+
# * {Types::ListLogAnomalyDetectorsResponse#next_token #next_token} => String
|
3133
|
+
#
|
3134
|
+
# The returned {Seahorse::Client::Response response} is a pageable response and is Enumerable. For details on usage see {Aws::PageableResponse PageableResponse}.
|
3135
|
+
#
|
3136
|
+
# @example Request syntax with placeholder values
|
3137
|
+
#
|
3138
|
+
# resp = client.list_log_anomaly_detectors({
|
3139
|
+
# filter_log_group_arn: "LogGroupArn",
|
3140
|
+
# limit: 1,
|
3141
|
+
# next_token: "NextToken",
|
3142
|
+
# })
|
3143
|
+
#
|
3144
|
+
# @example Response structure
|
3145
|
+
#
|
3146
|
+
# resp.anomaly_detectors #=> Array
|
3147
|
+
# resp.anomaly_detectors[0].anomaly_detector_arn #=> String
|
3148
|
+
# resp.anomaly_detectors[0].detector_name #=> String
|
3149
|
+
# resp.anomaly_detectors[0].log_group_arn_list #=> Array
|
3150
|
+
# resp.anomaly_detectors[0].log_group_arn_list[0] #=> String
|
3151
|
+
# resp.anomaly_detectors[0].evaluation_frequency #=> String, one of "ONE_MIN", "FIVE_MIN", "TEN_MIN", "FIFTEEN_MIN", "THIRTY_MIN", "ONE_HOUR"
|
3152
|
+
# resp.anomaly_detectors[0].filter_pattern #=> String
|
3153
|
+
# resp.anomaly_detectors[0].anomaly_detector_status #=> String, one of "INITIALIZING", "TRAINING", "ANALYZING", "FAILED", "DELETED", "PAUSED"
|
3154
|
+
# resp.anomaly_detectors[0].kms_key_id #=> String
|
3155
|
+
# resp.anomaly_detectors[0].creation_time_stamp #=> Integer
|
3156
|
+
# resp.anomaly_detectors[0].last_modified_time_stamp #=> Integer
|
3157
|
+
# resp.anomaly_detectors[0].anomaly_visibility_time #=> Integer
|
3158
|
+
# resp.next_token #=> String
|
3159
|
+
#
|
3160
|
+
# @see http://docs.aws.amazon.com/goto/WebAPI/logs-2014-03-28/ListLogAnomalyDetectors AWS API Documentation
|
3161
|
+
#
|
3162
|
+
# @overload list_log_anomaly_detectors(params = {})
|
3163
|
+
# @param [Hash] params ({})
|
3164
|
+
def list_log_anomaly_detectors(params = {}, options = {})
|
3165
|
+
req = build_request(:list_log_anomaly_detectors, params)
|
3166
|
+
req.send_request(options)
|
3167
|
+
end
|
3168
|
+
|
2796
3169
|
# Displays the tags associated with a CloudWatch Logs resource.
|
2797
3170
|
# Currently, log groups and destinations support tagging.
|
2798
3171
|
#
|
@@ -3161,7 +3534,7 @@ module Aws::CloudWatchLogs
|
|
3161
3534
|
# [1]: https://docs.aws.amazon.com/AmazonCloudWatchLogs/latest/APIReference/API_PutDeliverySource.html
|
3162
3535
|
# [2]: https://docs.aws.amazon.com/AmazonCloudWatchLogs/latest/APIReference/API_PutDeliveryDestinationolicy.html
|
3163
3536
|
# [3]: https://docs.aws.amazon.com/AmazonCloudWatchLogs/latest/APIReference/API_CreateDelivery.html
|
3164
|
-
# [4]: https://docs.aws.amazon.com/
|
3537
|
+
# [4]: https://docs.aws.amazon.com/AmazonCloudWatch/latest/logs/AWS-logs-and-resource-policy.html
|
3165
3538
|
#
|
3166
3539
|
# @option params [required, String] :name
|
3167
3540
|
# A name for this delivery destination. This name must be unique for all
|
@@ -3255,7 +3628,7 @@ module Aws::CloudWatchLogs
|
|
3255
3628
|
# [1]: https://docs.aws.amazon.com/AmazonCloudWatchLogs/latest/APIReference/API_PutDeliverySource.html
|
3256
3629
|
# [2]: https://docs.aws.amazon.com/AmazonCloudWatchLogs/latest/APIReference/API_PutDeliveryDestination.html
|
3257
3630
|
# [3]: https://docs.aws.amazon.com/AmazonCloudWatchLogs/latest/APIReference/API_CreateDelivery.html
|
3258
|
-
# [4]: https://docs.aws.amazon.com/
|
3631
|
+
# [4]: https://docs.aws.amazon.com/AmazonCloudWatch/latest/logs/AWS-logs-and-resource-policy.html
|
3259
3632
|
#
|
3260
3633
|
# @option params [required, String] :delivery_destination_name
|
3261
3634
|
# The name of the delivery destination to assign this policy to.
|
@@ -3332,7 +3705,7 @@ module Aws::CloudWatchLogs
|
|
3332
3705
|
# [1]: https://docs.aws.amazon.com/AmazonCloudWatchLogs/latest/APIReference/API_PutDeliveryDestination.html
|
3333
3706
|
# [2]: https://docs.aws.amazon.com/AmazonCloudWatchLogs/latest/APIReference/API_PutDeliveryDestinationolicy.html
|
3334
3707
|
# [3]: https://docs.aws.amazon.com/AmazonCloudWatchLogs/latest/APIReference/API_CreateDelivery.html
|
3335
|
-
# [4]: https://docs.aws.amazon.com/
|
3708
|
+
# [4]: https://docs.aws.amazon.com/AmazonCloudWatch/latest/logs/AWS-logs-and-resource-policy.html
|
3336
3709
|
#
|
3337
3710
|
# @option params [required, String] :name
|
3338
3711
|
# A name for this delivery source. This name must be unique for all
|
@@ -4406,6 +4779,126 @@ module Aws::CloudWatchLogs
|
|
4406
4779
|
req.send_request(options)
|
4407
4780
|
end
|
4408
4781
|
|
4782
|
+
# Use this operation to *suppress* anomaly detection for a specified
|
4783
|
+
# anomaly or pattern. If you suppress an anomaly, CloudWatch Logs won’t
|
4784
|
+
# report new occurrences of that anomaly and won't update that anomaly
|
4785
|
+
# with new data. If you suppress a pattern, CloudWatch Logs won’t report
|
4786
|
+
# any anomalies related to that pattern.
|
4787
|
+
#
|
4788
|
+
# You must specify either `anomalyId` or `patternId`, but you can't
|
4789
|
+
# specify both parameters in the same operation.
|
4790
|
+
#
|
4791
|
+
# If you have previously used this operation to suppress detection of a
|
4792
|
+
# pattern or anomaly, you can use it again to cause CloudWatch Logs to
|
4793
|
+
# end the suppression. To do this, use this operation and specify the
|
4794
|
+
# anomaly or pattern to stop suppressing, and omit the `suppressionType`
|
4795
|
+
# and `suppressionPeriod` parameters.
|
4796
|
+
#
|
4797
|
+
# @option params [String] :anomaly_id
|
4798
|
+
# If you are suppressing or unsuppressing an anomaly, specify its unique
|
4799
|
+
# ID here. You can find anomaly IDs by using the [ListAnomalies][1]
|
4800
|
+
# operation.
|
4801
|
+
#
|
4802
|
+
#
|
4803
|
+
#
|
4804
|
+
# [1]: https://docs.aws.amazon.com/AmazonCloudWatchLogs/latest/APIReference/API_ListAnomalies.html
|
4805
|
+
#
|
4806
|
+
# @option params [String] :pattern_id
|
4807
|
+
# If you are suppressing or unsuppressing an pattern, specify its unique
|
4808
|
+
# ID here. You can find pattern IDs by using the [ListAnomalies][1]
|
4809
|
+
# operation.
|
4810
|
+
#
|
4811
|
+
#
|
4812
|
+
#
|
4813
|
+
# [1]: https://docs.aws.amazon.com/AmazonCloudWatchLogs/latest/APIReference/API_ListAnomalies.html
|
4814
|
+
#
|
4815
|
+
# @option params [required, String] :anomaly_detector_arn
|
4816
|
+
# The ARN of the anomaly detector that this operation is to act on.
|
4817
|
+
#
|
4818
|
+
# @option params [String] :suppression_type
|
4819
|
+
# Use this to specify whether the suppression to be temporary or
|
4820
|
+
# infinite. If you specify `LIMITED`, you must also specify a
|
4821
|
+
# `suppressionPeriod`. If you specify `INFINITE`, any value for
|
4822
|
+
# `suppressionPeriod` is ignored.
|
4823
|
+
#
|
4824
|
+
# @option params [Types::SuppressionPeriod] :suppression_period
|
4825
|
+
# If you are temporarily suppressing an anomaly or pattern, use this
|
4826
|
+
# structure to specify how long the suppression is to last.
|
4827
|
+
#
|
4828
|
+
# @return [Struct] Returns an empty {Seahorse::Client::Response response}.
|
4829
|
+
#
|
4830
|
+
# @example Request syntax with placeholder values
|
4831
|
+
#
|
4832
|
+
# resp = client.update_anomaly({
|
4833
|
+
# anomaly_id: "AnomalyId",
|
4834
|
+
# pattern_id: "PatternId",
|
4835
|
+
# anomaly_detector_arn: "AnomalyDetectorArn", # required
|
4836
|
+
# suppression_type: "LIMITED", # accepts LIMITED, INFINITE
|
4837
|
+
# suppression_period: {
|
4838
|
+
# value: 1,
|
4839
|
+
# suppression_unit: "SECONDS", # accepts SECONDS, MINUTES, HOURS
|
4840
|
+
# },
|
4841
|
+
# })
|
4842
|
+
#
|
4843
|
+
# @see http://docs.aws.amazon.com/goto/WebAPI/logs-2014-03-28/UpdateAnomaly AWS API Documentation
|
4844
|
+
#
|
4845
|
+
# @overload update_anomaly(params = {})
|
4846
|
+
# @param [Hash] params ({})
|
4847
|
+
def update_anomaly(params = {}, options = {})
|
4848
|
+
req = build_request(:update_anomaly, params)
|
4849
|
+
req.send_request(options)
|
4850
|
+
end
|
4851
|
+
|
4852
|
+
# Updates an existing log anomaly detector.
|
4853
|
+
#
|
4854
|
+
# @option params [required, String] :anomaly_detector_arn
|
4855
|
+
# The ARN of the anomaly detector that you want to update.
|
4856
|
+
#
|
4857
|
+
# @option params [String] :evaluation_frequency
|
4858
|
+
# Specifies how often the anomaly detector runs and look for anomalies.
|
4859
|
+
# Set this value according to the frequency that the log group receives
|
4860
|
+
# new logs. For example, if the log group receives new log events every
|
4861
|
+
# 10 minutes, then setting `evaluationFrequency` to `FIFTEEN_MIN` might
|
4862
|
+
# be appropriate.
|
4863
|
+
#
|
4864
|
+
# @option params [String] :filter_pattern
|
4865
|
+
# A symbolic description of how CloudWatch Logs should interpret the
|
4866
|
+
# data in each log event. For example, a log event can contain
|
4867
|
+
# timestamps, IP addresses, strings, and so on. You use the filter
|
4868
|
+
# pattern to specify what to look for in the log event message.
|
4869
|
+
#
|
4870
|
+
# @option params [Integer] :anomaly_visibility_time
|
4871
|
+
# The number of days to use as the life cycle of anomalies. After this
|
4872
|
+
# time, anomalies are automatically baselined and the anomaly detector
|
4873
|
+
# model will treat new occurrences of similar event as normal.
|
4874
|
+
# Therefore, if you do not correct the cause of an anomaly during this
|
4875
|
+
# time, it will be considered normal going forward and will not be
|
4876
|
+
# detected.
|
4877
|
+
#
|
4878
|
+
# @option params [required, Boolean] :enabled
|
4879
|
+
# Use this parameter to pause or restart the anomaly detector.
|
4880
|
+
#
|
4881
|
+
# @return [Struct] Returns an empty {Seahorse::Client::Response response}.
|
4882
|
+
#
|
4883
|
+
# @example Request syntax with placeholder values
|
4884
|
+
#
|
4885
|
+
# resp = client.update_log_anomaly_detector({
|
4886
|
+
# anomaly_detector_arn: "AnomalyDetectorArn", # required
|
4887
|
+
# evaluation_frequency: "ONE_MIN", # accepts ONE_MIN, FIVE_MIN, TEN_MIN, FIFTEEN_MIN, THIRTY_MIN, ONE_HOUR
|
4888
|
+
# filter_pattern: "FilterPattern",
|
4889
|
+
# anomaly_visibility_time: 1,
|
4890
|
+
# enabled: false, # required
|
4891
|
+
# })
|
4892
|
+
#
|
4893
|
+
# @see http://docs.aws.amazon.com/goto/WebAPI/logs-2014-03-28/UpdateLogAnomalyDetector AWS API Documentation
|
4894
|
+
#
|
4895
|
+
# @overload update_log_anomaly_detector(params = {})
|
4896
|
+
# @param [Hash] params ({})
|
4897
|
+
def update_log_anomaly_detector(params = {}, options = {})
|
4898
|
+
req = build_request(:update_log_anomaly_detector, params)
|
4899
|
+
req.send_request(options)
|
4900
|
+
end
|
4901
|
+
|
4409
4902
|
# @!endgroup
|
4410
4903
|
|
4411
4904
|
# @param params ({})
|
@@ -4419,7 +4912,7 @@ module Aws::CloudWatchLogs
|
|
4419
4912
|
params: params,
|
4420
4913
|
config: config)
|
4421
4914
|
context[:gem_name] = 'aws-sdk-cloudwatchlogs'
|
4422
|
-
context[:gem_version] = '1.
|
4915
|
+
context[:gem_version] = '1.75.0'
|
4423
4916
|
Seahorse::Client::Request.new(handlers, context)
|
4424
4917
|
end
|
4425
4918
|
|