InterviewStack.io LogoInterviewStack.io

EC2 Lambda and Managed Services Questions

Comprehensive understanding of cloud compute options and how to choose between Amazon EC2, AWS Lambda, and managed deployment services such as Elastic Beanstalk. Candidates should be able to compare tradeoffs between control and operational overhead. Amazon EC2 provides full operating system level control, support for long running and stateful processes, custom machine images, fine grain instance sizing, placement groups for network and latency requirements, and suitability for legacy or specialized workloads. AWS Lambda provides a serverless event driven execution model with automatic scaling, per invocation billing, and minimal infrastructure management but introduces cold start latency, concurrency limits, execution duration limits, and resource constraints. Managed deployment services such as Elastic Beanstalk simplify application deployment and lifecycle management by abstracting infrastructure while still allowing configuration of underlying resources. Candidates should also know instance family characteristics for sizing such as burstable T series, general purpose M series, and compute optimized C series; pricing models including on demand, reserved capacity, savings plans, and spot instances; cost optimization techniques such as right sizing and spot use; and scaling and deployment patterns including auto scaling groups, function concurrency management, scheduled scaling, placement groups, and deployment strategies. Key design considerations include stateless versus stateful architecture, startup time impact, observability and monitoring, testing and deployment complexity, security and compliance, and how each option affects reliability, latency and cost.

MediumTechnical
75 practiced
After moving several Lambda functions into a VPC to access RDS, you observe significantly increased cold start latency. Diagnose the likely cause and propose mitigations that reduce cold starts while preserving secure access to the database. Include trade-offs for each mitigation.
EasyTechnical
128 practiced
Explain the primary characteristics and ideal workloads for EC2 instance families: T (burstable), M (general purpose), C (compute-optimized), and R (memory-optimized). For each family describe typical use cases, how CPU/memory behave under sustained load, and one common sizing mistake teams make when selecting instance families.
HardSystem Design
86 practiced
Design an architecture to ensure strong transactional consistency between an EC2-hosted payment service and a Lambda-based notification service that both write to the same DynamoDB table. Address how to guarantee no lost updates, idempotency for notifications, and failure handling when one service succeeds and the other fails. Discuss DynamoDB transactions and patterns for cross-service coordination.
HardTechnical
89 practiced
A third-party NPM package introduced into a Lambda webhook appears to be exfiltrating sensitive customer data. Describe immediate containment steps you would take (runtime, network, deploy, and access controls), a structured incident investigation plan, short-term code and permission changes, and long-term architectural and process changes to reduce risk from third-party dependencies.
EasyTechnical
72 practiced
Describe AWS Spot Instances, including how interruptions are signaled and typical interruption modeling. Provide three practical strategies to safely utilize Spot instances to reduce cost (for stateless and checkpointable workloads) and give a concrete example of checkpointing or graceful degradation.

Unlock Full Question Bank

Get access to hundreds of EC2 Lambda and Managed Services interview questions and detailed answers.

Sign in to Continue

Join thousands of developers preparing for their dream job.