Early stages of a Server-Sent Events server in PHP. Client-side is known as EventSource.
Basically the idea here is a lightweight server to sit in-between the browser and the web server. The responsibility of the server would be to efficiently, securely, and safely relay SSE messages.
see examples in: