Package com.linecorp.armeria.client
Class SessionProtocolNegotiationCache
- java.lang.Object
-
- com.linecorp.armeria.client.SessionProtocolNegotiationCache
-
public final class SessionProtocolNegotiationCache extends Object
Keeps the recentSessionProtocol
negotiation failures. It is a LRU cache which keeps at most 64k 'host name + port' pairs.
-
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static void
clear()
Clears the cache.static boolean
isUnsupported(SocketAddress remoteAddress, SessionProtocol protocol)
Returnstrue
if the specifiedremoteAddress
is known to have no support for the specifiedSessionProtocol
.static void
setUnsupported(SocketAddress remoteAddress, SessionProtocol protocol)
Updates the cache with the information that the specifiedremoteAddress
does not support the specifiedSessionProtocol
.
-
-
-
Method Detail
-
isUnsupported
public static boolean isUnsupported(SocketAddress remoteAddress, SessionProtocol protocol)
Returnstrue
if the specifiedremoteAddress
is known to have no support for the specifiedSessionProtocol
.
-
setUnsupported
public static void setUnsupported(SocketAddress remoteAddress, SessionProtocol protocol)
Updates the cache with the information that the specifiedremoteAddress
does not support the specifiedSessionProtocol
.
-
clear
public static void clear()
Clears the cache.
-
-