### Is there an existing issue for this?

- [X] I have searched the existing issues

### Feature description

Basically we want to only run the lambda when an insert is occurring in DynamoDB.
I tested using Dynobase deleting a record and the lambda still triggered.

```
resource "aws_lambda_event_source_mapping" "event-log" {
	event_source_arn  = aws_dynamodb_table.event-log.stream_arn
	function_name     = module.main.lambda-arn
	starting_position = "LATEST"
	enabled = true # change to false when truncating the table in localstack
	maximum_retry_attempts = 1 # limit retry on failure to 1 for now

	# https://dev.to/aws-builders/filtering-dynamodb-streams-before-lambda-p5p
	filter_criteria { # Doesn't seem to work on LocalStack for now
		filter {
			pattern = jsonencode({
				body = {
					eventName : ["INSERT"]
				}
			})
		}
	}
}
```


### 🧑‍💻 Implementation

_No response_

### Anything else?

 https://dev.to/aws-builders/filtering-dynamodb-streams-before-lambda-p5p
If the response returns an empty list, then the batch should be considered as a complete success. If an exception
    is raised, the batch should be considered a complete failure.
    See https://docs.aws.amazon.com/lambda/latest/dg/with-sqs.html#services-sqs-batchfailurereporting
    :param result: the lambda invocation result
    :param valid_message_ids: the list of valid message ids in the batch
    :raises KeyError: if the itemIdentifier value is missing or not in the batch
    :raises Exception: any other exception related to parsing (e.g., JSON parser error)
    :return: a list of message IDs that are part of a failure and should not be deleted from the queue
    """
    if not result or not result.result:
        return []
    if isinstance(result.result, dict):
        partial_batch_failure = result.result
    else:
        partial_batch_failure = json.loads(result.result)
    if not partial_batch_failure:
        return []
    batch_item_failures = partial_batch_failure.get("batchItemFailures")
    if not batch_item_failures:
        return []
    messages_to_keep = []
    for item in batch_item_failures:
        if "itemIdentifier" not in item:
            raise KeyError(f"missing itemIdentifier in batchItemFailure record {item}")
        item_identifier = item["itemIdentifier"]
        if item_identifier not in valid_message_ids:
            raise KeyError(f"itemIdentifier '{item_identifier}' not in the batch")
        messages_to_keep.append(item_identifier)
    return messages_to_keep