Skip to content

Commit

Permalink
feat(lambda-event-sources): starting position timestamp for kafka
Browse files Browse the repository at this point in the history
  • Loading branch information
nikovirtala committed Jan 23, 2025
1 parent e4703c1 commit b287c83
Show file tree
Hide file tree
Showing 11 changed files with 497 additions and 12 deletions.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Original file line number Diff line number Diff line change
Expand Up @@ -454,6 +454,128 @@
"my-test-topic3"
]
}
},
"F4ServiceRole100FF901": {
"Type": "AWS::IAM::Role",
"Properties": {
"AssumeRolePolicyDocument": {
"Statement": [
{
"Action": "sts:AssumeRole",
"Effect": "Allow",
"Principal": {
"Service": "lambda.amazonaws.com"
}
}
],
"Version": "2012-10-17"
},
"ManagedPolicyArns": [
{
"Fn::Join": [
"",
[
"arn:",
{
"Ref": "AWS::Partition"
},
":iam::aws:policy/service-role/AWSLambdaBasicExecutionRole"
]
]
}
]
}
},
"F4ServiceRoleDefaultPolicy1E98EC08": {
"Type": "AWS::IAM::Policy",
"Properties": {
"PolicyDocument": {
"Statement": [
{
"Action": [
"secretsmanager:DescribeSecret",
"secretsmanager:GetSecretValue"
],
"Effect": "Allow",
"Resource": [
{
"Ref": "S509448A1"
},
{
"Ref": "SC0855C491"
}
]
}
],
"Version": "2012-10-17"
},
"PolicyName": "F4ServiceRoleDefaultPolicy1E98EC08",
"Roles": [
{
"Ref": "F4ServiceRole100FF901"
}
]
}
},
"F4F1740A13": {
"Type": "AWS::Lambda::Function",
"Properties": {
"Code": {
"ZipFile": "exports.handler = async function handler(event) {\n console.log('event:', JSON.stringify(event, undefined, 2));\n return { event };\n}"
},
"Handler": "index.handler",
"Role": {
"Fn::GetAtt": [
"F4ServiceRole100FF901",
"Arn"
]
},
"Runtime": "nodejs18.x"
},
"DependsOn": [
"F4ServiceRoleDefaultPolicy1E98EC08",
"F4ServiceRole100FF901"
]
},
"F4KafkaEventSource838c4d5ff3c99c1a617120adfca83e5bmytesttopic4F6589D62": {
"Type": "AWS::Lambda::EventSourceMapping",
"Properties": {
"BatchSize": 100,
"FunctionName": {
"Ref": "F4F1740A13"
},
"SelfManagedEventSource": {
"Endpoints": {
"KafkaBootstrapServers": [
"my-self-hosted-kafka-broker-1:9092",
"my-self-hosted-kafka-broker-2:9092",
"my-self-hosted-kafka-broker-3:9092"
]
}
},
"SelfManagedKafkaEventSourceConfig": {
"ConsumerGroupId": "myTestConsumerGroup4"
},
"SourceAccessConfigurations": [
{
"Type": "CLIENT_CERTIFICATE_TLS_AUTH",
"URI": {
"Ref": "SC0855C491"
}
},
{
"Type": "SERVER_ROOT_CA_CERTIFICATE",
"URI": {
"Ref": "S509448A1"
}
}
],
"StartingPosition": "AT_TIMESTAMP",
"StartingPositionTimestamp": 1730270400,
"Topics": [
"my-test-topic4"
]
}
}
},
"Parameters": {
Expand Down

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading

0 comments on commit b287c83

Please sign in to comment.