AyuGramDesktop/Telegram/SourceFiles/mtproto
Loïc Molinari 06618a5253 Use fine grained session timers
The check of sent requests and containers is done unconditionally
every second even though the request timeout is 10 seconds and the
container timeout is 600 seconds. This commit uses fine grained timers
instead in order to avoid useless system wake-up events.

The check of sent requests is now scheduled on demand when a new
request is queued. Then the callback, while parsing queued requests,
computes the delta to the closest expiring request and automatically
schedules the next check if necessary.

Given the high value of the container timeout, its callback is called
repeatedly every 600 seconds, unless it computes a lower delta for an
expiring container using the same logic as for the requests.
2021-04-15 16:20:42 +03:00
..
details Fix build on macOS and Linux. 2021-04-12 10:48:17 +04:00
config_loader.cpp Allow getting outer_msg_id in MTProto handlers. 2021-03-12 16:58:26 +04:00
config_loader.h Rename RPCError to MTP::Error. 2021-03-12 16:58:26 +04:00
connection_abstract.cpp Move some more code to lib_mtproto. 2019-12-02 16:11:22 +03:00
connection_abstract.h Build with QT_NO_KEYWORDS 2021-03-04 12:07:54 +04:00
connection_http.cpp Build with QT_NO_KEYWORDS 2021-03-04 12:07:54 +04:00
connection_http.h Move some more code to lib_mtproto. 2019-12-02 16:11:22 +03:00
connection_resolving.cpp Avoid multiple .arg usage as suggested by clazy 2021-03-13 19:08:33 +03:00
connection_resolving.h Move some more code to lib_mtproto. 2019-12-02 16:11:22 +03:00
connection_tcp.cpp Build with QT_NO_KEYWORDS 2021-03-04 12:07:54 +04:00
connection_tcp.h Move some more code to lib_mtproto. 2019-12-02 16:11:22 +03:00
core_types.h Support broadcast mode in voice chats. 2021-03-12 16:58:26 +04:00
dedicated_file_loader.cpp Rename RPCError to MTP::Error. 2021-03-12 16:58:26 +04:00
dedicated_file_loader.h Rename RPCError to MTP::Error. 2021-03-12 16:58:26 +04:00
facade.cpp Remove MTP::MainInstance() global access point. 2020-06-23 21:53:40 +04:00
facade.h Support broadcast mode in voice chats. 2021-03-12 16:58:26 +04:00
mtp_instance.cpp Watch for network availability changes 2021-04-06 16:40:29 +03:00
mtp_instance.h Rename RPCError to MTP::Error. 2021-03-12 16:58:26 +04:00
mtproto_auth_key.cpp Fix destroyed key clearing. 2019-11-20 16:33:45 +03:00
mtproto_auth_key.h Fix destroyed key clearing. 2019-11-20 16:33:45 +03:00
mtproto_concurrent_sender.cpp Rename RPCError to MTP::Error. 2021-03-12 16:58:26 +04:00
mtproto_concurrent_sender.h Rename RPCError to MTP::Error. 2021-03-12 16:58:26 +04:00
mtproto_config.cpp Count all accounts in Core::App().unreadBadge. 2020-06-23 21:53:41 +04:00
mtproto_config.h Keep separate MTP::Config's for separate accounts. 2020-06-23 21:53:41 +04:00
mtproto_dc_options.cpp Get rid of deprecated ranges::view usage 2021-03-13 19:14:58 +03:00
mtproto_dc_options.h Keep separate MTP::Config's for separate accounts. 2020-06-23 21:53:41 +04:00
mtproto_dh_utils.cpp Extract mtproto key generation code. 2019-11-15 16:16:32 +03:00
mtproto_dh_utils.h Extract mtproto key generation code. 2019-11-15 16:16:32 +03:00
mtproto_pch.h Keep separate MTP::Config's for separate accounts. 2020-06-23 21:53:41 +04:00
mtproto_proxy_data.cpp Extract mtproto key generation code. 2019-11-15 16:16:32 +03:00
mtproto_proxy_data.h Extract mtproto key generation code. 2019-11-15 16:16:32 +03:00
mtproto_response.cpp Rename RPCError to MTP::Error. 2021-03-12 16:58:26 +04:00
mtproto_response.h Allow saving and using saved credentials. 2021-04-06 18:41:16 +04:00
sender.h Rename RPCError to MTP::Error. 2021-03-12 16:58:26 +04:00
session.cpp Remove dangling timer in MTP Session 2021-04-12 12:03:15 +03:00
session.h Remove dangling timer in MTP Session 2021-04-12 12:03:15 +03:00
session_private.cpp Use fine grained session timers 2021-04-15 16:20:42 +03:00
session_private.h Use fine grained session timers 2021-04-15 16:20:42 +03:00
special_config_request.cpp Avoid multiple .arg usage as suggested by clazy 2021-03-13 19:08:33 +03:00
special_config_request.h Keep separate MTP::Config's for separate accounts. 2020-06-23 21:53:41 +04:00
type_utils.h Version 1.9.3: Fix build for OS X 10.10-10.11. 2019-12-31 17:52:15 +03:00