public class NettyJaxrsServer extends Object implements EmbeddedJaxrsServer<NettyJaxrsServer>
| Modifier and Type | Field and Description |
|---|---|
protected io.netty.bootstrap.ServerBootstrap |
bootstrap |
protected int |
configuredPort |
protected ResteasyDeployment |
deployment |
protected SecurityDomain |
domain |
protected String |
hostname |
protected String |
root |
protected int |
runtimePort |
| Constructor and Description |
|---|
NettyJaxrsServer() |
protected io.netty.bootstrap.ServerBootstrap bootstrap
protected String hostname
protected int configuredPort
protected int runtimePort
protected ResteasyDeployment deployment
protected String root
protected SecurityDomain domain
public NettyJaxrsServer deploy()
deploy in interface EmbeddedJaxrsServer<NettyJaxrsServer>public NettyJaxrsServer start()
start in interface EmbeddedJaxrsServer<NettyJaxrsServer>public void stop()
stop in interface EmbeddedJaxrsServer<NettyJaxrsServer>public ResteasyDeployment getDeployment()
getDeployment in interface EmbeddedJaxrsServer<NettyJaxrsServer>public NettyJaxrsServer setDeployment(ResteasyDeployment deployment)
setDeployment in interface EmbeddedJaxrsServer<NettyJaxrsServer>public NettyJaxrsServer setPort(int port)
setPort in interface EmbeddedJaxrsServer<NettyJaxrsServer>public int getPort()
public NettyJaxrsServer setHostname(String hostname)
setHostname in interface EmbeddedJaxrsServer<NettyJaxrsServer>public String getHostname()
public NettyJaxrsServer setRootResourcePath(String rootResourcePath)
setRootResourcePath in interface EmbeddedJaxrsServer<NettyJaxrsServer>public NettyJaxrsServer setSecurityDomain(SecurityDomain sc)
setSecurityDomain in interface EmbeddedJaxrsServer<NettyJaxrsServer>public NettyJaxrsServer setSSLContext(SSLContext sslContext)
public NettyJaxrsServer setSniConfiguration(SniConfiguration sniConfiguration)
public SniConfiguration getSniConfiguration()
public NettyJaxrsServer setIoWorkerCount(int ioWorkerCount)
EventLoopGroupioWorkerCount - worker countpublic NettyJaxrsServer setExecutorThreadCount(int executorThreadCount)
EventExecutor.
If you want to disable the use of the EventExecutor specify a value <= 0. This should only be done if you are 100% sure that you don't have any blocking
code in there.executorThreadCount - thread countpublic NettyJaxrsServer setMaxRequestSize(int maxRequestSize)
maxRequestSize - the max request size. This is 10mb by default.public NettyJaxrsServer setMaxInitialLineLength(int maxInitialLineLength)
public NettyJaxrsServer setMaxHeaderSize(int maxHeaderSize)
public NettyJaxrsServer setMaxChunkSize(int maxChunkSize)
public NettyJaxrsServer setBacklog(int backlog)
public int getIdleTimeout()
public NettyJaxrsServer setIdleTimeout(int idleTimeoutSeconds)
idleTimeoutSeconds - - How many seconds to cleanup client connection. default value -1 meaning no idle timeout.public NettyJaxrsServer setChannelHandlers(List<io.netty.channel.ChannelHandler> channelHandlers)
ChannelHandlers to the ServerBootstrap.
The additional channel handlers are being added before the HTTP handling.
channelHandlers - the additional ChannelHandlers.public NettyJaxrsServer setHttpChannelHandlers(List<io.netty.channel.ChannelHandler> httpChannelHandlers)
ChannelHandlers to the ServerBootstrap.
The additional channel handlers are being added after the HTTP handling.
httpChannelHandlers - the additional ChannelHandlers.public NettyJaxrsServer setChannelOptions(Map<io.netty.channel.ChannelOption,Object> channelOptions)
ChannelOptions to the ServerBootstrap.channelOptions - the additional ChannelOptions.AbstractBootstrap.option(io.netty.channel.ChannelOption, Object)public NettyJaxrsServer setChildChannelOptions(Map<io.netty.channel.ChannelOption,Object> channelOptions)
ServerBootstrap.channelOptions - the additional child ChannelOptions.ServerBootstrap.childOption(io.netty.channel.ChannelOption, Object)protected RequestDispatcher createRequestDispatcher()
Copyright © 2020 JBoss by Red Hat. All rights reserved.