Class DefaultTransportFactory

java.lang.Object
org.infinispan.hotrod.impl.transport.netty.DefaultTransportFactory
All Implemented Interfaces:
TransportFactory

public class DefaultTransportFactory extends Object implements TransportFactory
Default implementation of the TransportFactory interface which uses epoll if available and nio otherwise.
  • Constructor Details

    • DefaultTransportFactory

      public DefaultTransportFactory()
  • Method Details

    • socketChannelClass

      public Class<? extends io.netty.channel.socket.SocketChannel> socketChannelClass()
      Description copied from interface: TransportFactory
      Returns the Netty SocketChannel class to use in the transport.
      Specified by:
      socketChannelClass in interface TransportFactory
    • createEventLoopGroup

      public io.netty.channel.EventLoopGroup createEventLoopGroup(int maxExecutors, ExecutorService executorService)
      Description copied from interface: TransportFactory
      Creates an event loop group
      Specified by:
      createEventLoopGroup in interface TransportFactory
      Parameters:
      maxExecutors - the maximum number of executors
      executorService - the executor service to use
      Returns:
      an instance of Netty's EventLoopGroup
    • datagramChannelClass

      public Class<? extends io.netty.channel.socket.DatagramChannel> datagramChannelClass()
      Description copied from interface: TransportFactory
      Returns the Netty DatagramChannel class to use for DNS resolution.
      Specified by:
      datagramChannelClass in interface TransportFactory