Package org.elasticsearch.http.netty4
Class Netty4HttpServerTransport
- java.lang.Object
-
- org.elasticsearch.common.component.AbstractComponent
-
- org.elasticsearch.common.component.AbstractLifecycleComponent
-
- org.elasticsearch.http.netty4.Netty4HttpServerTransport
-
- All Implemented Interfaces:
java.io.Closeable,java.lang.AutoCloseable,org.elasticsearch.common.component.LifecycleComponent,org.elasticsearch.common.lease.Releasable,org.elasticsearch.http.HttpServerTransport
public class Netty4HttpServerTransport extends org.elasticsearch.common.component.AbstractLifecycleComponent implements org.elasticsearch.http.HttpServerTransport
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description protected static classNetty4HttpServerTransport.HttpChannelHandler
-
Field Summary
Fields Modifier and Type Field Description protected org.elasticsearch.common.util.BigArraysbigArraysprotected java.lang.String[]bindHostsprotected org.elasticsearch.common.transport.BoundTransportAddressboundAddressprotected booleancompressionprotected intcompressionLevelprotected booleandetailedErrorsEnabledprotected org.elasticsearch.common.unit.ByteSizeValuemaxChunkSizeprotected intmaxCompositeBufferComponentsprotected org.elasticsearch.common.unit.ByteSizeValuemaxContentLengthprotected org.elasticsearch.common.unit.ByteSizeValuemaxHeaderSizeprotected org.elasticsearch.common.unit.ByteSizeValuemaxInitialLineLengthprotected org.elasticsearch.common.network.NetworkServicenetworkServiceprotected booleanpipeliningprotected intpipeliningMaxEventsprotected org.elasticsearch.common.transport.PortsRangeportprotected java.lang.String[]publishHostsprotected io.netty.channel.RecvByteBufAllocatorrecvByteBufAllocatorprotected booleanresetCookiesprotected booleanreuseAddressprotected io.netty.bootstrap.ServerBootstrapserverBootstrapprotected java.util.List<io.netty.channel.Channel>serverChannelsstatic org.elasticsearch.common.settings.Setting<java.lang.Integer>SETTING_HTTP_NETTY_MAX_COMPOSITE_BUFFER_COMPONENTSstatic org.elasticsearch.common.settings.Setting<org.elasticsearch.common.unit.ByteSizeValue>SETTING_HTTP_NETTY_RECEIVE_PREDICTOR_MAXDeprecated.This (undocumented) setting is deprecated to reduce complexity and is removed in 7.0.static org.elasticsearch.common.settings.Setting<org.elasticsearch.common.unit.ByteSizeValue>SETTING_HTTP_NETTY_RECEIVE_PREDICTOR_MINDeprecated.This (undocumented) setting is deprecated to reduce complexity and is removed in 7.0.static org.elasticsearch.common.settings.Setting<org.elasticsearch.common.unit.ByteSizeValue>SETTING_HTTP_NETTY_RECEIVE_PREDICTOR_SIZEstatic org.elasticsearch.common.settings.Setting<java.lang.Integer>SETTING_HTTP_WORKER_COUNTprotected booleantcpKeepAliveprotected booleantcpNoDelayprotected org.elasticsearch.common.unit.ByteSizeValuetcpReceiveBufferSizeprotected org.elasticsearch.common.unit.ByteSizeValuetcpSendBufferSizeprotected org.elasticsearch.threadpool.ThreadPoolthreadPoolprotected intworkerCountprotected org.elasticsearch.common.xcontent.NamedXContentRegistryxContentRegistryThe registry used to construct parsers so they supportXContentParser.namedObject(Class, String, Object).
-
Constructor Summary
Constructors Constructor Description Netty4HttpServerTransport(org.elasticsearch.common.settings.Settings settings, org.elasticsearch.common.network.NetworkService networkService, org.elasticsearch.common.util.BigArrays bigArrays, org.elasticsearch.threadpool.ThreadPool threadPool, org.elasticsearch.common.xcontent.NamedXContentRegistry xContentRegistry, org.elasticsearch.http.HttpServerTransport.Dispatcher dispatcher)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description org.elasticsearch.common.transport.BoundTransportAddressboundAddress()io.netty.channel.ChannelHandlerconfigureServerChannelHandler()protected voiddoClose()protected voiddoStart()protected voiddoStop()protected voidexceptionCaught(io.netty.channel.ChannelHandlerContext ctx, java.lang.Throwable cause)Netty4CorsConfiggetCorsConfig()org.elasticsearch.http.HttpInfoinfo()org.elasticsearch.common.settings.Settingssettings()org.elasticsearch.http.HttpStatsstats()-
Methods inherited from class org.elasticsearch.common.component.AbstractComponent
logDeprecatedSetting, logRemovedSetting, nodeName
-
Methods inherited from class org.elasticsearch.common.component.AbstractLifecycleComponent
addLifecycleListener, close, lifecycleState, removeLifecycleListener, start, stop
-
Methods inherited from interface org.elasticsearch.common.component.LifecycleComponent
addLifecycleListener, lifecycleState, removeLifecycleListener, start, stop
-
-
-
-
Field Detail
-
SETTING_HTTP_NETTY_MAX_COMPOSITE_BUFFER_COMPONENTS
public static org.elasticsearch.common.settings.Setting<java.lang.Integer> SETTING_HTTP_NETTY_MAX_COMPOSITE_BUFFER_COMPONENTS
-
SETTING_HTTP_WORKER_COUNT
public static final org.elasticsearch.common.settings.Setting<java.lang.Integer> SETTING_HTTP_WORKER_COUNT
-
SETTING_HTTP_NETTY_RECEIVE_PREDICTOR_SIZE
public static final org.elasticsearch.common.settings.Setting<org.elasticsearch.common.unit.ByteSizeValue> SETTING_HTTP_NETTY_RECEIVE_PREDICTOR_SIZE
-
SETTING_HTTP_NETTY_RECEIVE_PREDICTOR_MIN
@Deprecated public static final org.elasticsearch.common.settings.Setting<org.elasticsearch.common.unit.ByteSizeValue> SETTING_HTTP_NETTY_RECEIVE_PREDICTOR_MIN
Deprecated.This (undocumented) setting is deprecated to reduce complexity and is removed in 7.0. See #26165 for details.
-
SETTING_HTTP_NETTY_RECEIVE_PREDICTOR_MAX
@Deprecated public static final org.elasticsearch.common.settings.Setting<org.elasticsearch.common.unit.ByteSizeValue> SETTING_HTTP_NETTY_RECEIVE_PREDICTOR_MAX
Deprecated.This (undocumented) setting is deprecated to reduce complexity and is removed in 7.0. See #26165 for details.
-
networkService
protected final org.elasticsearch.common.network.NetworkService networkService
-
bigArrays
protected final org.elasticsearch.common.util.BigArrays bigArrays
-
maxContentLength
protected final org.elasticsearch.common.unit.ByteSizeValue maxContentLength
-
maxInitialLineLength
protected final org.elasticsearch.common.unit.ByteSizeValue maxInitialLineLength
-
maxHeaderSize
protected final org.elasticsearch.common.unit.ByteSizeValue maxHeaderSize
-
maxChunkSize
protected final org.elasticsearch.common.unit.ByteSizeValue maxChunkSize
-
workerCount
protected final int workerCount
-
pipelining
protected final boolean pipelining
-
pipeliningMaxEvents
protected final int pipeliningMaxEvents
-
compression
protected final boolean compression
-
compressionLevel
protected final int compressionLevel
-
resetCookies
protected final boolean resetCookies
-
port
protected final org.elasticsearch.common.transport.PortsRange port
-
bindHosts
protected final java.lang.String[] bindHosts
-
publishHosts
protected final java.lang.String[] publishHosts
-
detailedErrorsEnabled
protected final boolean detailedErrorsEnabled
-
threadPool
protected final org.elasticsearch.threadpool.ThreadPool threadPool
-
xContentRegistry
protected final org.elasticsearch.common.xcontent.NamedXContentRegistry xContentRegistry
The registry used to construct parsers so they supportXContentParser.namedObject(Class, String, Object).
-
tcpNoDelay
protected final boolean tcpNoDelay
-
tcpKeepAlive
protected final boolean tcpKeepAlive
-
reuseAddress
protected final boolean reuseAddress
-
tcpSendBufferSize
protected final org.elasticsearch.common.unit.ByteSizeValue tcpSendBufferSize
-
tcpReceiveBufferSize
protected final org.elasticsearch.common.unit.ByteSizeValue tcpReceiveBufferSize
-
recvByteBufAllocator
protected final io.netty.channel.RecvByteBufAllocator recvByteBufAllocator
-
maxCompositeBufferComponents
protected final int maxCompositeBufferComponents
-
serverBootstrap
protected volatile io.netty.bootstrap.ServerBootstrap serverBootstrap
-
boundAddress
protected volatile org.elasticsearch.common.transport.BoundTransportAddress boundAddress
-
serverChannels
protected final java.util.List<io.netty.channel.Channel> serverChannels
-
-
Constructor Detail
-
Netty4HttpServerTransport
public Netty4HttpServerTransport(org.elasticsearch.common.settings.Settings settings, org.elasticsearch.common.network.NetworkService networkService, org.elasticsearch.common.util.BigArrays bigArrays, org.elasticsearch.threadpool.ThreadPool threadPool, org.elasticsearch.common.xcontent.NamedXContentRegistry xContentRegistry, org.elasticsearch.http.HttpServerTransport.Dispatcher dispatcher)
-
-
Method Detail
-
settings
public org.elasticsearch.common.settings.Settings settings()
-
doStart
protected void doStart()
- Specified by:
doStartin classorg.elasticsearch.common.component.AbstractLifecycleComponent
-
doStop
protected void doStop()
- Specified by:
doStopin classorg.elasticsearch.common.component.AbstractLifecycleComponent
-
doClose
protected void doClose()
- Specified by:
doClosein classorg.elasticsearch.common.component.AbstractLifecycleComponent
-
boundAddress
public org.elasticsearch.common.transport.BoundTransportAddress boundAddress()
- Specified by:
boundAddressin interfaceorg.elasticsearch.http.HttpServerTransport
-
info
public org.elasticsearch.http.HttpInfo info()
- Specified by:
infoin interfaceorg.elasticsearch.http.HttpServerTransport
-
stats
public org.elasticsearch.http.HttpStats stats()
- Specified by:
statsin interfaceorg.elasticsearch.http.HttpServerTransport
-
getCorsConfig
public Netty4CorsConfig getCorsConfig()
-
exceptionCaught
protected void exceptionCaught(io.netty.channel.ChannelHandlerContext ctx, java.lang.Throwable cause) throws java.lang.Exception- Throws:
java.lang.Exception
-
configureServerChannelHandler
public io.netty.channel.ChannelHandler configureServerChannelHandler()
-
-