Quiz Entry - updated: 2026.07.30
To detect a protocol state change, a service can use SSE or polling. What is the trade-off?
Server-Sent Events (SSE) push state changes to you in real time; polling means you repeatedly query for changes yourself. SSE gives lower latency, polling is simpler but heavier.
An integration service can respond to protocol state transitions two ways:
- Server-Sent Events (SSE) — the service subscribes and the Engine pushes real-time state changes to it as they happen. Low latency, no wasted queries.
- Polling — the service periodically queries protocol instances or types through a backend service to detect changes. Simpler to implement, but it trades freshness and efficiency: you only learn of a change on the next poll, and you query even when nothing changed.
The preferred approach depends on the application's requirements — latency, scalability, and infrastructure constraints. Real-time UIs favour SSE; batch or constrained environments may accept polling.
Go deeper:
Server-sent events (Wikipedia) — how the push side works over a single long-lived HTTP connection, and how it compares to polling and WebSockets.