Two Ways to Build Event-Driven Serverless Applications
Aug 2, 2023Piyush Bhansali

Summary
This post details two patterns for integrating AWS Lambda with Kafka: the Confluent Lambda Sink Connector and AWS Lambda Event Source Mapping (ESM). The Sink Connector offers synchronous/asynchronous invocation and DLQ support, suitable for fire-and-forget scenarios or ordered processing with tasks. ESM provides automatic polling and scaling based on consumer offset lag, ideal for auto-scaling and ordered processing within a consumer group. Use cases are provided for each pattern: healthcare EHR integration with ESM for ordered processing, and email marketing with the Sink Connector for asynchronous, high-throughput scenarios.
More from the HTTP and REST API Integration with Kafka trail
- Integrate Kafka with AWS EventBridge Using Confluent
- Provisioned Mode for Lambda's Kafka ESM: New Controls and Autoscaling
- Connect Your HTTP APIs to Confluent with Fully Managed Connectors
- Building Event-Driven Architectures: Top 5 Best Practices
- Serverless, Secure Data Streaming with Confluent Cloud and AWS Lambda