public void invokeOnewayImpl(final Channel channel, final RemotingCommand request, final long timeoutMillis)
throws RemotingTimeoutException, RemotingSendRequestException {
try {
channel.writeAndFlush(request).addListener(new ChannelFutureListener() {
@Override
public void operationComplete(ChannelFuture f) throws Exception {
if (!f.isSuccess()) {
log.warn("send a request command to channel <" + channel.remoteAddress() + "> failed.");
}
}
});
} catch (Exception e) {
log.warn("write send a request command to channel <" + channel.remoteAddress() + "> failed.");
throw new RemotingSendRequestException(RemotingHelper.parseChannelRemoteAddr(channel), e);
}
}
NettyRemotingAbstract.java 文件源码
java
阅读 24
收藏 0
点赞 0
评论 0
项目:elephant
作者:
评论列表
文章目录