mirror of
https://github.com/processone/ejabberd.git
synced 2024-11-22 16:20:52 +01:00
Make hibernate timeouts configurable
Two *global* options added: c2s_hibernate and receiver_hibernate. Default if not specified is 90000, the previous hardcoded value.
This commit is contained in:
parent
e207d0af56
commit
942072cf9d
@ -133,7 +133,7 @@
|
||||
%% session:
|
||||
-define(C2S_OPEN_TIMEOUT, 60000).
|
||||
|
||||
-define(C2S_HIBERNATE_TIMEOUT, 90000).
|
||||
-define(C2S_HIBERNATE_TIMEOUT, ejabberd_config:get_option(c2s_hibernate, fun(X) when is_integer(X); X == hibernate-> X end, 90000)).
|
||||
|
||||
-define(STREAM_HEADER,
|
||||
<<"<?xml version='1.0'?><stream:stream "
|
||||
|
@ -56,7 +56,8 @@
|
||||
xml_stream_state :: fxml_stream:xml_stream_state(),
|
||||
timeout = infinity:: timeout()}).
|
||||
|
||||
-define(HIBERNATE_TIMEOUT, 90000).
|
||||
-define(HIBERNATE_TIMEOUT, ejabberd_config:get_option(receiver_hibernate, fun(X) when is_integer(X); X == hibernate-> X end, 90000)).
|
||||
|
||||
|
||||
-spec start_link(inet:socket(), atom(), shaper:shaper(),
|
||||
non_neg_integer() | infinity) -> ignore |
|
||||
|
Loading…
Reference in New Issue
Block a user