sdk.lusid.extensions.tcp_keep_alive_connector.TcpKeepAliveConnector
- class TcpKeepAliveConnector(connector, socket_options)[source]
Replacement for aiohttp.TCPConnector which sets socket options on each connection. So we can use tcp keep alives which aiohttp has limited support for.
Attributes
This is a Pydantic class. For now, click on the green [source] link in the class signature above to see descriptions/allowed values for these attributes.
allowed_protocol_schema_setIs connector closed.
familySocket family like AF_INET.
force_closeUltimately close connection on releasing if True.
limitThe total number for simultaneous connections.
limit_per_hostThe limit for simultaneous connections to the same endpoint.
use_dns_cacheTrue if local DNS caching is enabled.
Methods
clear_dns_cacheRemove specified host/port or clear all dns local cache.
Close all opened transports.
Wraps TCP connector, each new connection will have socket options and windows ioctl for keep alives applied
- async close()[source]
Close all opened transports.
- Parameters:
abort_ssl – If True, SSL connections will be aborted immediately without performing the shutdown handshake. If False (default), the behavior is determined by ssl_shutdown_timeout: - If ssl_shutdown_timeout=0: connections are aborted - If ssl_shutdown_timeout>0: graceful shutdown is performed
- Return type:
- property closed
Is connector closed.
A readonly property.