netty: client transport needs to flush fence operation (#3137)

This the cause of the flakey serverNotListening test, because the
NOOP_MESSAGE just sits around the pipeline. As a result, the
listener does not fire within the 1s verification timeout.
This commit is contained in:
zpencer 2017-06-28 10:23:48 -07:00 committed by GitHub
parent 4b94237bb9
commit f559cf4adf
1 changed files with 1 additions and 1 deletions

View File

@ -224,7 +224,7 @@ class NettyClientTransport implements ConnectionClientTransport {
channel.connect(address);
// This write will have no effect, yet it will only complete once the negotiationHandler
// flushes any pending writes.
channel.write(NettyClientHandler.NOOP_MESSAGE).addListener(new ChannelFutureListener() {
channel.writeAndFlush(NettyClientHandler.NOOP_MESSAGE).addListener(new ChannelFutureListener() {
@Override
public void operationComplete(ChannelFuture future) throws Exception {
if (!future.isSuccess()) {