This chapter covers the core features and capabilities of Microservices Architecture Guide.
This guide provides battle-tested IaC templates and patterns for building a microservices architecture on AWS. It covers the full stack from service decomposition strategy through deployment, networking (API Gateway + service mesh), and end-to-end observability. Every template is deployable and extensively commented.
| File | Description |
|---|---|
cloudformation/api-gateway.yaml | API Gateway with Lambda authorizer, rate limiting, WAF integration |
cloudformation/ecs-service-mesh.yaml | ECS Fargate services with App Mesh sidecar proxies |
cloudformation/observability-stack.yaml | CloudWatch, X-Ray, Container Insights, custom dashboards |
terraform/api-gateway.tf | Terraform API Gateway with OpenAPI integration |
terraform/ecs-fargate-service.tf | ECS Fargate service module with auto-scaling |
terraform/service-mesh.tf | App Mesh virtual services, routers, and nodes |
terraform/variables.tf | Shared variables for all Terraform configurations |
kubernetes/service-deployment.yaml | K8s Deployment with readiness/liveness probes |
kubernetes/istio-virtualservice.yaml | Istio traffic management and circuit breaking |
kubernetes/network-policies.yaml | K8s NetworkPolicy for service isolation |
scripts/service_decomposition_analyzer.py | Analyzes domain boundaries and suggests decomposition |
scripts/api_contract_generator.py | Generates OpenAPI specs from service definitions |
docs/architecture.md | Reference architecture with Mermaid diagrams |
docs/decomposition-patterns.md | Service decomposition decision framework |
docs/observability-guide.md | Observability instrumentation guide |
examples/api-gateway-openapi.yaml | OpenAPI 3.0 spec for a sample API |
examples/service-catalog.json | Example service registry / catalog |
LICENSE | MIT License |
┌─────────────────────────────────────────────────────────┐
│ API Gateway / ALB │
│ (Rate limiting, Auth, WAF) │
├──────────┬──────────┬───────────┬───────────────────────┤
│ │ │ │ │
│ User │ Order │ Product │ Payment │
│ Service │ Service │ Service │ Service │
│ (ECS) │ (ECS) │ (ECS) │ (ECS) │
│ │ │ │ │
├──────────┴──────────┴───────────┴───────────────────────┤
│ Service Mesh (App Mesh / Istio) │
│ (mTLS, Circuit Breaking, Retries, Tracing) │
├─────────────────────────────────────────────────────────┤
│ Observability (X-Ray, CloudWatch) │
│ (Distributed tracing, Metrics, Structured logs) │
└─────────────────────────────────────────────────────────┘
Follow this guide to get Microservices Architecture Guide up and running in your environment.
Use the decomposition analyzer to assess service boundaries:
python3 scripts/service_decomposition_analyzer.py --interactiveGenerate an OpenAPI spec from your service catalog:
python3 scripts/api_contract_generator.py \
--catalog examples/service-catalog.json \
--output my-api-spec.yamlaws cloudformation deploy \
--template-file cloudformation/api-gateway.yaml \
--stack-name microservices-api-gw \
--parameter-overrides Environment=staging \
--capabilities CAPABILITY_NAMED_IAMaws cloudformation deploy \
--template-file cloudformation/ecs-service-mesh.yaml \
--stack-name user-service \
--parameter-overrides ServiceName=user-service ImageUri=123456789012.dkr.ecr.us-east-1.amazonaws.com/user-service:latestaws cloudformation deploy \
--template-file cloudformation/observability-stack.yaml \
--stack-name microservices-observability| Component | Monthly Cost (10 services, moderate traffic) |
|---|---|
| API Gateway (REST) | ~$30-100 (per million requests) |
| ECS Fargate (10 services x 0.5 vCPU) | ~$150-300 |
| App Mesh | Free (included with ECS) |
| CloudWatch Logs | ~$20-50 (depending on log volume) |
| X-Ray Traces | ~$5-15 (first 100K traces/month free) |
| Total | ~$200-500/month |
Get the full Microservices Architecture Guide and unlock everything.
Get the complete guide with every chapter unlocked, including code samples, diagrams, and best practices.
Access all interactive tools with complete data, all workload profiles, and the full scenario library.
Downloadable source code, configuration files, and working examples from every chapter.
Free updates for life. Every new chapter, tool, and improvement included.