public class OutboundConnectionQueue
extends io.netty.channel.ChannelInboundHandlerAdapter
| Constructor and Description |
|---|
OutboundConnectionQueue(io.netty.channel.Channel channel,
RemoteReceiver receiver,
NetworkConnectionManager connectionManager,
int closeAfterIdleForMs) |
| Modifier and Type | Method and Description |
|---|---|
void |
channelWritabilityChanged(io.netty.channel.ChannelHandlerContext ctx) |
boolean |
enqueue(Envelope env)
Enqueues an envelope to be sent.
|
int |
getNumQueuedEnvelopes() |
String |
toString() |
void |
userEventTriggered(io.netty.channel.ChannelHandlerContext ctx,
Object event) |
channelActive, channelInactive, channelRead, channelReadComplete, channelRegistered, channelUnregistered, exceptionCaughthandlerAdded, handlerRemoved, isSharablepublic OutboundConnectionQueue(io.netty.channel.Channel channel,
RemoteReceiver receiver,
NetworkConnectionManager connectionManager,
int closeAfterIdleForMs)
public boolean enqueue(Envelope env)
false, the channel cannot be used to enqueue
envelopes any more and the caller needs to establish a new connection to the target.
The current envelope needs to be enqueued at the new channel.env - the envelope to be sentpublic void userEventTriggered(io.netty.channel.ChannelHandlerContext ctx,
Object event)
throws Exception
userEventTriggered in interface io.netty.channel.ChannelInboundHandleruserEventTriggered in class io.netty.channel.ChannelInboundHandlerAdapterExceptionpublic void channelWritabilityChanged(io.netty.channel.ChannelHandlerContext ctx)
throws Exception
channelWritabilityChanged in interface io.netty.channel.ChannelInboundHandlerchannelWritabilityChanged in class io.netty.channel.ChannelInboundHandlerAdapterExceptionpublic int getNumQueuedEnvelopes()
Copyright © 2014 The Apache Software Foundation. All rights reserved.