Class SessionProtocolNegotiationCache

java.lang.Object
com.linecorp.armeria.client.SessionProtocolNegotiationCache

public final class SessionProtocolNegotiationCache
extends Object
Keeps the recent SessionProtocol negotiation failures. It is a LRU cache which keeps at most 64k 'host name + port' pairs.
  • Method Details

    • isUnsupported

      public static boolean isUnsupported​(Endpoint endpointWithPort, SessionProtocol protocol)
      Returns true if the specified Endpoint is known to have no support for the specified SessionProtocol.
    • isUnsupported

      public static boolean isUnsupported​(SocketAddress remoteAddress, SessionProtocol protocol)
      Returns true if the specified remoteAddress is known to have no support for the specified SessionProtocol.
    • setUnsupported

      public static void setUnsupported​(SocketAddress remoteAddress, SessionProtocol protocol)
      Updates the cache with the information that the specified remoteAddress does not support the specified SessionProtocol.
    • clear

      public static void clear()
      Clears the cache.