diff --git a/clients/client-lambda/src/commands/DeleteEventSourceMappingCommand.ts b/clients/client-lambda/src/commands/DeleteEventSourceMappingCommand.ts index 6a46aa3a9d58..136f9327f80a 100644 --- a/clients/client-lambda/src/commands/DeleteEventSourceMappingCommand.ts +++ b/clients/client-lambda/src/commands/DeleteEventSourceMappingCommand.ts @@ -132,6 +132,9 @@ export interface DeleteEventSourceMappingCommandOutput extends EventSourceMappin * @throws {@link InvalidParameterValueException} (client fault) *

One of the parameters in the request is not valid.

* + * @throws {@link ResourceConflictException} (client fault) + *

The resource already exists, or another operation is in progress.

+ * * @throws {@link ResourceInUseException} (client fault) *

The operation conflicts with the resource's availability. For example, you tried to update an event source * mapping in the CREATING state, or you tried to delete an event source mapping currently UPDATING.

diff --git a/clients/client-lambda/src/commands/DeleteFunctionCommand.ts b/clients/client-lambda/src/commands/DeleteFunctionCommand.ts index 66b4cca7c8f9..25fe7564afa3 100644 --- a/clients/client-lambda/src/commands/DeleteFunctionCommand.ts +++ b/clients/client-lambda/src/commands/DeleteFunctionCommand.ts @@ -37,7 +37,8 @@ export interface DeleteFunctionCommandOutput extends __MetadataBearer {} /** * @public *

Deletes a Lambda function. To delete a specific function version, use the Qualifier parameter. - * Otherwise, all versions and aliases are deleted.

+ * Otherwise, all versions and aliases are deleted. This doesn't require the user to have explicit + * permissions for DeleteAlias.

*

To delete Lambda event source mappings that invoke a function, use DeleteEventSourceMapping. For Amazon Web Services and resources that invoke your function * directly, delete the trigger in the service where you originally configured it.

* @example diff --git a/clients/client-lambda/src/models/models_0.ts b/clients/client-lambda/src/models/models_0.ts index 707df39dfdae..9e2647350f94 100644 --- a/clients/client-lambda/src/models/models_0.ts +++ b/clients/client-lambda/src/models/models_0.ts @@ -1051,15 +1051,15 @@ export interface CreateEventSourceMappingRequest { ParallelizationFactor?: number; /** - *

The position in a stream from which to start reading. Required for Amazon Kinesis, Amazon - * DynamoDB, and Amazon MSK Streams sources. AT_TIMESTAMP is supported only for - * Amazon Kinesis streams and Amazon DocumentDB.

+ *

The position in a stream from which to start reading. Required for Amazon Kinesis and + * Amazon DynamoDB Stream event sources. AT_TIMESTAMP is supported only for + * Amazon Kinesis streams, Amazon DocumentDB, Amazon MSK, and self-managed Apache Kafka.

*/ StartingPosition?: EventSourcePosition | string; /** *

With StartingPosition set to AT_TIMESTAMP, the time from which to start - * reading.

+ * reading. StartingPositionTimestamp cannot be in the future.

*/ StartingPositionTimestamp?: Date; @@ -1145,14 +1145,15 @@ export interface EventSourceMappingConfiguration { UUID?: string; /** - *

The position in a stream from which to start reading. Required for Amazon Kinesis, Amazon DynamoDB, and Amazon MSK stream sources. AT_TIMESTAMP is supported only for Amazon Kinesis - * streams and Amazon DocumentDB.

+ *

The position in a stream from which to start reading. Required for Amazon Kinesis and + * Amazon DynamoDB Stream event sources. AT_TIMESTAMP is supported only for + * Amazon Kinesis streams, Amazon DocumentDB, Amazon MSK, and self-managed Apache Kafka.

*/ StartingPosition?: EventSourcePosition | string; /** *

With StartingPosition set to AT_TIMESTAMP, the time from which to start - * reading.

+ * reading. StartingPositionTimestamp cannot be in the future.

*/ StartingPositionTimestamp?: Date; @@ -1551,11 +1552,8 @@ export type SnapStartApplyOn = (typeof SnapStartApplyOn)[keyof typeof SnapStartA /** * @public - *

The function's Lambda SnapStart setting. Set ApplyOn to PublishedVersions to create a + *

The function's Lambda SnapStart setting. Set ApplyOn to PublishedVersions to create a * snapshot of the initialized execution environment when you publish a function version.

- *

SnapStart is supported with the java11 runtime. For more information, see - * Improving startup performance with Lambda - * SnapStart.

*/ export interface SnapStart { /** diff --git a/clients/client-lambda/src/protocols/Aws_restJson1.ts b/clients/client-lambda/src/protocols/Aws_restJson1.ts index 4a322cefa9a9..455a8a23dd53 100644 --- a/clients/client-lambda/src/protocols/Aws_restJson1.ts +++ b/clients/client-lambda/src/protocols/Aws_restJson1.ts @@ -3388,6 +3388,9 @@ const de_DeleteEventSourceMappingCommandError = async ( case "InvalidParameterValueException": case "com.amazonaws.lambda#InvalidParameterValueException": throw await de_InvalidParameterValueExceptionRes(parsedOutput, context); + case "ResourceConflictException": + case "com.amazonaws.lambda#ResourceConflictException": + throw await de_ResourceConflictExceptionRes(parsedOutput, context); case "ResourceInUseException": case "com.amazonaws.lambda#ResourceInUseException": throw await de_ResourceInUseExceptionRes(parsedOutput, context); diff --git a/codegen/sdk-codegen/aws-models/lambda.json b/codegen/sdk-codegen/aws-models/lambda.json index f81909778d53..b528eaab2b7d 100644 --- a/codegen/sdk-codegen/aws-models/lambda.json +++ b/codegen/sdk-codegen/aws-models/lambda.json @@ -2567,13 +2567,13 @@ "StartingPosition": { "target": "com.amazonaws.lambda#EventSourcePosition", "traits": { - "smithy.api#documentation": "

The position in a stream from which to start reading. Required for Amazon Kinesis, Amazon\n DynamoDB, and Amazon MSK Streams sources. AT_TIMESTAMP is supported only for\n Amazon Kinesis streams and Amazon DocumentDB.

" + "smithy.api#documentation": "

The position in a stream from which to start reading. Required for Amazon Kinesis and\n Amazon DynamoDB Stream event sources. AT_TIMESTAMP is supported only for\n Amazon Kinesis streams, Amazon DocumentDB, Amazon MSK, and self-managed Apache Kafka.

" } }, "StartingPositionTimestamp": { "target": "com.amazonaws.lambda#Date", "traits": { - "smithy.api#documentation": "

With StartingPosition set to AT_TIMESTAMP, the time from which to start\n reading.

" + "smithy.api#documentation": "

With StartingPosition set to AT_TIMESTAMP, the time from which to start\n reading. StartingPositionTimestamp cannot be in the future.

" } }, "DestinationConfig": { @@ -3133,6 +3133,9 @@ { "target": "com.amazonaws.lambda#InvalidParameterValueException" }, + { + "target": "com.amazonaws.lambda#ResourceConflictException" + }, { "target": "com.amazonaws.lambda#ResourceInUseException" }, @@ -3197,7 +3200,7 @@ } ], "traits": { - "smithy.api#documentation": "

Deletes a Lambda function. To delete a specific function version, use the Qualifier parameter.\n Otherwise, all versions and aliases are deleted.

\n

To delete Lambda event source mappings that invoke a function, use DeleteEventSourceMapping. For Amazon Web Services and resources that invoke your function\n directly, delete the trigger in the service where you originally configured it.

", + "smithy.api#documentation": "

Deletes a Lambda function. To delete a specific function version, use the Qualifier parameter.\n Otherwise, all versions and aliases are deleted. This doesn't require the user to have explicit\n permissions for DeleteAlias.

\n

To delete Lambda event source mappings that invoke a function, use DeleteEventSourceMapping. For Amazon Web Services and resources that invoke your function\n directly, delete the trigger in the service where you originally configured it.

", "smithy.api#http": { "method": "DELETE", "uri": "/2015-03-31/functions/{FunctionName}", @@ -3912,13 +3915,13 @@ "StartingPosition": { "target": "com.amazonaws.lambda#EventSourcePosition", "traits": { - "smithy.api#documentation": "

The position in a stream from which to start reading. Required for Amazon Kinesis, Amazon DynamoDB, and Amazon MSK stream sources. AT_TIMESTAMP is supported only for Amazon Kinesis\n streams and Amazon DocumentDB.

" + "smithy.api#documentation": "

The position in a stream from which to start reading. Required for Amazon Kinesis and\n Amazon DynamoDB Stream event sources. AT_TIMESTAMP is supported only for\n Amazon Kinesis streams, Amazon DocumentDB, Amazon MSK, and self-managed Apache Kafka.

" } }, "StartingPositionTimestamp": { "target": "com.amazonaws.lambda#Date", "traits": { - "smithy.api#documentation": "

With StartingPosition set to AT_TIMESTAMP, the time from which to start\n reading.

" + "smithy.api#documentation": "

With StartingPosition set to AT_TIMESTAMP, the time from which to start\n reading. StartingPositionTimestamp cannot be in the future.

" } }, "BatchSize": { @@ -10159,7 +10162,7 @@ } }, "traits": { - "smithy.api#documentation": "

The function's Lambda SnapStart setting. Set ApplyOn to PublishedVersions to create a\n snapshot of the initialized execution environment when you publish a function version.

\n

SnapStart is supported with the java11 runtime. For more information, see\n Improving startup performance with Lambda\n SnapStart.

" + "smithy.api#documentation": "

The function's Lambda SnapStart setting. Set ApplyOn to PublishedVersions to create a\n snapshot of the initialized execution environment when you publish a function version.

" } }, "com.amazonaws.lambda#SnapStartApplyOn": {