Skip to content

Real-time collaboration

Activate

The feature is available as soon as the "Real-time collaboration" island is attached to the profile:

Activate

Use

The island is showing the faces of the users which did a change the last 15 minutes.

Use

If no users, or only the current user, were active the last 15 minutes, the island is not displayed.

The live updates still run while the island is hidden, as long as it is enabled in the profile: each user must see the changes made by others with a 2 seconds delay maximum. Without the island, no stream is opened (IslandInterface::needsSse()).

The loop is executing three checks in this order:

  • is there a change? if not, wait 2 seconds and start again
  • is it done in another session? if not, wait 2 seconds and start again. Sessions, not users, are compared: the same user in another browser gets the change, and a change made outside a browser session (an AI agent, a queue worker) is relayed to everyone
  • is the change made the last 3 seconds? if not, wait 2 seconds and start again

If all three are OK, a stream is sent with the updated HTML fragments to replace.

Under the hood

We use the SSE extension of HTMX with the EventStreamResponse introduced in Symfony 7.3