Designing a Serverless Real-Time Chat with AWS WebSockets
I want a clean, feasible plan for building a real-time chat service on AWS. Just an architecture I can deploy, test, and iterate on.
Goals Real time. Messages appear for all clients in the same room. Serverless scale. Handle spikes without manual intervention. Cost aware. Pay only when used. Simple to operate. Clear metrics, alarms, and dead-letter handling. Architecture Core pieces
Amazon API Gateway WebSocket API
Routes: $connect, $disconnect, $default, and sendMessage. AWS Lambda