public class Http2ClientFilter extends Http2BaseFilter
FIXED_LENGTH_ENCODING| Constructor and Description |
|---|
Http2ClientFilter() |
Http2ClientFilter(DraftVersion... supportedDraftVersions) |
Http2ClientFilter(ExecutorService threadPool,
DraftVersion... supportedDraftVersions) |
| Modifier and Type | Method and Description |
|---|---|
protected Http2Connection |
createClientHttp2Connection(DraftVersion draftVersion,
Connection connection)
Creates client-side
Http2Connection with preconfigured
initial-windows-size and max-concurrent-streams. |
protected org.glassfish.grizzly.npn.AlpnClientNegotiator |
getClientAlpnNegotioator() |
NextAction |
handleConnect(FilterChainContext ctx)
Execute a unit of processing work to be performed, when channel gets
connected.
|
NextAction |
handleEvent(FilterChainContext ctx,
FilterChainEvent event)
Handle custom event associated with the
Connection. |
NextAction |
handleRead(FilterChainContext ctx)
Execute a unit of processing work to be performed, when channel will
become available for reading.
|
NextAction |
handleWrite(FilterChainContext ctx)
Execute a unit of processing work to be performed, when some data should
be written on channel.
|
boolean |
isNeverForceUpgrade() |
boolean |
isSendPushRequestUpstream() |
protected SettingsFrame.SettingsFrameBuilder |
prepareSettings() |
protected SettingsFrame.SettingsFrameBuilder |
prepareSettings(DraftVersion version) |
protected SettingsFrame.SettingsFrameBuilder |
prepareSettings(DraftVersion version,
SettingsFrame.SettingsFrameBuilder builder) |
protected void |
processCompleteHeader(Http2Connection http2Connection,
FilterChainContext context,
HeaderBlockHead firstHeaderFrame)
The method is called once complete HTTP header block arrives on
Http2Connection. |
protected void |
processOutgoingHttpHeader(FilterChainContext ctx,
Http2Connection http2Connection,
HttpHeader httpHeader,
HttpPacket entireHttpPacket) |
void |
setNeverForceUpgrade(boolean neverForceUpgrade) |
void |
setSendPushRequestUpstream(boolean sendPushRequestUpstream) |
checkRequestHeadersOnUpgrade, checkResponseHeadersOnUpgrade, createHttp2Connection, getHttp2UpgradeSettings, getHttp2UpgradingVersion, getInitialWindowSize, getLocalMaxFramePayloadSize, getMaxConcurrentStreams, obtainHttp2Connection, onHttpContentEncoded, onHttpContentError, onHttpContentParsed, onHttpHeaderError, onHttpHeaderParsed, onHttpHeadersEncoded, onHttpHeadersParsed, onHttpPacketParsed, onInitialLineEncoded, onInitialLineParsed, onPrefaceReceived, prepareOutgoingRequest, processFrames, sendSettings, setInitialWindowSize, setLocalMaxFramePayloadSize, setMaxConcurrentStreamsbindcreateContext, exceptionOccurred, handleAccept, handleClose, onAdded, onFilterChainChanged, onRemoved, toStringpublic Http2ClientFilter()
public Http2ClientFilter(DraftVersion... supportedDraftVersions)
public Http2ClientFilter(ExecutorService threadPool, DraftVersion... supportedDraftVersions)
public boolean isNeverForceUpgrade()
public void setNeverForceUpgrade(boolean neverForceUpgrade)
public boolean isSendPushRequestUpstream()
public void setSendPushRequestUpstream(boolean sendPushRequestUpstream)
sendPushRequestUpstream - true if the push request has to
be sent upstream, so a user have a chance to process it,
or false otherwisepublic NextAction handleConnect(FilterChainContext ctx) throws IOException
BaseFilterFilter may either complete the required processing and
return false, or delegate remaining processing to the next
Filter in a FilterChain containing this Filter
by returning true.handleConnect in interface FilterhandleConnect in class BaseFilterctx - FilterChainContextNextAction instruction for FilterChain, how it
should continue the executionIOExceptionpublic NextAction handleRead(FilterChainContext ctx) throws IOException
BaseFilterFilter may either complete the required processing and
return false, or delegate remaining processing to the next
Filter in a FilterChain containing this Filter
by returning true.handleRead in interface FilterhandleRead in class BaseFilterctx - FilterChainContextNextAction instruction for FilterChain, how it
should continue the executionIOExceptionpublic NextAction handleWrite(FilterChainContext ctx) throws IOException
BaseFilterFilter may either complete the required processing and
return false, or delegate remaining processing to the next
Filter in a FilterChain containing this Filter
by returning true.handleWrite in interface FilterhandleWrite in class Http2BaseFilterctx - FilterChainContextNextAction instruction for FilterChain, how it
should continue the executionIOExceptionpublic NextAction handleEvent(FilterChainContext ctx, FilterChainEvent event) throws IOException
BaseFilterConnection.
This Filter may either complete the required processing and
return StopAction, or delegate remaining processing to the next
Filter in a FilterChain containing this Filter
by returning InvokeAction.handleEvent in interface FilterhandleEvent in class Http2BaseFilterctx - FilterChainContextNextAction instruction for FilterChain, how it
should continue the executionIOExceptionprotected void processOutgoingHttpHeader(FilterChainContext ctx, Http2Connection http2Connection, HttpHeader httpHeader, HttpPacket entireHttpPacket) throws IOException
processOutgoingHttpHeader in class Http2BaseFilterctx - http2Connection - httpHeader - entireHttpPacket - IOExceptionprotected Http2Connection createClientHttp2Connection(DraftVersion draftVersion, Connection connection)
Http2Connection with preconfigured
initial-windows-size and max-concurrent-streams.
Note: Should be called with disabled OP_READ (or during OP_READ processing),
because peer frames must not be processed at the time this method
is running.draftVersion - connection - Http2Connectionprotected org.glassfish.grizzly.npn.AlpnClientNegotiator getClientAlpnNegotioator()
protected void processCompleteHeader(Http2Connection http2Connection, FilterChainContext context, HeaderBlockHead firstHeaderFrame) throws IOException
Http2BaseFilterHttp2Connection.processCompleteHeader in class Http2BaseFilterIOExceptionprotected final SettingsFrame.SettingsFrameBuilder prepareSettings()
protected final SettingsFrame.SettingsFrameBuilder prepareSettings(DraftVersion version)
protected SettingsFrame.SettingsFrameBuilder prepareSettings(DraftVersion version, SettingsFrame.SettingsFrameBuilder builder)
Copyright © 2021 Oracle Corporation. All rights reserved.