Class ReactorNetty4HttpServerTransport
java.lang.Object
org.opensearch.common.lifecycle.AbstractLifecycleComponent
org.opensearch.http.AbstractHttpServerTransport
org.opensearch.http.reactor.netty4.ReactorNetty4HttpServerTransport
- All Implemented Interfaces:
Closeable,AutoCloseable,org.opensearch.common.lease.Releasable,org.opensearch.common.lifecycle.LifecycleComponent,org.opensearch.core.service.ReportingService<HttpInfo>,HttpServerTransport
The HTTP transport implementations based on Reactor Netty (see please
HttpServer).-
Nested Class Summary
Nested classes/interfaces inherited from interface org.opensearch.http.HttpServerTransport
HttpServerTransport.DispatcherNested classes/interfaces inherited from interface org.opensearch.core.service.ReportingService
org.opensearch.core.service.ReportingService.Info -
Field Summary
FieldsModifier and TypeFieldDescriptionThe maximum number of composite components for request accumulationThe number of Reactor Netty HTTP workersFields inherited from class org.opensearch.http.AbstractHttpServerTransport
bigArrays, corsHandler, dispatcher, handlingSettings, maxContentLength, networkService, port, settings, threadPoolFields inherited from class org.opensearch.common.lifecycle.AbstractLifecycleComponent
lifecycleFields inherited from interface org.opensearch.http.HttpServerTransport
HTTP_SERVER_WORKER_THREAD_NAME_PREFIX -
Constructor Summary
ConstructorsConstructorDescriptionReactorNetty4HttpServerTransport(Settings settings, NetworkService networkService, BigArrays bigArrays, ThreadPool threadPool, org.opensearch.core.xcontent.NamedXContentRegistry xContentRegistry, HttpServerTransport.Dispatcher dispatcher, ClusterSettings clusterSettings, SharedGroupFactory sharedGroupFactory, Tracer tracer) Creates new HTTP transport implementations based on Reactor Netty (see pleaseHttpServer). -
Method Summary
Modifier and TypeMethodDescriptionprotected HttpServerChannelbind(InetSocketAddress socketAddress) Binds the transport engine to the socket addressprotected voiddoStart()Starts the transportprotected org.reactivestreams.Publisher<Void> incomingRequest(reactor.netty.http.server.HttpServerRequest request, reactor.netty.http.server.HttpServerResponse response) Handles incoming Reactor Netty requestvoidonException(HttpChannel channel, Exception cause) protected voidCalled to tear down internal resourcesMethods inherited from class org.opensearch.http.AbstractHttpServerTransport
bindServer, boundAddress, doClose, doStop, incomingRequest, info, onServerException, serverAcceptedChannel, statsMethods inherited from class org.opensearch.common.lifecycle.AbstractLifecycleComponent
addLifecycleListener, close, lifecycleState, removeLifecycleListener, start, stopMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface org.opensearch.common.lifecycle.LifecycleComponent
addLifecycleListener, lifecycleState, removeLifecycleListener, start, stopMethods inherited from interface org.opensearch.common.lease.Releasable
close
-
Field Details
-
SETTING_HTTP_WORKER_COUNT
The number of Reactor Netty HTTP workers -
SETTING_HTTP_NETTY_MAX_COMPOSITE_BUFFER_COMPONENTS
The maximum number of composite components for request accumulation
-
-
Constructor Details
-
Method Details
-
bind
Binds the transport engine to the socket address- Specified by:
bindin classAbstractHttpServerTransport- Parameters:
socketAddress- socket address to bind to- Throws:
Exception
-
incomingRequest
protected org.reactivestreams.Publisher<Void> incomingRequest(reactor.netty.http.server.HttpServerRequest request, reactor.netty.http.server.HttpServerResponse response) Handles incoming Reactor Netty request- Parameters:
request- request instanceresponse- response instances- Returns:
- response publisher
-
stopInternal
protected void stopInternal()Called to tear down internal resources- Specified by:
stopInternalin classAbstractHttpServerTransport
-
doStart
protected void doStart()Starts the transport- Specified by:
doStartin classorg.opensearch.common.lifecycle.AbstractLifecycleComponent
-
onException
- Overrides:
onExceptionin classAbstractHttpServerTransport
-