Class HttpConnectionOverHTTP2
java.lang.Object
org.eclipse.jetty.client.transport.HttpConnection
org.eclipse.jetty.http2.client.transport.internal.HttpConnectionOverHTTP2
- All Implemented Interfaces:
Closeable
,AutoCloseable
,Connection
,ConnectionPool.MaxMultiplexable
,ConnectionPool.MaxUsable
,IConnection
,Attachable
,Sweeper.Sweepable
public class HttpConnectionOverHTTP2
extends HttpConnection
implements Sweeper.Sweepable, ConnectionPool.MaxMultiplexable, ConnectionPool.MaxUsable
-
Constructor Summary
ConstructorDescriptionHttpConnectionOverHTTP2
(Destination destination, Session session, HTTP2Connection connection) -
Method Summary
Modifier and TypeMethodDescriptionprotected HttpChannelOverHTTP2
void
close()
protected void
protected Iterator<HttpChannel>
int
int
boolean
isClosed()
boolean
protected HttpChannelOverHTTP2
protected void
normalizeRequest
(HttpRequest request) boolean
onIdleTimeout
(long idleTimeout, Throwable failure) protected boolean
release
(HttpChannelOverHTTP2 channel) send
(HttpExchange exchange) void
setRecycleHttpChannels
(boolean recycleHttpChannels) boolean
sweep()
toString()
void
Methods inherited from class org.eclipse.jetty.client.transport.HttpConnection
destroy, getAttachment, getHttpClient, getHttpDestination, send, send, setAttachment
-
Constructor Details
-
HttpConnectionOverHTTP2
public HttpConnectionOverHTTP2(Destination destination, Session session, HTTP2Connection connection)
-
-
Method Details
-
getSession
-
getLocalSocketAddress
- Specified by:
getLocalSocketAddress
in interfaceConnection
- Returns:
- the local socket address associated with the connection
-
getRemoteSocketAddress
- Specified by:
getRemoteSocketAddress
in interfaceConnection
- Returns:
- the remote socket address associated with the connection
-
getSslSessionData
- Specified by:
getSslSessionData
in interfaceConnection
- Returns:
- the
EndPoint.SslSessionData
associated with the connection, ornull
if the connection is not secure.
-
isRecycleHttpChannels
public boolean isRecycleHttpChannels() -
setRecycleHttpChannels
public void setRecycleHttpChannels(boolean recycleHttpChannels) -
getMaxMultiplex
public int getMaxMultiplex()- Specified by:
getMaxMultiplex
in interfaceConnectionPool.MaxMultiplexable
- Returns:
- the max number of requests multiplexable on a single connection
-
getMaxUsage
public int getMaxUsage()- Specified by:
getMaxUsage
in interfaceConnectionPool.MaxUsable
- Returns:
- the max number of requests on a single connection
-
getHttpChannels
- Specified by:
getHttpChannels
in classHttpConnection
-
send
- Specified by:
send
in interfaceIConnection
-
upgrade
-
normalizeRequest
- Overrides:
normalizeRequest
in classHttpConnection
-
acquireHttpChannel
-
newHttpChannel
-
release
-
onIdleTimeout
- Overrides:
onIdleTimeout
in classHttpConnection
-
close
public void close()- Specified by:
close
in interfaceAutoCloseable
- Specified by:
close
in interfaceCloseable
- Specified by:
close
in interfaceConnection
-
close
-
isClosed
public boolean isClosed()- Specified by:
isClosed
in interfaceConnection
- Returns:
- whether this connection has been closed
- See Also:
-
sweep
public boolean sweep()- Specified by:
sweep
in interfaceSweeper.Sweepable
- Returns:
- whether this resource should be swept
-
toString
- Overrides:
toString
in classHttpConnection
-