Package org.eclipse.jetty.http2.server
Class HTTP2ServerConnection
java.lang.Object
org.eclipse.jetty.io.AbstractConnection
org.eclipse.jetty.http2.HTTP2Connection
org.eclipse.jetty.http2.server.HTTP2ServerConnection
- All Implemented Interfaces:
Closeable,AutoCloseable,Parser.Listener,ServerParser.Listener,Connection,Connection.UpgradeTo,WriteFlusher.Listener
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionprotected classNested classes/interfaces inherited from class org.eclipse.jetty.http2.HTTP2Connection
HTTP2Connection.HTTP2ProducerNested classes/interfaces inherited from interface org.eclipse.jetty.io.Connection
Connection.Listener, Connection.UpgradeFrom, Connection.UpgradeToNested classes/interfaces inherited from interface org.eclipse.jetty.http2.parser.Parser.Listener
Parser.Listener.Adapter, Parser.Listener.WrapperNested classes/interfaces inherited from interface org.eclipse.jetty.http2.parser.ServerParser.Listener
ServerParser.Listener.Adapter, ServerParser.Listener.Wrapper -
Field Summary
Fields inherited from class org.eclipse.jetty.http2.HTTP2Connection
LOG -
Constructor Summary
ConstructorsConstructorDescriptionHTTP2ServerConnection(RetainableByteBufferPool retainableByteBufferPool, Executor executor, EndPoint endPoint, HttpConfiguration httpConfig, HTTP2ServerSession session, int inputBufferSize, ServerSessionListener listener) -
Method Summary
Modifier and TypeMethodDescriptionbooleanstatic booleanisSupportedProtocol(String protocol) newServerHttpChannelOverHTTP2(Connector connector, HttpConfiguration httpConfig, HttpTransportOverHTTP2 transport) voidvoidonNewStream(Connector connector, IStream stream, HeadersFrame frame) voidonOpen()Callback method invoked when this connection is opened.voidvoidonSessionFailure(Throwable failure, Callback callback) booleanonSessionTimeout(Throwable failure) voidonStreamFailure(IStream stream, Throwable failure, Callback callback) booleanonStreamTimeout(IStream stream, Throwable failure) voidonTrailers(IStream stream, HeadersFrame frame) voidpush(Connector connector, IStream stream, MetaData.Request request) voidsetRecycleHttpChannels(boolean recycleHttpChannels) booleanupgrade(MetaData.Request request, HttpFields.Mutable responseFields) Methods inherited from class org.eclipse.jetty.http2.HTTP2Connection
close, dispatch, getBytesIn, getBytesOut, getMessagesIn, getMessagesOut, getSession, isUseInputDirectByteBuffers, isUseOutputDirectByteBuffers, offerTask, onClose, onConnectionFailure, onData, onFillable, onFlushed, onGoAway, onHeaders, onIdleExpired, onPing, onPriority, onPushPromise, onReset, onSettings, onStreamFailure, onUpgradeTo, onWindowUpdate, produce, setUseInputDirectByteBuffers, setUseOutputDirectByteBuffersMethods inherited from class org.eclipse.jetty.io.AbstractConnection
addEventListener, failedCallback, fillInterested, getCreatedTimeStamp, getEndPoint, getExecutor, getInputBufferSize, isFillInterested, onFillInterestedFailed, onReadTimeout, removeEventListener, setInputBufferSize, toConnectionString, toString, tryFillInterestedMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitMethods inherited from interface org.eclipse.jetty.http2.parser.Parser.Listener
onConnectionFailure, onData, onGoAway, onHeaders, onPing, onPriority, onPushPromise, onReset, onSettings, onStreamFailure, onWindowUpdate
-
Constructor Details
-
HTTP2ServerConnection
public HTTP2ServerConnection(RetainableByteBufferPool retainableByteBufferPool, Executor executor, EndPoint endPoint, HttpConfiguration httpConfig, HTTP2ServerSession session, int inputBufferSize, ServerSessionListener listener)
-
-
Method Details
-
isSupportedProtocol
- Parameters:
protocol- An HTTP2 protocol variant- Returns:
- True if the protocol version is supported
-
isRecycleHttpChannels
public boolean isRecycleHttpChannels() -
setRecycleHttpChannels
public void setRecycleHttpChannels(boolean recycleHttpChannels) -
onOpen
public void onOpen()Description copied from interface:ConnectionCallback method invoked when this connection is opened.
Creators of the connection implementation are responsible for calling this method.
- Specified by:
onOpenin interfaceConnection- Overrides:
onOpenin classHTTP2Connection
-
onPreface
public void onPreface()- Specified by:
onPrefacein interfaceServerParser.Listener
-
onNewStream
-
onData
-
onTrailers
-
onStreamTimeout
-
onStreamFailure
-
onSessionTimeout
-
onSessionFailure
-
push
-
newServerHttpChannelOverHTTP2
protected HTTP2ServerConnection.ServerHttpChannelOverHTTP2 newServerHttpChannelOverHTTP2(Connector connector, HttpConfiguration httpConfig, HttpTransportOverHTTP2 transport) -
upgrade
-