Skip to content

Commit 187c525

Browse files
Documented protocol defaults
1 parent 2faa6f5 commit 187c525

File tree

1 file changed

+16
-9
lines changed

1 file changed

+16
-9
lines changed

socketio/server.py

Lines changed: 16 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,8 @@ class Server(object):
2121
is stored in an in-memory structure, so the use of
2222
multiple connected servers is not possible.
2323
:param logger: To enable logging set to ``True`` or pass a logger object to
24-
use. To disable logging set to ``False``.
24+
use. To disable logging set to ``False``. The default is
25+
``False``.
2526
:param binary: ``True`` to support binary payloads, ``False`` to treat all
2627
payloads as text. On Python 2, if this is set to ``True``,
2728
``unicode`` values are treated as text, and ``str`` and
@@ -48,26 +49,32 @@ class Server(object):
4849
The first async mode that has all its dependencies
4950
installed is then one that is chosen.
5051
:param ping_timeout: The time in seconds that the client waits for the
51-
server to respond before disconnecting.
52+
server to respond before disconnecting. The default
53+
is 60 seconds.
5254
:param ping_interval: The interval in seconds at which the client pings
53-
the server.
55+
the server. The default is 25 seconds.
5456
:param max_http_buffer_size: The maximum size of a message when using the
55-
polling transport.
56-
:param allow_upgrades: Whether to allow transport upgrades or not.
57+
polling transport. The default is 100,000,000
58+
bytes.
59+
:param allow_upgrades: Whether to allow transport upgrades or not. The
60+
default is ``True``.
5761
:param http_compression: Whether to compress packages when using the
58-
polling transport.
62+
polling transport. The default is ``True``.
5963
:param compression_threshold: Only compress messages when their byte size
60-
is greater than this value.
64+
is greater than this value. The default is
65+
1024 bytes.
6166
:param cookie: Name of the HTTP cookie that contains the client session
6267
id. If set to ``None``, a cookie is not sent to the client.
68+
The default is ``'io'``.
6369
:param cors_allowed_origins: List of origins that are allowed to connect
6470
to this server. All origins are allowed by
6571
default.
6672
:param cors_credentials: Whether credentials (cookies, authentication) are
67-
allowed in requests to this server.
73+
allowed in requests to this server. The default is
74+
``True``.
6875
:param engineio_logger: To enable Engine.IO logging set to ``True`` or pass
6976
a logger object to use. To disable logging set to
70-
``False``.
77+
``False``. The default is ``False``.
7178
"""
7279
def __init__(self, client_manager=None, logger=False, binary=False,
7380
json=None, async_handlers=False, **kwargs):

0 commit comments

Comments
 (0)