Package io.grpc.netty
Class ProtocolNegotiators.ProxyProtocolNegotiationHandler
java.lang.Object
io.netty.channel.ChannelHandlerAdapter
io.netty.channel.ChannelInboundHandlerAdapter
io.netty.channel.ChannelDuplexHandler
io.grpc.netty.ProtocolNegotiators.ProtocolNegotiationHandler
io.grpc.netty.ProtocolNegotiators.ProxyProtocolNegotiationHandler
- All Implemented Interfaces:
io.netty.channel.ChannelHandler
,io.netty.channel.ChannelInboundHandler
,io.netty.channel.ChannelOutboundHandler
- Enclosing class:
ProtocolNegotiators
static final class ProtocolNegotiators.ProxyProtocolNegotiationHandler
extends ProtocolNegotiators.ProtocolNegotiationHandler
A Proxy handler follows
ProtocolNegotiators.ProtocolNegotiationHandler
pattern. Upon successful proxy
connection, this handler will install next
handler which should be a handler from
other type of ProtocolNegotiator
to continue negotiating protocol using proxy.-
Nested Class Summary
Nested classes/interfaces inherited from interface io.netty.channel.ChannelHandler
io.netty.channel.ChannelHandler.Sharable
-
Field Summary
Fields -
Constructor Summary
ConstructorsConstructorDescriptionProxyProtocolNegotiationHandler
(SocketAddress address, String userName, String password, io.netty.channel.ChannelHandler next, ChannelLogger negotiationLogger) -
Method Summary
Modifier and TypeMethodDescriptionprotected void
protocolNegotiationEventTriggered
(io.netty.channel.ChannelHandlerContext ctx) protected void
userEventTriggered0
(io.netty.channel.ChannelHandlerContext ctx, Object evt) Methods inherited from class io.grpc.netty.ProtocolNegotiators.ProtocolNegotiationHandler
fireProtocolNegotiationEvent, getProtocolNegotiationEvent, handlerAdded, handlerAdded0, replaceProtocolNegotiationEvent, userEventTriggered
Methods inherited from class io.netty.channel.ChannelDuplexHandler
bind, close, connect, deregister, disconnect, flush, read, write
Methods inherited from class io.netty.channel.ChannelInboundHandlerAdapter
channelActive, channelInactive, channelRead, channelReadComplete, channelRegistered, channelUnregistered, channelWritabilityChanged, exceptionCaught
Methods inherited from class io.netty.channel.ChannelHandlerAdapter
ensureNotSharable, handlerRemoved, isSharable
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface io.netty.channel.ChannelHandler
handlerRemoved
-
Field Details
-
address
-
userName
-
password
-
-
Constructor Details
-
ProxyProtocolNegotiationHandler
public ProxyProtocolNegotiationHandler(SocketAddress address, @Nullable String userName, @Nullable String password, io.netty.channel.ChannelHandler next, ChannelLogger negotiationLogger)
-
-
Method Details
-
protocolNegotiationEventTriggered
protected void protocolNegotiationEventTriggered(io.netty.channel.ChannelHandlerContext ctx) - Overrides:
protocolNegotiationEventTriggered
in classProtocolNegotiators.ProtocolNegotiationHandler
-
userEventTriggered0
protected void userEventTriggered0(io.netty.channel.ChannelHandlerContext ctx, Object evt) throws Exception - Overrides:
userEventTriggered0
in classProtocolNegotiators.ProtocolNegotiationHandler
- Throws:
Exception
-