Class AbstractConnectorHttpClientTransport.ClientSelectorManager

    • Constructor Detail

      • ClientSelectorManager

        protected ClientSelectorManager​(HttpClient client,
                                        int selectors)
    • Method Detail

      • newConnection

        public Connection newConnection​(java.nio.channels.SelectableChannel channel,
                                        EndPoint endPoint,
                                        java.lang.Object attachment)
                                 throws java.io.IOException
        Description copied from class: SelectorManager

        Factory method to create Connection.

        Specified by:
        newConnection in class SelectorManager
        Parameters:
        channel - the channel associated to the connection
        endPoint - the endpoint
        attachment - the attachment
        Returns:
        a new connection
        Throws:
        java.io.IOException - if unable to create new connection
      • connectionFailed

        protected void connectionFailed​(java.nio.channels.SelectableChannel channel,
                                        java.lang.Throwable x,
                                        java.lang.Object attachment)
        Description copied from class: SelectorManager

        Callback method invoked when a non-blocking connect cannot be completed.

        By default it just logs with level warning.

        Overrides:
        connectionFailed in class SelectorManager
        Parameters:
        channel - the channel that attempted the connect
        x - the exception that caused the connect to fail
        attachment - the attachment object associated at registration