Skip to content

Commit 59eab30

Browse files
committed
Use _rpcTimeout in ChannelN#close
Instead of fixed 10-second timeout. Fixes #1907
1 parent 7e7eac5 commit 59eab30

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

src/main/java/com/rabbitmq/client/impl/ChannelN.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -631,8 +631,8 @@ public AMQCommand transformReply(AMQCommand command) {
631631
// we wait for the reply. We ignore the result.
632632
// (It's NOT always close-ok.)
633633
notify = true;
634-
// do not wait indefinitely
635-
k.getReply(10000);
634+
int closeTimeout = _rpcTimeout == NO_RPC_TIMEOUT ? 10000 : _rpcTimeout;
635+
k.getReply(closeTimeout);
636636
} catch (TimeoutException ise) {
637637
if (!abort)
638638
throw ise;

0 commit comments

Comments
 (0)