Class ChannelRecord

java.lang.Object
java.util.concurrent.CompletableFuture<io.netty.channel.Channel>
org.infinispan.hotrod.impl.transport.netty.ChannelRecord
All Implemented Interfaces:
io.netty.util.concurrent.GenericFutureListener<io.netty.channel.ChannelFuture>, CompletionStage<io.netty.channel.Channel>, Future<io.netty.channel.Channel>, EventListener

public class ChannelRecord extends CompletableFuture<io.netty.channel.Channel> implements io.netty.util.concurrent.GenericFutureListener<io.netty.channel.ChannelFuture>
This class serves multiple purposes: 1) Activation: this extends CompletableFuture which is completed once the connection and initial handshake are completed. 2) Storage for unresolved address and pool info.
  • Method Details

    • of

      public static ChannelRecord of(io.netty.channel.Channel channel)
    • getUnresolvedAddress

      public SocketAddress getUnresolvedAddress()
    • complete

      public boolean complete(io.netty.channel.Channel channel)
      Overrides:
      complete in class CompletableFuture<io.netty.channel.Channel>
    • operationComplete

      public void operationComplete(io.netty.channel.ChannelFuture future) throws Exception
      Specified by:
      operationComplete in interface io.netty.util.concurrent.GenericFutureListener<io.netty.channel.ChannelFuture>
      Throws:
      Exception
    • isIdle

      public boolean isIdle()
    • setIdleAndIsClosed

      public boolean setIdleAndIsClosed()
    • closeAndWasIdle

      public boolean closeAndWasIdle()
    • release

      public void release(io.netty.channel.Channel channel)