Serverless Developer Guide
Advanced Topics
You can do a lot by just creating a function and connecting it to an event source like API Gateway 
or S3 triggers.
As you progress on your journey, you should explore the following more advanced topics.
• Connect services with event source mapping
• Deploy code in containers
• Add additional code with layers
• Augment functions with extensions
• Launch functions faster with SnapStart
• Connect to functions with Function URLs
Event source mapping
Some services can trigger Lambda functions directly, for example, when an image is added to an 
S3 bucket, a Lambda can be triggered to resize it. Some services cannot invoke Lambda directly; 
but you can instead use an event source mapping which is a polling mechanism that reads from an 
event source and invokes a Lambda function.
You can use event source mappings to process items from a stream or queue in the following 
services:
• Amazon DynamoDB
• Amazon Kinesis
• Amazon MQ
• Amazon Managed Streaming for Apache Kafka (Amazon MSK)
• Self-managed Apache Kafka
• Amazon Simple Queue Service
Related resource:
• Event source mapping oﬃcial documentation, including the default behavior that batches 
records together into a single payload that Lambda sends to your function.
Advanced Topics 57