Technical decisions, patterns learned, and the evolution across 19 projects
Every project runs on Lambda. No EC2, no containers, no idle costs. Function URLs for simple APIs, API Gateway when CORS or routing gets complex, SAM when the stack has multiple resources.
Bedrock Nova Lite isn't just for chatbots. Used it as a reasoning engine inside Step Functions (Failover Orchestrator), a code reviewer (Architecture Reviewer), and a document analyzer (Resume Radar, Cost Optimizer).
S3 events trigger Lambda, SQS buffers async work, EventBridge schedules recurring jobs, Step Functions orchestrate multi-step workflows with conditional branching. No polling, no cron servers.
Failover Orchestrator uses one table with pk/sk pattern: HEALTHCHECK|timestamp, INCIDENT|timestamp, CONFIG|status. TTL handles cleanup. On-demand billing keeps costs at pennies.
CI/CD workflow with --delete wiped S3 files that didn't exist locally. Now: always verify S3 contents before sync. Safety rule added to project rules.
Foundation model ARNs don't work for inference profiles. Learned to use Resource: "*" for bedrock:InvokeModel. Scoping down requires knowing the exact inference profile ARN.
CloudFront security headers block everything not whitelisted. Every new Lambda URL or external font needs to be added to the Content-Security-Policy. Switched to wildcards.
Lambda Function URL CORS config + Lambda response CORS headers = browser rejection. Pick one. Function URL config handles it — don't duplicate in code.
samconfig.toml requires version = 0.1 at the top. Missing it causes cryptic errors. PC Matic blocks SAM and Python — must whitelist both.
Deployed code but saw old page. Always invalidate CloudFront after deploy. CI/CD now does this automatically. Hard refresh (Cmd+Shift+R) for local browser cache.
Replaced RDS, ALB, ASG, and VPC infrastructure with serverless equivalents. HA Web App became Resume Radar (single Lambda). Six old CloudFront distributions and three S3 buckets removed. Same functionality, 80% cost reduction.
Amazon Q IDE subscription is the largest line item. After that: Route 53 (~$0.50), Bedrock Nova Lite (~$0.15), DynamoDB on-demand (pennies), S3 + CloudFront (pennies). Nine AI projects, two live sites, CI/CD pipelines — all within free tier or near-zero cost.