Why Adopt
Cloudflare Workers run JavaScript at the edge—300+ data centers worldwide. Your code executes milliseconds from your users, not in some distant data center.
FlowLink’s redirect service runs entirely on Workers. The result: P50 latency of 12ms, P99 of 48ms. Try achieving that with a traditional server.
Key Features
- Global by default - Deploy once, run everywhere
- Zero cold starts - V8 isolates, not containers
- KV storage - Globally distributed key-value store
- Durable Objects - Stateful edge computing
- Free tier - 100k requests/day
My Architecture Pattern
User Request
↓
Cloudflare Worker (nearest edge)
↓
KV Lookup (cached at edge)
↓
Response (< 50ms)
The Rails app is source of truth for data. Workers handle the read-heavy, latency-sensitive path.
When to Use Workers
Good fit:
- Redirects and proxies
- Authentication/authorization at edge
- API rate limiting
- Image/content transformation
- Geolocation logic
Poor fit:
- CPU-intensive work (50ms CPU limit)
- Long-running tasks
- Complex database queries
The Developer Experience
Workers’ DX is excellent:
wranglerCLI is fast and intuitive- Local development via Miniflare
- Git-based deployments
- Excellent observability
Cost Reality
FlowLink handles ~10k redirects/day. Monthly cost: $0 (free tier).
At scale, pricing is $0.50 per million requests. Compare to Lambda’s $0.20/million + duration charges, and Workers often wins on total cost.
For latency-sensitive workloads, Workers is simply the best option.