Long message-bus HTTP requests? What are they for?

You can read about MessageBus here:

MessageBus is responsible for pushing live notifications from the server to the clients.

So, for example, as soon as someone :heart:'s this message I get a blue notification on the top right. Or if someone replies this page will refresh right away with the reply.

MessageBus using long polling with chunked encoding, what this means is that a single 30 second session can push multiple messages from the server to the client.

The 30 second requests here are not a performance concern, payloads are tiny and the server is designed to handle this traffic very easily. Since you are using H2 it does not even eat up a connection slot like it would in the old days of H1. Once browser moves to a background tab message bus is smart enough to slow down its polling.

5 Likes