kikocis/java-driver public
Changesets · Branches · Tags · Compare
| Changeset | 0fe9369e8f1bb3697421ea61d0486bf3e29ece7fe353709e55acbdab229d297a |
|---|---|
| Author | olim7t <omichallat+github@gmail.com> · 2014-12-18 21:44 +01:00 |
| Committer | olim7t <omichallat+github@gmail.com> · 2014-12-19 00:22 +01:00 |
| Parents | 14b391abab4f |
1 file changed
modified driver-core/src/main/java/com/datastax/driver/core/Connection.java +4 −2
| @@ -754,9 +754,11 @@ | ||
| 754 | 754 | ChannelFuture future = channel.close(); |
| 755 | 755 | future.addListener(new ChannelFutureListener() { |
| 756 | 756 | public void operationComplete(ChannelFuture future) { |
| 757 | - if (future.getCause() != null) | |
| 757 | + factory.allChannels.remove(channel); | |
| 758 | + if (future.getCause() != null) { | |
| 759 | + logger.warn("Error closing channel", future.getCause()); | |
| 758 | 760 | ConnectionCloseFuture.this.setException(future.getCause()); |
| 759 | - else | |
| 761 | + } else | |
| 760 | 762 | ConnectionCloseFuture.this.set(null); |
| 761 | 763 | } |
| 762 | 764 | }); |