Class HttpConnectionOverHTTP2
- java.lang.Object
-
- org.eclipse.jetty.client.HttpConnection
-
- org.eclipse.jetty.http2.client.http.HttpConnectionOverHTTP2
-
- All Implemented Interfaces:
java.io.Closeable
,java.lang.AutoCloseable
,Connection
,ConnectionPool.Multiplexable
,IConnection
,Attachable
,Sweeper.Sweepable
public class HttpConnectionOverHTTP2 extends HttpConnection implements Sweeper.Sweepable, ConnectionPool.Multiplexable
-
-
Constructor Summary
Constructors Constructor Description HttpConnectionOverHTTP2(HttpDestination destination, Session session)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected HttpChannelOverHTTP2
acquireHttpChannel()
void
close()
protected void
close(java.lang.Throwable failure)
protected java.util.Iterator<HttpChannel>
getHttpChannels()
int
getMaxMultiplex()
Session
getSession()
boolean
isClosed()
boolean
isRecycleHttpChannels()
protected HttpChannelOverHTTP2
newHttpChannel()
protected void
normalizeRequest(HttpRequest request)
boolean
onIdleTimeout(long idleTimeout, java.lang.Throwable failure)
protected boolean
release(HttpChannelOverHTTP2 channel)
SendFailure
send(HttpExchange exchange)
void
setRecycleHttpChannels(boolean recycleHttpChannels)
boolean
sweep()
java.lang.String
toString()
void
upgrade(java.util.Map<java.lang.String,java.lang.Object> context)
-
Methods inherited from class org.eclipse.jetty.client.HttpConnection
destroy, getAttachment, getHttpClient, getHttpDestination, send, send, setAttachment
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface org.eclipse.jetty.client.ConnectionPool.Multiplexable
setMaxMultiplex
-
-
-
-
Constructor Detail
-
HttpConnectionOverHTTP2
public HttpConnectionOverHTTP2(HttpDestination destination, Session session)
-
-
Method Detail
-
getSession
public Session getSession()
-
isRecycleHttpChannels
public boolean isRecycleHttpChannels()
-
setRecycleHttpChannels
public void setRecycleHttpChannels(boolean recycleHttpChannels)
-
getMaxMultiplex
public int getMaxMultiplex()
- Specified by:
getMaxMultiplex
in interfaceConnectionPool.Multiplexable
- Returns:
- the max number of requests multiplexable on a single connection
-
getHttpChannels
protected java.util.Iterator<HttpChannel> getHttpChannels()
- Specified by:
getHttpChannels
in classHttpConnection
-
send
public SendFailure send(HttpExchange exchange)
- Specified by:
send
in interfaceIConnection
-
upgrade
public void upgrade(java.util.Map<java.lang.String,java.lang.Object> context)
-
normalizeRequest
protected void normalizeRequest(HttpRequest request)
- Overrides:
normalizeRequest
in classHttpConnection
-
acquireHttpChannel
protected HttpChannelOverHTTP2 acquireHttpChannel()
-
newHttpChannel
protected HttpChannelOverHTTP2 newHttpChannel()
-
release
protected boolean release(HttpChannelOverHTTP2 channel)
-
onIdleTimeout
public boolean onIdleTimeout(long idleTimeout, java.lang.Throwable failure)
- Overrides:
onIdleTimeout
in classHttpConnection
-
close
public void close()
- Specified by:
close
in interfacejava.lang.AutoCloseable
- Specified by:
close
in interfacejava.io.Closeable
- Specified by:
close
in interfaceConnection
-
close
protected void close(java.lang.Throwable failure)
-
isClosed
public boolean isClosed()
- Specified by:
isClosed
in interfaceConnection
- Returns:
- whether this connection has been closed
- See Also:
Connection.close()
-
sweep
public boolean sweep()
- Specified by:
sweep
in interfaceSweeper.Sweepable
- Returns:
- whether this resource should be swept
-
toString
public java.lang.String toString()
- Overrides:
toString
in classHttpConnection
-
-