summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorMichael Klishin <michael@clojurewerkz.org>2016-01-29 17:13:53 +0300
committerMichael Klishin <michael@clojurewerkz.org>2016-01-29 17:13:53 +0300
commit4f7da6bef9f9b273c9749739275b1a12ab3be91c (patch)
tree43abcade1daa5c8f3b6bf0760e9201d6ffe43317 /src
parent548c1ca6bf34056f039febdbe395de50f39a2d06 (diff)
parent6aba71548f60227d2d927facdbe9e8f0c529ab86 (diff)
downloadrabbitmq-server-git-4f7da6bef9f9b273c9749739275b1a12ab3be91c.tar.gz
Merge branch 'rabbitmq-server-541' into stable
This is only a part of what #541 is supposed to cover but it already helped in a particular node shutdown lockup we've observed => worth merging earlier. Per discussion with @dcorbacho.
Diffstat (limited to 'src')
-rw-r--r--src/rabbit_channel_sup.erl10
1 files changed, 6 insertions, 4 deletions
diff --git a/src/rabbit_channel_sup.erl b/src/rabbit_channel_sup.erl
index 047fce853f..7aa369b6ca 100644
--- a/src/rabbit_channel_sup.erl
+++ b/src/rabbit_channel_sup.erl
@@ -53,6 +53,8 @@
-endif.
+-define(FAIR_WAIT, 70000).
+
%%----------------------------------------------------------------------------
start_link({tcp, Sock, Channel, FrameMax, ReaderPid, ConnName, Protocol, User,
@@ -69,7 +71,7 @@ start_link({tcp, Sock, Channel, FrameMax, ReaderPid, ConnName, Protocol, User,
[Channel, ReaderPid, WriterPid, ReaderPid, ConnName,
Protocol, User, VHost, Capabilities, Collector,
LimiterPid]},
- intrinsic, ?MAX_WAIT, worker, [rabbit_channel]}),
+ intrinsic, ?FAIR_WAIT, worker, [rabbit_channel]}),
{ok, AState} = rabbit_command_assembler:init(Protocol),
{ok, SupPid, {ChannelPid, AState}};
start_link({direct, Channel, ClientChannelPid, ConnPid, ConnName, Protocol,
@@ -84,7 +86,7 @@ start_link({direct, Channel, ClientChannelPid, ConnPid, ConnName, Protocol,
[Channel, ClientChannelPid, ClientChannelPid, ConnPid,
ConnName, Protocol, User, VHost, Capabilities, Collector,
LimiterPid]},
- intrinsic, ?MAX_WAIT, worker, [rabbit_channel]}),
+ intrinsic, ?FAIR_WAIT, worker, [rabbit_channel]}),
{ok, SupPid, {ChannelPid, none}}.
%%----------------------------------------------------------------------------
@@ -95,8 +97,8 @@ init(Type) ->
child_specs({tcp, Sock, Channel, FrameMax, ReaderPid, Protocol, Identity}) ->
[{writer, {rabbit_writer, start_link,
[Sock, Channel, FrameMax, Protocol, ReaderPid, Identity, true]},
- intrinsic, ?MAX_WAIT, worker, [rabbit_writer]}
+ intrinsic, ?FAIR_WAIT, worker, [rabbit_writer]}
| child_specs({direct, Identity})];
child_specs({direct, Identity}) ->
[{limiter, {rabbit_limiter, start_link, [Identity]},
- transient, ?MAX_WAIT, worker, [rabbit_limiter]}].
+ transient, ?FAIR_WAIT, worker, [rabbit_limiter]}].