Skip to content

Commit 4723f34

Browse files
author
awstools
committed
feat(client-cloudwatch-logs): This release introduces a new optional parameter: Entity, in PutLogEvents request
1 parent a30b03e commit 4723f34

File tree

8 files changed

+275
-19
lines changed

8 files changed

+275
-19
lines changed

clients/client-cloudwatch-logs/src/commands/PutAccountPolicyCommand.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -85,7 +85,7 @@ export interface PutAccountPolicyCommandOutput extends PutAccountPolicyResponse,
8585
* delivery. Kinesis Data Streams and Firehose are supported as logical destinations.</p>
8686
* </li>
8787
* </ul>
88-
* <p>Each account can have one account-level subscription filter policy.
88+
* <p>Each account can have one account-level subscription filter policy per Region.
8989
* If you are updating an existing filter, you must specify the correct name in <code>PolicyName</code>.
9090
* To perform a <code>PutAccountPolicy</code> subscription filter operation for any destination except a Lambda
9191
* function, you must also have the <code>iam:PassRole</code> permission.</p>

clients/client-cloudwatch-logs/src/commands/PutLogEventsCommand.ts

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -93,6 +93,14 @@ export interface PutLogEventsCommandOutput extends PutLogEventsResponse, __Metad
9393
* },
9494
* ],
9595
* sequenceToken: "STRING_VALUE",
96+
* entity: { // Entity
97+
* keyAttributes: { // EntityKeyAttributes
98+
* "<keys>": "STRING_VALUE",
99+
* },
100+
* attributes: { // EntityAttributes
101+
* "<keys>": "STRING_VALUE",
102+
* },
103+
* },
96104
* };
97105
* const command = new PutLogEventsCommand(input);
98106
* const response = await client.send(command);
@@ -103,6 +111,9 @@ export interface PutLogEventsCommandOutput extends PutLogEventsResponse, __Metad
103111
* // tooOldLogEventEndIndex: Number("int"),
104112
* // expiredLogEventEndIndex: Number("int"),
105113
* // },
114+
* // rejectedEntityInfo: { // RejectedEntityInfo
115+
* // errorType: "InvalidEntity" || "InvalidTypeValue" || "InvalidKeyAttributes" || "InvalidAttributes" || "EntitySizeTooLarge" || "UnsupportedLogGroupType" || "MissingRequiredFields", // required
116+
* // },
106117
* // };
107118
*
108119
* ```

clients/client-cloudwatch-logs/src/commands/PutMetricFilterCommand.ts

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -33,6 +33,12 @@ export interface PutMetricFilterCommandOutput extends __MetadataBearer {}
3333
* through <a href="https://docs.aws.amazon.com/AmazonCloudWatchLogs/latest/APIReference/API_PutLogEvents.html">PutLogEvents</a>.</p>
3434
* <p>The maximum number of metric filters that can be associated with a log group is
3535
* 100.</p>
36+
* <p>Using regular expressions to create metric filters is supported. For these filters,
37+
* there is a quotas of quota of two regular expression patterns within a single filter pattern. There
38+
* is also a quota of five regular expression patterns per log group.
39+
* For more information about using regular expressions in metric filters,
40+
* see <a href="https://docs.aws.amazon.com/AmazonCloudWatch/latest/logs/FilterAndPatternSyntax.html">
41+
* Filter pattern syntax for metric filters, subscription filters, filter log events, and Live Tail</a>.</p>
3642
* <p>When you create a metric filter, you can also optionally assign a unit and dimensions
3743
* to the metric that is created.</p>
3844
* <important>

clients/client-cloudwatch-logs/src/commands/PutSubscriptionFilterCommand.ts

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -55,6 +55,12 @@ export interface PutSubscriptionFilterCommandOutput extends __MetadataBearer {}
5555
* <p>Each log group can have up to two subscription filters associated with it. If you are
5656
* updating an existing filter, you must specify the correct name in <code>filterName</code>.
5757
* </p>
58+
* <p>Using regular expressions to create subscription filters is supported. For these filters,
59+
* there is a quotas of quota of two regular expression patterns within a single filter pattern. There
60+
* is also a quota of five regular expression patterns per log group.
61+
* For more information about using regular expressions in subscription filters,
62+
* see <a href="https://docs.aws.amazon.com/AmazonCloudWatch/latest/logs/FilterAndPatternSyntax.html">
63+
* Filter pattern syntax for metric filters, subscription filters, filter log events, and Live Tail</a>.</p>
5864
* <p>To perform a <code>PutSubscriptionFilter</code> operation for any destination except a Lambda function,
5965
* you must also have the
6066
* <code>iam:PassRole</code> permission.</p>

clients/client-cloudwatch-logs/src/commands/StartLiveTailCommand.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -58,11 +58,11 @@ export interface StartLiveTailCommandOutput extends StartLiveTailResponse, __Met
5858
* which it starts dropping the oldest events.</p>
5959
* </li>
6060
* <li>
61-
* <p>A <a href="https://docs.aws.amazon.com/AmazonCloudWatchLogs/latest/APIReference/API_SessionStreamingException.html">SessionStreamingException</a>
61+
* <p>A <a href="https://docs.aws.amazon.com/AmazonCloudWatchLogs/latest/APIReference/API_StartLiveTailResponseStream.html#CWL-Type-StartLiveTailResponseStream-SessionStreamingException">SessionStreamingException</a>
6262
* object is returned if an unknown error occurs on the server side.</p>
6363
* </li>
6464
* <li>
65-
* <p>A <a href="https://docs.aws.amazon.com/AmazonCloudWatchLogs/latest/APIReference/API_SessionTimeoutException.html">SessionTimeoutException</a>
65+
* <p>A <a href="https://docs.aws.amazon.com/AmazonCloudWatchLogs/latest/APIReference/API_StartLiveTailResponseStream.html#CWL-Type-StartLiveTailResponseStream-SessionTimeoutException">SessionTimeoutException</a>
6666
* object is returned when the session times out, after it has been kept open for three hours.</p>
6767
* </li>
6868
* </ul>

clients/client-cloudwatch-logs/src/models/models_0.ts

Lines changed: 71 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -119,7 +119,7 @@ export interface LogEvent {
119119
}
120120

121121
/**
122-
* <p>A tructures that contains information about one pattern token related to
122+
* <p>A structure that contains information about one pattern token related to
123123
* an anomaly.</p>
124124
* <p>For more information about patterns and tokens, see <a href="https://docs.aws.amazon.com/AmazonCloudWatchLogs/latest/APIReference/API_CreateLogAnomalyDetector.html">CreateLogAnomalyDetector</a>.
125125
* </p>
@@ -2844,6 +2844,43 @@ export interface DisassociateKmsKeyRequest {
28442844
resourceIdentifier?: string;
28452845
}
28462846

2847+
/**
2848+
* <p>Reserved for future use.</p>
2849+
* @public
2850+
*/
2851+
export interface Entity {
2852+
/**
2853+
* <p>Reserved for future use.</p>
2854+
* @public
2855+
*/
2856+
keyAttributes?: Record<string, string>;
2857+
2858+
/**
2859+
* <p>Reserved for future use.</p>
2860+
* @public
2861+
*/
2862+
attributes?: Record<string, string>;
2863+
}
2864+
2865+
/**
2866+
* @public
2867+
* @enum
2868+
*/
2869+
export const EntityRejectionErrorType = {
2870+
ENTITY_SIZE_TOO_LARGE: "EntitySizeTooLarge",
2871+
INVALID_ATTRIBUTES: "InvalidAttributes",
2872+
INVALID_ENTITY: "InvalidEntity",
2873+
INVALID_KEY_ATTRIBUTE: "InvalidKeyAttributes",
2874+
INVALID_TYPE_VALUE: "InvalidTypeValue",
2875+
MISSING_REQUIRED_FIELDS: "MissingRequiredFields",
2876+
UNSUPPORTED_LOG_GROUP_TYPE: "UnsupportedLogGroupType",
2877+
} as const;
2878+
2879+
/**
2880+
* @public
2881+
*/
2882+
export type EntityRejectionErrorType = (typeof EntityRejectionErrorType)[keyof typeof EntityRejectionErrorType];
2883+
28472884
/**
28482885
* <p>Represents a matched event.</p>
28492886
* @public
@@ -2913,17 +2950,16 @@ export interface FilterLogEventsRequest {
29132950

29142951
/**
29152952
* <p>Filters the results to only logs from the log streams in this list.</p>
2916-
* <p>If you specify a value for both <code>logStreamNamePrefix</code> and <code>logStreamNames</code>, the action
2953+
* <p>If you specify a value for both <code>logStreamNames</code> and <code>logStreamNamePrefix</code>, the action
29172954
* returns an <code>InvalidParameterException</code> error.</p>
29182955
* @public
29192956
*/
29202957
logStreamNames?: string[];
29212958

29222959
/**
29232960
* <p>Filters the results to include only events from log streams that have names starting with this prefix.</p>
2924-
* <p>If you specify a value for both <code>logStreamNamePrefix</code> and <code>logStreamNames</code>, but the value for
2925-
* <code>logStreamNamePrefix</code> does not match any log stream names specified in <code>logStreamNames</code>, the action
2926-
* returns an <code>InvalidParameterException</code> error.</p>
2961+
* <p>If you specify a value for both <code>logStreamNamePrefix</code> and <code>logStreamNames</code>, the action
2962+
* returns an <code>InvalidParameterException</code> error.</p>
29272963
* @public
29282964
*/
29292965
logStreamNamePrefix?: string;
@@ -4008,7 +4044,7 @@ export interface PutAccountPolicyRequest {
40084044
* </li>
40094045
* <li>
40104046
* <p>
4011-
* <b>Distribution</b>The method used to distribute log data to the destination.
4047+
* <b>Distribution</b> The method used to distribute log data to the destination.
40124048
* By default, log data is
40134049
* grouped by log stream, but the grouping can be set to <code>Random</code> for a more even distribution.
40144050
* This property is only applicable when the destination is an Kinesis Data Streams data stream.</p>
@@ -4222,11 +4258,15 @@ export interface PutDeliverySourceRequest {
42224258
* <p>Defines the type of log that the source is sending.</p>
42234259
* <ul>
42244260
* <li>
4261+
* <p>For Amazon Bedrock, the valid value is
4262+
* <code>APPLICATION_LOGS</code>.</p>
4263+
* </li>
4264+
* <li>
42254265
* <p>For Amazon CodeWhisperer, the valid value is
42264266
* <code>EVENT_LOGS</code>.</p>
42274267
* </li>
42284268
* <li>
4229-
* <p>For IAM Identity Centerr, the valid value is
4269+
* <p>For IAM Identity Center, the valid value is
42304270
* <code>ERROR_LOGS</code>.</p>
42314271
* </li>
42324272
* <li>
@@ -4371,6 +4411,24 @@ export interface PutLogEventsRequest {
43714411
* @public
43724412
*/
43734413
sequenceToken?: string;
4414+
4415+
/**
4416+
* <p>Reserved for future use.</p>
4417+
* @public
4418+
*/
4419+
entity?: Entity;
4420+
}
4421+
4422+
/**
4423+
* <p>Reserved for future use.</p>
4424+
* @public
4425+
*/
4426+
export interface RejectedEntityInfo {
4427+
/**
4428+
* <p>Reserved for future use.</p>
4429+
* @public
4430+
*/
4431+
errorType: EntityRejectionErrorType | undefined;
43744432
}
43754433

43764434
/**
@@ -4421,6 +4479,12 @@ export interface PutLogEventsResponse {
44214479
* @public
44224480
*/
44234481
rejectedLogEventsInfo?: RejectedLogEventsInfo;
4482+
4483+
/**
4484+
* <p>Reserved for future use.</p>
4485+
* @public
4486+
*/
4487+
rejectedEntityInfo?: RejectedEntityInfo;
44244488
}
44254489

44264490
/**

clients/client-cloudwatch-logs/src/protocols/Aws_json1_1.ts

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -238,6 +238,7 @@ import {
238238
DescribeResourcePoliciesRequest,
239239
DescribeSubscriptionFiltersRequest,
240240
DisassociateKmsKeyRequest,
241+
Entity,
241242
FilterLogEventsRequest,
242243
GetDataProtectionPolicyRequest,
243244
GetDeliveryDestinationPolicyRequest,
@@ -3173,6 +3174,12 @@ const de_SessionTimeoutExceptionRes = async (
31733174

31743175
// se_DisassociateKmsKeyRequest omitted.
31753176

3177+
// se_Entity omitted.
3178+
3179+
// se_EntityAttributes omitted.
3180+
3181+
// se_EntityKeyAttributes omitted.
3182+
31763183
// se_FilterLogEventsRequest omitted.
31773184

31783185
// se_GetDataProtectionPolicyRequest omitted.
@@ -3613,6 +3620,8 @@ const de_QueryStatistics = (output: any, context: __SerdeContext): QueryStatisti
36133620
}) as any;
36143621
};
36153622

3623+
// de_RejectedEntityInfo omitted.
3624+
36163625
// de_RejectedLogEventsInfo omitted.
36173626

36183627
// de_ResourceAlreadyExistsException omitted.

0 commit comments

Comments
 (0)