Class H2MultiplexingRequesterBootstrap
- java.lang.Object
-
- org.apache.hc.core5.http2.impl.nio.bootstrap.H2MultiplexingRequesterBootstrap
-
public class H2MultiplexingRequesterBootstrap extends java.lang.ObjectH2MultiplexingRequesterbootstrap.- Since:
- 5.0
-
-
Field Summary
Fields Modifier and Type Field Description private CharCodingConfigcharCodingConfigprivate Callback<java.lang.Exception>exceptionCallbackprivate FrameFactoryframeFactoryprivate H2Configh2Configprivate HttpProcessorhttpProcessorprivate IOReactorConfigioReactorConfigprivate Decorator<IOSession>ioSessionDecoratorprivate java.util.List<RequestRouter.Entry<Supplier<AsyncPushConsumer>>>routeEntriesprivate IOSessionListenersessionListenerprivate H2StreamListenerstreamListenerprivate booleanstrictALPNHandshakeprivate IOReactorMetricsListenerthreadPoolListenerprivate TlsStrategytlsStrategyprivate UriPatternTypeuriPatternType
-
Constructor Summary
Constructors Modifier Constructor Description privateH2MultiplexingRequesterBootstrap()
-
Method Summary
-
-
-
Field Detail
-
routeEntries
private final java.util.List<RequestRouter.Entry<Supplier<AsyncPushConsumer>>> routeEntries
-
uriPatternType
private UriPatternType uriPatternType
-
ioReactorConfig
private IOReactorConfig ioReactorConfig
-
httpProcessor
private HttpProcessor httpProcessor
-
charCodingConfig
private CharCodingConfig charCodingConfig
-
h2Config
private H2Config h2Config
-
tlsStrategy
private TlsStrategy tlsStrategy
-
strictALPNHandshake
private boolean strictALPNHandshake
-
exceptionCallback
private Callback<java.lang.Exception> exceptionCallback
-
sessionListener
private IOSessionListener sessionListener
-
streamListener
private H2StreamListener streamListener
-
frameFactory
private FrameFactory frameFactory
-
threadPoolListener
private IOReactorMetricsListener threadPoolListener
-
-
Method Detail
-
bootstrap
public static H2MultiplexingRequesterBootstrap bootstrap()
-
setIOReactorConfig
public final H2MultiplexingRequesterBootstrap setIOReactorConfig(IOReactorConfig ioReactorConfig)
Sets I/O reactor configuration.- Returns:
- this instance.
-
setHttpProcessor
public final H2MultiplexingRequesterBootstrap setHttpProcessor(HttpProcessor httpProcessor)
SetsHttpProcessorinstance.- Returns:
- this instance.
-
setH2Config
public final H2MultiplexingRequesterBootstrap setH2Config(H2Config h2Config)
Sets HTTP/2 protocol parameters- Returns:
- this instance.
-
setCharCodingConfig
public final H2MultiplexingRequesterBootstrap setCharCodingConfig(CharCodingConfig charCodingConfig)
Sets message char coding.- Returns:
- this instance.
-
setTlsStrategy
public final H2MultiplexingRequesterBootstrap setTlsStrategy(TlsStrategy tlsStrategy)
SetsTlsStrategyinstance.- Returns:
- this instance.
-
setStrictALPNHandshake
public final H2MultiplexingRequesterBootstrap setStrictALPNHandshake(boolean strictALPNHandshake)
-
setIOSessionDecorator
public final H2MultiplexingRequesterBootstrap setIOSessionDecorator(Decorator<IOSession> ioSessionDecorator)
- Returns:
- this instance.
-
setExceptionCallback
public final H2MultiplexingRequesterBootstrap setExceptionCallback(Callback<java.lang.Exception> exceptionCallback)
SetsExceptionCallbackinstance.- Returns:
- this instance.
-
setIOSessionListener
public final H2MultiplexingRequesterBootstrap setIOSessionListener(IOSessionListener sessionListener)
SetsIOSessionListenerinstance.- Returns:
- this instance.
-
setIOReactorMetricsListener
public final H2MultiplexingRequesterBootstrap setIOReactorMetricsListener(IOReactorMetricsListener threadPoolListener)
SetsIOReactorMetricsListenerinstance.- Returns:
- this instance.
- Since:
- 5.4
-
setStreamListener
public final H2MultiplexingRequesterBootstrap setStreamListener(H2StreamListener streamListener)
SetsH2StreamListenerinstance.- Returns:
- this instance.
-
setStreamListener
public final H2MultiplexingRequesterBootstrap setStreamListener(FrameFactory frameFactory)
SetsFrameFactoryinstance.- Returns:
- this instance.
- Since:
- 5.4
-
setUriPatternType
public final H2MultiplexingRequesterBootstrap setUriPatternType(UriPatternType uriPatternType)
SetsUriPatternTypefor handler registration.- Returns:
- this instance.
-
register
public final H2MultiplexingRequesterBootstrap register(java.lang.String uriPattern, Supplier<AsyncPushConsumer> supplier)
Registers the givenAsyncPushConsumerSupplieras a default handler for URIs matching the given pattern.- Parameters:
uriPattern- the pattern to register the handler for.supplier- the handler supplier.- Returns:
- this instance.
-
register
public final H2MultiplexingRequesterBootstrap register(java.lang.String hostname, java.lang.String uriPattern, Supplier<AsyncPushConsumer> supplier)
Registers the givenAsyncPushConsumerSupplieras a handler for URIs matching the given host and the pattern.- Parameters:
hostname- the host nameuriPattern- the pattern to register the handler for.supplier- the handler supplier.- Returns:
- this instance.
- Since:
- 5.3
-
registerVirtual
@Deprecated public final H2MultiplexingRequesterBootstrap registerVirtual(java.lang.String hostname, java.lang.String uriPattern, Supplier<AsyncPushConsumer> supplier)
Deprecated.- Returns:
- this instance.
-
create
public H2MultiplexingRequester create()
-
-