Top Description Fields Constructors Methods
io.undertow.server.protocol.http2

public final Class Http2OpenListener

extends Object
implements ChannelListener<StreamConnection>, DelegateOpenListener
Class Inheritance
All Implemented Interfaces
io.undertow.server.DelegateOpenListener, io.undertow.server.OpenListener, org.xnio.ChannelListener, java.util.EventListener
Imports
io.undertow.UndertowLogger, .UndertowMessages, .UndertowOptions, io.undertow.conduits.BytesReceivedStreamSourceConduit, .BytesSentStreamSinkConduit, io.undertow.protocols.http2.Http2Channel, io.undertow.server.ConnectorStatistics, .ConnectorStatisticsImpl, .DelegateOpenListener, .HttpHandler, .XnioByteBufferPool, org.xnio.ChannelListener, .IoUtils, .OptionMap, .Pool, .StreamConnection, io.undertow.connector.ByteBufferPool, .PooledByteBuffer, java.nio.ByteBuffer, java.util.Collections, .Set, java.util.concurrent.ConcurrentHashMap

Open listener for HTTP2 server
Author
Stuart Douglas

Field Summary

Modifier and TypeField and Description
private final ByteBufferPool
private final int
private final ChannelListener<Http2Channel>
private final Set<Http2Channel>
private final ConnectorStatisticsImpl
public static final String
public static final String
HTTP2_14

Deprecated
private final String
private volatile HttpHandler
private volatile boolean
private volatile OptionMap

Constructor Summary

AccessConstructor and Description
public
Http2OpenListener(final Pool<ByteBuffer> pool)
Deprecated

public
Http2OpenListener(final Pool<ByteBuffer> pool, final OptionMap undertowOptions)
Deprecated

public
Http2OpenListener(final Pool<ByteBuffer> pool, final OptionMap undertowOptions, String protocol)
Deprecated

public
public
Http2OpenListener(final ByteBufferPool pool, final OptionMap undertowOptions)

public
Http2OpenListener(final ByteBufferPool pool, final OptionMap undertowOptions, String protocol)

Method Summary

Modifier and TypeMethod and Description
public void
closeConnections()

Overrides default io.undertow.server.OpenListener.closeConnections.

Close all active connections that were handled by this listener

public ByteBufferPool
public ConnectorStatistics
public HttpHandler
public OptionMap
public void
handleEvent(final StreamConnection
The channel
channel
,
PooledByteBuffer
Any additional data that was read from the stream as part of the handshake process
buffer
)

Implements io.undertow.server.DelegateOpenListener.handleEvent.

public void
handleEvent(StreamConnection
the channel event
channel
)

Implements org.xnio.ChannelListener.handleEvent.

Handle the event on this channel.

public void
setRootHandler(final HttpHandler
The new root handler
rootHandler
)

Implements io.undertow.server.OpenListener.setRootHandler.

Sets the root handler

public void
setUndertowOptions(final OptionMap
The connector options
undertowOptions
)

Implements io.undertow.server.OpenListener.setUndertowOptions.

Inherited from java.lang.Object:
cloneequalsfinalizegetClasshashCodenotifynotifyAlltoStringwaitwaitwait

Field Detail

bufferPoolback to summary
private final ByteBufferPool bufferPool
bufferSizeback to summary
private final int bufferSize
closeTaskback to summary
private final ChannelListener<Http2Channel> closeTask
connectionsback to summary
private final Set<Http2Channel> connections
connectorStatisticsback to summary
private final ConnectorStatisticsImpl connectorStatistics
HTTP2back to summary
public static final String HTTP2
HTTP2_14back to summary
public static final String HTTP2_14

Deprecated

Annotations
@Deprecated
protocolback to summary
private final String protocol
rootHandlerback to summary
private volatile HttpHandler rootHandler
statisticsEnabledback to summary
private volatile boolean statisticsEnabled
undertowOptionsback to summary
private volatile OptionMap undertowOptions

Constructor Detail

Http2OpenListenerback to summary
public Http2OpenListener(final Pool<ByteBuffer> pool)

Deprecated

Annotations
@Deprecated
Http2OpenListenerback to summary
public Http2OpenListener(final Pool<ByteBuffer> pool, final OptionMap undertowOptions)

Deprecated

Annotations
@Deprecated
Http2OpenListenerback to summary
public Http2OpenListener(final Pool<ByteBuffer> pool, final OptionMap undertowOptions, String protocol)

Deprecated

Annotations
@Deprecated
Http2OpenListenerback to summary
public Http2OpenListener(final ByteBufferPool pool)
Http2OpenListenerback to summary
public Http2OpenListener(final ByteBufferPool pool, final OptionMap undertowOptions)
Http2OpenListenerback to summary
public Http2OpenListener(final ByteBufferPool pool, final OptionMap undertowOptions, String protocol)

Method Detail

closeConnectionsback to summary
public void closeConnections()

Overrides default io.undertow.server.OpenListener.closeConnections.

Doc from io.undertow.server.OpenListener.closeConnections.

Close all active connections that were handled by this listener

Annotations
@Override
getBufferPoolback to summary
public ByteBufferPool getBufferPool()

Implements io.undertow.server.OpenListener.getBufferPool.

Returns:ByteBufferPool

Doc from io.undertow.server.OpenListener.getBufferPool.

The buffer pool in use by this connector

Annotations
@Override
getConnectorStatisticsback to summary
public ConnectorStatistics getConnectorStatistics()

Implements io.undertow.server.OpenListener.getConnectorStatistics.

Returns:ConnectorStatistics

Doc from io.undertow.server.OpenListener.getConnectorStatistics.

The connector statistics, or null if statistics gathering is disabled.

Annotations
@Override
getRootHandlerback to summary
public HttpHandler getRootHandler()

Implements io.undertow.server.OpenListener.getRootHandler.

Returns:HttpHandler

Doc from io.undertow.server.OpenListener.getRootHandler.

The first handler that will be executed by requests on the connector

Annotations
@Override
getUndertowOptionsback to summary
public OptionMap getUndertowOptions()

Implements io.undertow.server.OpenListener.getUndertowOptions.

Returns:OptionMap

Doc from io.undertow.server.OpenListener.getUndertowOptions.

The connector options

Annotations
@Override
handleEventback to summary
public void handleEvent(final StreamConnection channel, PooledByteBuffer buffer)

Implements io.undertow.server.DelegateOpenListener.handleEvent.

Parameters
channel:StreamConnection

Doc from io.undertow.server.DelegateOpenListener.handleEvent.

The channel

buffer:PooledByteBuffer

Doc from io.undertow.server.DelegateOpenListener.handleEvent.

Any additional data that was read from the stream as part of the handshake process

handleEventback to summary
public void handleEvent(StreamConnection channel)

Implements org.xnio.ChannelListener.handleEvent.

Doc from org.xnio.ChannelListener.handleEvent.

Handle the event on this channel.

Parameters
channel:StreamConnection

the channel event

Annotations
@Override
setRootHandlerback to summary
public void setRootHandler(final HttpHandler rootHandler)

Implements io.undertow.server.OpenListener.setRootHandler.

Doc from io.undertow.server.OpenListener.setRootHandler.

Sets the root handler

Parameters
rootHandler:HttpHandler

The new root handler

Annotations
@Override
setUndertowOptionsback to summary
public void setUndertowOptions(final OptionMap undertowOptions)

Implements io.undertow.server.OpenListener.setUndertowOptions.

Parameters
undertowOptions:OptionMap

Doc from io.undertow.server.OpenListener.setUndertowOptions.

The connector options

Annotations
@Override