Setting the file. One moment.
Skill 24 · Architect For Startups
Subchapter 24.25
references/observability.mdMarkdown7 KBView on GitHub
| Trap | Impact | Fix |
|---|---|---|
| Log retention: never expire (default) | $0.03/GB/month storage — grows forever. 100GB/month of logs = $36/year in year 1, $72 in year 2, etc. | Set retention policy on creation. 30 days prod. |
| Custom metrics via PutMetricData | $0.30/metric/month + $0.01/1000 API calls | Use Embedded Metric Format in Lambda — creates metrics from logs at zero API cost |
| High-cardinality custom metrics | Dimensions multiply: 100 users × 10 endpoints = 1000 metrics = $300/month | Use Logs Insights for high-cardinality analysis, reserve metrics for low-cardinality aggregates |
| X-Ray 100% sampling in prod | $5.00/million traces recorded + storage | Sample: 1/sec + 5% additional. For startups this is usually enough. |
| Datadog before $5M ARR | $15-50/host/month + $1.70/million log events. 10 containers + logs = $500-2000/month easily | CloudWatch is included in AWS credits. Switch when team size (>10 engineers) justifies the UX premium. |
| CloudWatch Dashboards | $3/dashboard/month — sounds small, proliferates fast | 1 dashboard per service max. Use automatic dashboards for exploration. |
| Contributor Insights | $0.02/rule/100 log events evaluated. High-volume logs = surprise bill | Enable only on specific log groups for incident investigation, disable after |
| Trigger | Action |
|---|---|
| First customer-facing outage you can’t diagnose in 30min | Add X-Ray tracing |
| Debugging takes >1hr regularly | Increase log retention, add structured fields |
| 3+ services with cross-service calls | Distributed tracing (X-Ray or OTEL) |
| 10+ engineers needing observability | Evaluate Datadog/New Relic (UX justifies cost) |
| SOC2 audit | 90-day log retention, CloudTrail in all accounts |
| Monthly observability bill >$500 on CloudWatch | Audit: log retention, custom metrics cardinality, unused dashboards |
CloudWatch costs (logs, metrics, dashboards, X-Ray) are covered by AWS Activate credits. While you have credits:
Set a calendar reminder 6 months before credits expire to implement cost-optimized retention policies.