fastapi-stream-lease

One user. One stream. Two tabs.

This demo holds a Redis lease for each SSE stream. Both panels share one HttpOnly session cookie, so the second stream is rejected with 429 until the first one finishes or disconnects.

Active streams
0 / 20
Per user
1
Backend
checking...

Tab A

Synthetic SSE stream

idle
Tokens received 0 / 0 Last token โ€”
Ready.

Tab B

Same cookie, same user

idle
Tokens received 0 / 0 Last token โ€”
Ready.

What you are seeing