Top Inners Fields Constructors Methods
org.eclipse.jetty.http2.server

public abstract Class AbstractHTTP2ServerConnectionFactory

extends AbstractConnectionFactory
Class Inheritance
Known Direct Subclasses
org.eclipse.jetty.http2.server.HTTP2ServerConnectionFactory, org.eclipse.jetty.http2.server.RawHTTP2ServerConnectionFactory
Annotations
@ManagedObject
Imports
java.io.IOException, java.util.HashMap, .HashSet, .Map, .Objects, .Set, java.util.concurrent.CompletableFuture, .ConcurrentHashMap, java.util.concurrent.atomic.AtomicReference, org.eclipse.jetty.http2.BufferingFlowControlStrategy, .FlowControlStrategy, .HTTP2Connection, .HTTP2Session, .RateControl, .WindowRateControl, org.eclipse.jetty.http2.api.Session, org.eclipse.jetty.http2.api.server.ServerSessionListener, org.eclipse.jetty.http2.frames.Frame, .SettingsFrame, org.eclipse.jetty.http2.generator.Generator, org.eclipse.jetty.http2.hpack.HpackContext, org.eclipse.jetty.http2.parser.ServerParser, org.eclipse.jetty.http2.server.internal.HTTP2ServerConnection, .HTTP2ServerSession, org.eclipse.jetty.io.Connection, .EndPoint, org.eclipse.jetty.server.AbstractConnectionFactory, .Connector, .HttpConfiguration, org.eclipse.jetty.util.annotation.ManagedAttribute, .ManagedObject, .Name, org.eclipse.jetty.util.component.Dumpable, .Graceful, .LifeCycle

Nested and Inner Type Summary

Modifier and TypeClass and Description
public static class

Field Summary

Modifier and TypeField and Description
private boolean
private FlowControlStrategy.Factory
private final HttpConfiguration
private int
private int
private int
private int
private int
private int
private int
private int
private RateControl.Factory
private final AbstractHTTP2ServerConnectionFactory.HTTP2SessionContainer
private long
private boolean
private boolean

Constructor Summary

AccessConstructor and Description
public
protected

Method Summary

Modifier and TypeMethod and Description
public FlowControlStrategy.Factory
public HttpConfiguration
public int
public int
public int
public int
public int
public int
public int
public int
public RateControl.Factory
getRateControlFactory()

Returns: the factory that creates RateControl objects

public long
public boolean
private static boolean
public boolean
public boolean
public Connection
newConnection(Connector
The Connector creating this connection
connector
,
EndPoint
the EndPoint associated with the connection
endPoint
)

Implements org.eclipse.jetty.server.ConnectionFactory.newConnection.

Creates a new Connection with the given parameters

private ServerParser
newServerParser(Connector connector, RateControl rateControl)

protected abstract ServerSessionListener
newSessionListener(Connector connector, EndPoint endPoint)

protected Map<Integer, Integer>
public void
setConnectProtocolEnabled(boolean connectProtocolEnabled)

public void
public void
setInitialSessionRecvWindow(int initialSessionRecvWindow)

public void
setInitialStreamRecvWindow(int initialStreamRecvWindow)

public void
setMaxConcurrentStreams(int maxConcurrentStreams)

public void
setMaxDecoderTableCapacity(int maxDecoderTableCapacity)

public void
setMaxEncoderTableCapacity(int
The HPACK encoder dynamic table maximum capacity
maxEncoderTableCapacity
)

Sets the limit for the encoder HPACK dynamic table capacity.

public void
setMaxFrameSize(int maxFrameSize)

public void
setMaxHeaderBlockFragment(int maxHeaderBlockFragment)

public void
setMaxSettingsKeys(int maxSettingsKeys)

public void
setRateControlFactory(RateControl.Factory
the factory that creates RateControl objects
rateControlFactory
)

Sets the factory that creates a per-connection RateControl object.

public void
setStreamIdleTimeout(long
the idle timeout in milliseconds, 0 for the default, -1 to disable the idle timeout
streamIdleTimeout
)

Sets the HTTP/2 stream idle timeout.

public void
setUseInputDirectByteBuffers(boolean useInputDirectByteBuffers)

public void
setUseOutputDirectByteBuffers(boolean useOutputDirectByteBuffers)

Inherited from org.eclipse.jetty.server.AbstractConnectionFactory:
configurefindNextProtocolfindNextProtocolgetFactoriesgetInputBufferSizegetProtocolgetProtocolssetInputBufferSizetoString

Field Detail

connectProtocolEnabledback to summary
private boolean connectProtocolEnabled
flowControlStrategyFactoryback to summary
private FlowControlStrategy.Factory flowControlStrategyFactory
httpConfigurationback to summary
private final HttpConfiguration httpConfiguration
initialSessionRecvWindowback to summary
private int initialSessionRecvWindow
initialStreamRecvWindowback to summary
private int initialStreamRecvWindow
maxConcurrentStreamsback to summary
private int maxConcurrentStreams
maxDecoderTableCapacityback to summary
private int maxDecoderTableCapacity
maxEncoderTableCapacityback to summary
private int maxEncoderTableCapacity
maxFrameSizeback to summary
private int maxFrameSize
maxHeaderBlockFragmentback to summary
private int maxHeaderBlockFragment
maxSettingsKeysback to summary
private int maxSettingsKeys
rateControlFactoryback to summary
private RateControl.Factory rateControlFactory
sessionContainerback to summary
private final AbstractHTTP2ServerConnectionFactory.HTTP2SessionContainer sessionContainer
streamIdleTimeoutback to summary
private long streamIdleTimeout
useInputDirectByteBuffersback to summary
private boolean useInputDirectByteBuffers
useOutputDirectByteBuffersback to summary
private boolean useOutputDirectByteBuffers

Constructor Detail

AbstractHTTP2ServerConnectionFactoryback to summary
public AbstractHTTP2ServerConnectionFactory(HttpConfiguration httpConfiguration)
AbstractHTTP2ServerConnectionFactoryback to summary
protected AbstractHTTP2ServerConnectionFactory(HttpConfiguration httpConfiguration, String... protocols)

Method Detail

getFlowControlStrategyFactoryback to summary
public FlowControlStrategy.Factory getFlowControlStrategyFactory()
getHttpConfigurationback to summary
public HttpConfiguration getHttpConfiguration()
getInitialSessionRecvWindowback to summary
public int getInitialSessionRecvWindow()
Annotations
@ManagedAttribute:The initial size of session\'s flow control receive window
getInitialStreamRecvWindowback to summary
public int getInitialStreamRecvWindow()
Annotations
@ManagedAttribute:The initial size of stream\'s flow control receive window
getMaxConcurrentStreamsback to summary
public int getMaxConcurrentStreams()
Annotations
@ManagedAttribute:The max number of concurrent streams per session
getMaxDecoderTableCapacityback to summary
public int getMaxDecoderTableCapacity()
Annotations
@ManagedAttribute:The HPACK decoder dynamic table maximum capacity
getMaxEncoderTableCapacityback to summary
public int getMaxEncoderTableCapacity()
Annotations
@ManagedAttribute:The HPACK encoder dynamic table maximum capacity
getMaxFrameSizeback to summary
public int getMaxFrameSize()
Annotations
@ManagedAttribute:The max frame size in bytes
getMaxHeaderBlockFragmentback to summary
public int getMaxHeaderBlockFragment()
Annotations
@ManagedAttribute:The max header block fragment
getMaxSettingsKeysback to summary
public int getMaxSettingsKeys()
Annotations
@ManagedAttribute:The max number of keys in all SETTINGS frames
getRateControlFactoryback to summary
public RateControl.Factory getRateControlFactory()
Returns:RateControl.Factory

the factory that creates RateControl objects

getStreamIdleTimeoutback to summary
public long getStreamIdleTimeout()
Annotations
@ManagedAttribute:The stream idle timeout in milliseconds
isConnectProtocolEnabledback to summary
public boolean isConnectProtocolEnabled()
Annotations
@ManagedAttribute:Whether CONNECT requests supports a protocol
isProtocolSupportedback to summary
private static boolean isProtocolSupported(String protocol)
isUseInputDirectByteBuffersback to summary
public boolean isUseInputDirectByteBuffers()
Annotations
@ManagedAttribute:Whether to use direct ByteBuffers for reading
isUseOutputDirectByteBuffersback to summary
public boolean isUseOutputDirectByteBuffers()
Annotations
@ManagedAttribute:Whether to use direct ByteBuffers for writing
newConnectionback to summary
public Connection newConnection(Connector connector, EndPoint endPoint)

Implements org.eclipse.jetty.server.ConnectionFactory.newConnection.

Doc from org.eclipse.jetty.server.ConnectionFactory.newConnection.

Creates a new Connection with the given parameters

Parameters
connector:Connector

The Connector creating this connection

endPoint:EndPoint

the EndPoint associated with the connection

Returns:Connection

a new Connection

Annotations
@Override
newServerParserback to summary
private ServerParser newServerParser(Connector connector, RateControl rateControl)
newSessionListenerback to summary
protected abstract ServerSessionListener newSessionListener(Connector connector, EndPoint endPoint)
newSettingsback to summary
protected Map<Integer, Integer> newSettings()
setConnectProtocolEnabledback to summary
public void setConnectProtocolEnabled(boolean connectProtocolEnabled)
setFlowControlStrategyFactoryback to summary
public void setFlowControlStrategyFactory(FlowControlStrategy.Factory flowControlStrategyFactory)
setInitialSessionRecvWindowback to summary
public void setInitialSessionRecvWindow(int initialSessionRecvWindow)
setInitialStreamRecvWindowback to summary
public void setInitialStreamRecvWindow(int initialStreamRecvWindow)
setMaxConcurrentStreamsback to summary
public void setMaxConcurrentStreams(int maxConcurrentStreams)
setMaxDecoderTableCapacityback to summary
public void setMaxDecoderTableCapacity(int maxDecoderTableCapacity)
setMaxEncoderTableCapacityback to summary
public void setMaxEncoderTableCapacity(int maxEncoderTableCapacity)

Sets the limit for the encoder HPACK dynamic table capacity.

Setting this value to 0 disables the use of the dynamic table.

Parameters
maxEncoderTableCapacity:int

The HPACK encoder dynamic table maximum capacity

setMaxFrameSizeback to summary
public void setMaxFrameSize(int maxFrameSize)
setMaxHeaderBlockFragmentback to summary
public void setMaxHeaderBlockFragment(int maxHeaderBlockFragment)
setMaxSettingsKeysback to summary
public void setMaxSettingsKeys(int maxSettingsKeys)
setRateControlFactoryback to summary
public void setRateControlFactory(RateControl.Factory rateControlFactory)

Sets the factory that creates a per-connection RateControl object.

Parameters
rateControlFactory:RateControl.Factory

the factory that creates RateControl objects

setStreamIdleTimeoutback to summary
public void setStreamIdleTimeout(long streamIdleTimeout)

Sets the HTTP/2 stream idle timeout.

Value -1 disables the idle timeout, value 0 implies using the default idle timeout, positive values specify the idle timeout in milliseconds.

Parameters
streamIdleTimeout:long

the idle timeout in milliseconds, 0 for the default, -1 to disable the idle timeout

setUseInputDirectByteBuffersback to summary
public void setUseInputDirectByteBuffers(boolean useInputDirectByteBuffers)
setUseOutputDirectByteBuffersback to summary
public void setUseOutputDirectByteBuffers(boolean useOutputDirectByteBuffers)
org.eclipse.jetty.http2.server back to summary

public Class AbstractHTTP2ServerConnectionFactory.HTTP2SessionContainer

extends Object
implements Listener, Graceful, Dumpable
Class Inheritance
  • java.lang.Object
  • org.eclipse.jetty.http2.server.AbstractHTTP2ServerConnectionFactory.HTTP2SessionContainer
All Implemented Interfaces
org.eclipse.jetty.util.component.Dumpable, org.eclipse.jetty.util.component.Graceful, org.eclipse.jetty.io.Connection.Listener, java.util.EventListener
Annotations
@ManagedObject:The container of HTTP/2 sessions

Field Summary

Modifier and TypeField and Description
private final Set<HTTP2Session>
private final AtomicReference<CompletableFuture<Void>>

Constructor Summary

AccessConstructor and Description
public

Method Summary

Modifier and TypeMethod and Description
public String
public void
dump(Appendable
The appendable to dump to
out
,
String
The indent to apply after any new lines.
indent
)

Implements org.eclipse.jetty.util.component.Dumpable.dump.

Dump this object (and children) into an Appendable using the provided indent after any new lines.

public Set<Session>
public int
public boolean
public void
public void
public CompletableFuture<Void>
shutdown()

Implements org.eclipse.jetty.util.component.Graceful.shutdown.

Shutdown the component.

private CompletableFuture<Void>
public String
toString()

Overrides java.lang.Object.toString.

Returns a string representation of the object.

Inherited from java.lang.Object:
cloneequalsfinalizegetClasshashCodenotifynotifyAllwaitwaitwait

Field Detail

sessionsback to summary
private final Set<HTTP2Session> sessions
shutdownback to summary
private final AtomicReference<CompletableFuture<Void>> shutdown

Constructor Detail

HTTP2SessionContainerback to summary
public HTTP2SessionContainer()

Method Detail

dumpback to summary
public String dump()

Overrides default org.eclipse.jetty.util.component.Dumpable.dump.

Annotations
@Override
dumpback to summary
public void dump(Appendable out, String indent) throws IOException

Implements org.eclipse.jetty.util.component.Dumpable.dump.

Doc from org.eclipse.jetty.util.component.Dumpable.dump.

Dump this object (and children) into an Appendable using the provided indent after any new lines. The indent should not be applied to the first object dumped.

Parameters
out:Appendable

The appendable to dump to

indent:String

The indent to apply after any new lines.

Annotations
@Override
Exceptions
IOException:
if unable to write to Appendable
getSessionsback to summary
public Set<Session> getSessions()
getSizeback to summary
public int getSize()
Annotations
@ManagedAttribute:The number of HTTP/2 sessions
readonly:true
isShutdownback to summary
public boolean isShutdown()

Implements org.eclipse.jetty.util.component.Graceful.isShutdown.

Returns:boolean

Doc from org.eclipse.jetty.util.component.Graceful.isShutdown.

True if shutdown() has been called.

Annotations
@Override
onClosedback to summary
public void onClosed(Connection connection)

Overrides default org.eclipse.jetty.io.Connection.Listener.onClosed.

Annotations
@Override
onOpenedback to summary
public void onOpened(Connection connection)

Overrides default org.eclipse.jetty.io.Connection.Listener.onOpened.

Annotations
@Override
shutdownback to summary
public CompletableFuture<Void> shutdown()

Implements org.eclipse.jetty.util.component.Graceful.shutdown.

Doc from org.eclipse.jetty.util.component.Graceful.shutdown.

Shutdown the component. When this method returns, the component should not accept any new load.

Returns:CompletableFuture<Void>

A future that is completed once all load on the component is completed

Annotations
@Override
shutdownback to summary
private CompletableFuture<Void> shutdown(HTTP2Session session)
toStringback to summary
public String toString()

Overrides java.lang.Object.toString.

Doc from java.lang.Object.toString.

Returns a string representation of the object. Satisfying this method's contract implies a non-null result must be returned.

Returns:String

a string representation of the object

Annotations
@Override