PLAYBOOK #04AWS Verbatim & System Design•10 min read
Performance Efficiency & Cost Optimization
Pillars 2 & 3: DynamoDB Single-Table Design, compute form factors (Lambda vs Fargate vs EC2), NAT Gateway traps ($0.045/GB), and cross-AZ data transfer charges.
PERF 1-5COST 1-11DynamoDB Single-TableNAT Gateway Trap
Source: AWS Well-Architected Tool:
- Performance Efficiency: PERF 1 – PERF 5 (5 Questions)
- Cost Optimization: COST 1 – COST 11 (11 Questions)
Core Concept: Maximizing throughput and minimizing latency while ruthlessly eliminating unnecessary cloud spend and data transfer waste.
1. Performance Efficiency (PERF 1 – PERF 5)
| ID | Question | Architectural Focus for Interviews |
|---|---|---|
| PERF 1 | How do you select the appropriate cloud resources and architecture patterns? | Microservices vs Serverless event-driven architectures, choosing between relational, key-value, document, graph, or time-series data models based on query access patterns. |
| PERF 2 | How do you select and use compute resources? | Choosing optimal compute form factors (Lambda vs Fargate vs EC2), leveraging Graviton3/ARM64 architecture for 20–40% better price/performance. |
| PERF 3 | How do you store, manage, and access data? | DynamoDB Single-Table Design, read replicas, caching tiers (DAX, Redis), S3 storage classes, optimizing partition key cardinality to eliminate hot partitions. |
| PERF 4 | How do you select and configure networking resources? | CloudFront CDN edge caching, AWS Global Accelerator (Anycast IP for TCP acceleration), Route 53 Latency-based routing, VPC Endpoints to avoid NAT Gateway bottlenecks. |
| PERF 5 | What process do you use to support more performance efficiency? | Load testing, tracing bottlenecks with AWS X-Ray, continuous benchmarking, automated load generation before peak events. |
2. Cost Optimization (COST 1 – COST 11)
| ID | Question | Architectural Focus for Interviews |
|---|---|---|
| COST 1 | How do you implement cloud financial management? | Tagging architectures by cost center/service, establishing budget alarms and anomaly detection. |
| COST 2 | How do you govern usage? | IAM service control policies (SCPs) preventing provisioning of unauthorized expensive instance types (e.g., p4d.24xlarge GPU instances). |
| COST 3 | How do you monitor your cost and usage? | AWS Cost Explorer, CloudWatch billing metrics, detailed cost allocation tags. |
| COST 4 | How do you decommission resources? | Automated cleanup of orphaned EBS volumes, unattached Elastic IPs, expired DynamoDB items via TTL, S3 bucket lifecycle rules. |
| COST 5 | How do you evaluate cost when you select services? | Total Cost of Ownership (TCO): comparing managed services (RDS/DynamoDB) vs self-hosted EC2 factoring in engineering operational maintenance cost. |
| COST 6 | How do you meet cost targets when you select resource type, size and number? | Right-sizing compute instances based on historical utilization (CloudWatch CPU/RAM metrics), auto-scaling down to zero when demand drops. |
| COST 7 | How do you use pricing models to reduce cost? | Compute Savings Plans (up to 66% discount for steady baseline), Reserved Instances, Spot Instances (up to 90% discount for stateless workers). |
| COST 8 | How do you plan for data transfer charges? | The AWS Data Transfer Trap: Keeping traffic inside the same AZ where possible, using VPC Gateway Endpoints for S3/DynamoDB (free vs NAT Gateway fees). |
| COST 9 | How do you manage demand, and supply resources? | Dynamic auto-scaling based on real-time metrics, queue-depth-based worker scaling, scheduled scaling for known promotional peaks. |
| COST 10 | How do you evaluate new services? | Benchmarking new instance generations (e.g., migrating from x86 to Graviton3 ARM instances to reduce costs by 20%). |
| COST 11 | How do you evaluate the cost of effort? | Avoiding speculative custom microservices when managed serverless primitives deliver 90% of the capability at 10% of the maintenance overhead. |
Part 2: Production Deep-Dive Locked1 Coin = 24 Hours
Unlock Complete Architecture & Production Runbooks
Your Balance:
You have explored the free architectural preview (~40%). Spend 1 Coin to unlock the remaining 3 production deep-dive sections for a full 24 hours.
Sections Included in This 24-Hour Pass:
3. High-Performance Data Architecture: DynamoDB Single-Table Design
4. The Hidden AWS Data Transfer Traps (Cost Invariant)
5. Network Routing & Global Acceleration
Connecting to coin treasury...
Keeps page unlocked for exactly 24 hoursSpend coins to fund LLM & compute infrastructure