Architect a real-time feature
Design a real-time feature with WebSockets, SSE, or long-polling, covering connection management, delivery guarantees, horizontal scaling, and graceful degradation.
Preview
Copy prompt
Design a real-time [Feature, e.g. live chat, collaborative editing, or live dashboard] for [Application]. Compare WebSockets, Server-Sent Events, and long polling against your latency and scalability requirements. For the chosen transport describe: the connection lifecycle and reconnection strategy, the message envelope format and versioning, delivery guarantees and what happens to messages when a client is temporarily disconnected, how to fan out messages at scale across multiple server instances using a pub-sub layer, and how the feature degrades gracefully when the real-time transport is unavailable.
More
Architecture
Prompts
