Package io.grpc.alts.internal
Class TsiHandshakeHandler
java.lang.Object
io.netty.channel.ChannelHandlerAdapter
io.netty.channel.ChannelInboundHandlerAdapter
io.netty.handler.codec.ByteToMessageDecoder
io.grpc.alts.internal.TsiHandshakeHandler
- All Implemented Interfaces:
io.netty.channel.ChannelHandler,io.netty.channel.ChannelInboundHandler
public final class TsiHandshakeHandler
extends io.netty.handler.codec.ByteToMessageDecoder
Performs The TSI Handshake.
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic classValidates a Tsi Peer object.Nested classes/interfaces inherited from class io.netty.handler.codec.ByteToMessageDecoder
io.netty.handler.codec.ByteToMessageDecoder.CumulatorNested classes/interfaces inherited from interface io.netty.channel.ChannelHandler
io.netty.channel.ChannelHandler.Sharable -
Field Summary
Fields inherited from class io.netty.handler.codec.ByteToMessageDecoder
COMPOSITE_CUMULATOR, MERGE_CUMULATOR -
Constructor Summary
ConstructorsConstructorDescriptionTsiHandshakeHandler(io.netty.channel.ChannelHandler next, NettyTsiHandshaker handshaker, TsiHandshakeHandler.HandshakeValidator handshakeValidator, io.grpc.alts.internal.AsyncSemaphore semaphore, io.grpc.ChannelLogger negotiationLogger) Constructs a TsHandshakeHandler.TsiHandshakeHandler(io.netty.channel.ChannelHandler next, NettyTsiHandshaker handshaker, TsiHandshakeHandler.HandshakeValidator handshakeValidator, io.grpc.ChannelLogger negotiationLogger) Constructs a TsiHandshakeHandler. -
Method Summary
Modifier and TypeMethodDescriptionprotected voidprotected voiddecodeLast(io.netty.channel.ChannelHandlerContext ctx, io.netty.buffer.ByteBuf in, List<Object> out) protected voidhandlerRemoved0(io.netty.channel.ChannelHandlerContext ctx) voiduserEventTriggered(io.netty.channel.ChannelHandlerContext ctx, Object evt) Methods inherited from class io.netty.handler.codec.ByteToMessageDecoder
actualReadableBytes, callDecode, channelInactive, channelRead, channelReadComplete, discardSomeReadBytes, handlerRemoved, internalBuffer, isSingleDecode, setCumulator, setDiscardAfterReads, setSingleDecodeMethods inherited from class io.netty.channel.ChannelInboundHandlerAdapter
channelActive, channelRegistered, channelUnregistered, channelWritabilityChanged, exceptionCaughtMethods inherited from class io.netty.channel.ChannelHandlerAdapter
ensureNotSharable, handlerAdded, isSharableMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface io.netty.channel.ChannelHandler
handlerAdded
-
Constructor Details
-
TsiHandshakeHandler
public TsiHandshakeHandler(io.netty.channel.ChannelHandler next, NettyTsiHandshaker handshaker, TsiHandshakeHandler.HandshakeValidator handshakeValidator, io.grpc.ChannelLogger negotiationLogger) Constructs a TsiHandshakeHandler. -
TsiHandshakeHandler
public TsiHandshakeHandler(io.netty.channel.ChannelHandler next, NettyTsiHandshaker handshaker, TsiHandshakeHandler.HandshakeValidator handshakeValidator, io.grpc.alts.internal.AsyncSemaphore semaphore, io.grpc.ChannelLogger negotiationLogger) Constructs a TsHandshakeHandler. If a semaphore is provided, a permit from the semaphore is required to start the handshake and is returned when the handshake ends.
-
-
Method Details
-
decodeLast
protected void decodeLast(io.netty.channel.ChannelHandlerContext ctx, io.netty.buffer.ByteBuf in, List<Object> out) throws Exception - Overrides:
decodeLastin classio.netty.handler.codec.ByteToMessageDecoder- Throws:
Exception
-
decode
protected void decode(io.netty.channel.ChannelHandlerContext ctx, io.netty.buffer.ByteBuf in, List<Object> out) throws Exception - Specified by:
decodein classio.netty.handler.codec.ByteToMessageDecoder- Throws:
Exception
-
userEventTriggered
public void userEventTriggered(io.netty.channel.ChannelHandlerContext ctx, Object evt) throws Exception - Specified by:
userEventTriggeredin interfaceio.netty.channel.ChannelInboundHandler- Overrides:
userEventTriggeredin classio.netty.handler.codec.ByteToMessageDecoder- Throws:
Exception
-
handlerRemoved0
- Overrides:
handlerRemoved0in classio.netty.handler.codec.ByteToMessageDecoder- Throws:
Exception
-