/skills-developer:realtime-systemsfrom Developer Skills
Build WebSocket, SSE and pub/sub features: presence, fan-out, reconnection and backpressure. Use when building WebSockets, SSE, pub/sub, presence, or live feeds.
Ships in Developer Skills. Installing the plugin adds it to Claude Code.
What the skill costs in Claude's context, stage by stage
Name and description: Claude knows it exists.
SKILL.md joins the conversation and stays.
Read when SKILL.md points to them.
Realtime systems are not simply regular HTTP request-response APIs wrapped in an infinite polling loop. True realtime architectures maintain persistent bidirectional or streaming connections (WebSockets, Server-Sent Events, gRPC streaming) governed by connection lifecycle management, heartbeat health checks, exponential backoff reconnection, horizontal pub/sub fanout, and strict backpressure handling to prevent server memory exhaustion.
EventSource).ws.ping(); // Expect pong response within 5 seconds
ws.terminate()) to prevent ghost/zombie connection accumulation.room:123.room:123 and broadcast the message to their locally connected sockets.ws.bufferedAmount). If buffer exceeds 1MB, drop ephemeral messages (e.g. cursor positions) or pause ingestion until buffer drains.REALTIME-SPEC.md)# Realtime Communication System Specification: [Feature Name]
## 1. Protocol & Infrastructure Architecture
- **Selected Protocol**: WebSockets (`wss://`) / Server-Sent Events (`text/event-stream`)
- **Transport Security**: TLS 1.3 enforced
- **Pub/Sub Broker**: Redis Cluster / NATS Core
- **Target Concurrency**: 50,000 simultaneous active connections
## 2. Horizontal Fanout Topology
```mermaid
graph TD
Client1[Client A] <-->|WSS| EdgeNode1[WebSocket Node 1]
Client2[Client B] <-->|WSS| EdgeNode2[WebSocket Node 2]
EdgeNode1 <-->|Pub/Sub| Broker[(Redis / NATS Cluster)]
EdgeNode2 <-->|Pub/Sub| Broker
bufferedAmount > 2MB for 10s.{
"event": "room:message",
"room_id": "c1248",
"sender_id": "usr_99",
"sequence_id": 14208,
"payload": {
"text": "Hello world"
}
}
---
## Worked Example: Collaborative Document Presence Engine
- **Challenge**: 1,000 engineers viewing the same document generated 1,000,000 cursor updates per minute, crashing Node.js servers.
- **Solution**:
- Downsampled cursor broadcasts from 60Hz to 15Hz client-side.
- Implemented backpressure checking on socket buffer before pushing.
- Switched from JSON strings to compact binary Protobuf payloads.
- **Outcome**: Server CPU dropped by 72%; memory usage stabilized under 300MB at 25,000 active connections.
---
## Verification Checklist
- [ ] Ping/pong heartbeat terminates dead connections within 35 seconds.
- [ ] Client reconnection implements exponential backoff with randomized jitter.
- [ ] Horizontal scaling is backed by Redis or NATS pub/sub message broker.
- [ ] Backpressure safeguards drop or throttle messages when client buffers overflow.
- [ ] Connections operate strictly over encrypted protocols (`wss://` or HTTPS).
---
## Anti-Patterns
- **Short-Polling pretending to be Realtime**: Hitting an API endpoint every 500ms from the browser.
- **Memory Leaks from Event Listeners**: Forgetting to remove event listeners on socket disconnect, crashing the Node.js process.
- **Broadcasting Everything to Everyone**: Sending all global events to all connected clients and filtering on the frontend.
What SKILL.md sets; muted values are Claude Code's defaults
skills-developer@skillary is listed by poorvith-mp/skillary — review the source before installing
npx claudepluginhub poorvith-mp/skillary --plugin skills-developer135 skills in this plugin
/accessibility-engineerMoved to accessibility-fix in skills-developer. Removed in v4.1./accessibility-fixAudit and refactor code for WCAG 2.1/2.2 AA and AAA: ARIA, keyboard operability, screen readers. Use when auditing or remediating WCAG 2.1/2.2 AA/AAA accessibility issues./ai-data-remediation-engineerMoved to data-pipelines in skills-developer. Removed in v4.1./ai-engineerMoved to ml-deployment in skills-developer. Removed in v4.1.