From da1de11cd3cef9866ad0d7e9a06bf3c5473908f4 Mon Sep 17 00:00:00 2001 From: awstools Date: Tue, 29 Oct 2024 18:58:00 +0000 Subject: [PATCH] feat(client-cloudwatch-logs): Added support for new optional baseline parameter in the UpdateAnomaly API. For UpdateAnomaly requests with baseline set to True, The anomaly behavior is then treated as baseline behavior. However, more severe occurrences of this behavior will still be reported as anomalies. --- .../src/commands/UpdateAnomalyCommand.ts | 1 + clients/client-cloudwatch-logs/src/models/models_0.ts | 10 ++++++++++ codegen/sdk-codegen/aws-models/cloudwatch-logs.json | 9 +++++++++ 3 files changed, 20 insertions(+) diff --git a/clients/client-cloudwatch-logs/src/commands/UpdateAnomalyCommand.ts b/clients/client-cloudwatch-logs/src/commands/UpdateAnomalyCommand.ts index ee7991ad2e371..ee0519da5521e 100644 --- a/clients/client-cloudwatch-logs/src/commands/UpdateAnomalyCommand.ts +++ b/clients/client-cloudwatch-logs/src/commands/UpdateAnomalyCommand.ts @@ -52,6 +52,7 @@ export interface UpdateAnomalyCommandOutput extends __MetadataBearer {} * value: Number("int"), * suppressionUnit: "SECONDS" || "MINUTES" || "HOURS", * }, + * baseline: true || false, * }; * const command = new UpdateAnomalyCommand(input); * const response = await client.send(command); diff --git a/clients/client-cloudwatch-logs/src/models/models_0.ts b/clients/client-cloudwatch-logs/src/models/models_0.ts index e01b5ca2740c9..380b77fada10c 100644 --- a/clients/client-cloudwatch-logs/src/models/models_0.ts +++ b/clients/client-cloudwatch-logs/src/models/models_0.ts @@ -5633,6 +5633,16 @@ export interface UpdateAnomalyRequest { * @public */ suppressionPeriod?: SuppressionPeriod; + + /** + *

Set this to true to prevent CloudWatch Logs from displaying this behavior as an anomaly in the future. The behavior is then treated as + * baseline behavior. However, if similar but + * more severe occurrences of this behavior occur in the future, those will still be reported as anomalies.

+ *

The default is false + *

+ * @public + */ + baseline?: boolean; } /** diff --git a/codegen/sdk-codegen/aws-models/cloudwatch-logs.json b/codegen/sdk-codegen/aws-models/cloudwatch-logs.json index 5b28a4597bfca..8710d0e81fb1f 100644 --- a/codegen/sdk-codegen/aws-models/cloudwatch-logs.json +++ b/codegen/sdk-codegen/aws-models/cloudwatch-logs.json @@ -497,6 +497,9 @@ "smithy.api#input": {} } }, + "com.amazonaws.cloudwatchlogs#Baseline": { + "type": "boolean" + }, "com.amazonaws.cloudwatchlogs#Boolean": { "type": "boolean" }, @@ -9872,6 +9875,12 @@ "traits": { "smithy.api#documentation": "

If you are temporarily suppressing an anomaly or pattern, use this structure to specify\n how long the suppression is to last.

" } + }, + "baseline": { + "target": "com.amazonaws.cloudwatchlogs#Baseline", + "traits": { + "smithy.api#documentation": "

Set this to true to prevent CloudWatch Logs from displaying this behavior as an anomaly in the future. The behavior is then treated as \n baseline behavior. However, if similar but \n more severe occurrences of this behavior occur in the future, those will still be reported as anomalies.

\n

The default is false\n

" + } } }, "traits": {