Class NettySessionInitializer

java.lang.Object
org.jivesoftware.openfire.nio.NettySessionInitializer

public class NettySessionInitializer extends Object
Initialises an outgoing netty channel for outbound S2S
  • Field Details

    • GRACEFUL_SHUTDOWN_QUIET_PERIOD

      public static final SystemProperty<Duration> GRACEFUL_SHUTDOWN_QUIET_PERIOD
      The inactivity duration after which a Netty executor can be shutdown gracefully.
    • GRACEFUL_SHUTDOWN_TIMEOUT

      public static final SystemProperty<Duration> GRACEFUL_SHUTDOWN_TIMEOUT
      The maximum amount of time to wait until a Netty executor is shutdown regardless if a task was submitted during the quiet period.
  • Constructor Details

    • NettySessionInitializer

      public NettySessionInitializer(DomainPair domainPair, int port)
  • Method Details

    • startSharedResources

      public static void startSharedResources()
      Initializes the shared Netty thread pools for outbound S2S connections. Should be called once during startup of the corresponding S2S networking code.
    • stopSharedResources

      public static void stopSharedResources()
      Shuts down the shared Netty thread pools for outbound S2S connections. This method blocks until all resources are shut down. Should be called once during shutdown of the corresponding S2S networking code.
    • init

      public Future<LocalSession> init(ConnectionListener listener)
    • stop

      public void stop()
    • toString

      public String toString()
      Overrides:
      toString in class Object