Class NettyServerConnectionHandler

  • All Implemented Interfaces:
    io.netty.channel.ChannelHandler, io.netty.channel.ChannelInboundHandler

    public class NettyServerConnectionHandler
    extends NettyConnectionHandler
    Server-specific ConnectionHandler that knows which subclass of StanzaHandler should be created and how to build and configure a NettyConnection.
    Author:
    Matthew Vivian, Alex Gidman
    • Field Detail

      • IDLE_TIMEOUT_PROPERTY

        public static final SystemProperty<Duration> IDLE_TIMEOUT_PROPERTY
        How much time the server will wait without receiving an inbound message until it is classed as an idle connection and closed.
      • BACKUP_PACKET_DELIVERY_ENABLED

        public static final SystemProperty<Boolean> BACKUP_PACKET_DELIVERY_ENABLED
        Enable / disable backup delivery of stanzas to the XMPP server itself when a stanza failed to be delivered on a server-to-server connection. When disabled, stanzas that can not be delivered on the connection are discarded.
    • Constructor Detail

    • Method Detail

      • handlerAdded

        public void handlerAdded​(io.netty.channel.ChannelHandlerContext ctx)
        Specified by:
        handlerAdded in interface io.netty.channel.ChannelHandler
        Overrides:
        handlerAdded in class NettyConnectionHandler
      • getMaxIdleTime

        public int getMaxIdleTime()
        Description copied from class: NettyConnectionHandler
        Returns the max number of seconds a connection can be idle (both ways) before being closed.

        Specified by:
        getMaxIdleTime in class NettyConnectionHandler
        Returns:
        the max number of seconds a connection can be idle.