mirror of
https://github.com/processone/ejabberd.git
synced 2024-12-26 17:38:45 +01:00
Merge pull request #283 from weiss/allow-unlimited-ack-queue
Support "max_ack_queue: infinity"
This commit is contained in:
commit
33e0bf1c19
@ -307,6 +307,7 @@ init([{SockMod, Socket}, Opts]) ->
|
||||
end,
|
||||
MaxAckQueue = case proplists:get_value(max_ack_queue, Opts) of
|
||||
Limit when is_integer(Limit), Limit > 0 -> Limit;
|
||||
infinity -> infinity;
|
||||
_ -> 500
|
||||
end,
|
||||
ResumeTimeout = case proplists:get_value(resume_timeout, Opts) of
|
||||
@ -2789,9 +2790,7 @@ mgmt_queue_drop(StateData, NumHandled) ->
|
||||
StateData#state.mgmt_queue),
|
||||
StateData#state{mgmt_queue = NewQueue}.
|
||||
|
||||
check_queue_length(#state{mgmt_max_queue = Limit} = StateData)
|
||||
when Limit == infinity;
|
||||
Limit == unlimited ->
|
||||
check_queue_length(#state{mgmt_max_queue = infinity} = StateData) ->
|
||||
StateData;
|
||||
check_queue_length(#state{mgmt_queue = Queue,
|
||||
mgmt_max_queue = Limit} = StateData) ->
|
||||
|
Loading…
Reference in New Issue
Block a user