ObservableConnection<String, String> conn = pool.acquire().toBlocking().last();
Assert.assertEquals("Unexpected pool idle count.", 0, stats.getIdleCount());
Assert.assertEquals("Unexpected pool in-use count.", 1, stats.getInUseCount());
Assert.assertEquals("Unexpected pool total connections count.", 1, stats.getTotalConnectionCount());
final CountDownLatch writeFinishLatch = new CountDownLatch(1);
conn.writeAndFlush("Hi").finallyDo(new Action0() {
@Override
public void call() {
writeFinishLatch.countDown();
}
});