Skip to content

Commit

Permalink
documentation on user session behavior on disconnections (Fixes #308)
Browse files Browse the repository at this point in the history
  • Loading branch information
miguelgrinberg committed Jun 29, 2019
1 parent 3062d3f commit 2aa8636
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion docs/server.rst
Original file line number Diff line number Diff line change
Expand Up @@ -396,7 +396,6 @@ retrieve information in the user session::

For the ``asyncio`` server, these methods are coroutines::


@sio.event
async def connect(sid, environ):
username = authenticate_user(environ)
Expand Down Expand Up @@ -437,6 +436,10 @@ The ``get_session()``, ``save_session()`` and ``session()`` methods take an
optional ``namespace`` argument. If this argument isn't provided, the session
is attached to the default namespace.

Note: the contents of the user session are destroyed when the client
disconnects. In particular, user session contents are not preserved when a
client reconnects after an unexpected disconnection from the server.

Using a Message Queue
---------------------

Expand Down

0 comments on commit 2aa8636

Please sign in to comment.