public class ThreadPoolConfiguration extends Object
EventLoopGroup used by the proxy.| 限定符和类型 | 字段和说明 |
|---|---|
private int |
acceptorThreads |
private int |
clientToProxyWorkerIoRatio |
private int |
clientToProxyWorkerThreads |
private int |
proxyToServerWorkerIoRatio |
private int |
proxyToServerWorkerThreads |
| 构造器和说明 |
|---|
ThreadPoolConfiguration() |
| 限定符和类型 | 方法和说明 |
|---|---|
int |
getAcceptorThreads() |
int |
getClientToProxyWorkerIoRatio() |
int |
getClientToProxyWorkerThreads() |
int |
getProxyToServerWorkerIoRatio() |
int |
getProxyToServerWorkerThreads() |
ThreadPoolConfiguration |
withAcceptorThreads(int acceptorThreads)
Set the number of acceptor threads to create.
|
ThreadPoolConfiguration |
withClientToProxyWorkerIoRatio(int clientToProxyWorkerIoRatio) |
ThreadPoolConfiguration |
withClientToProxyWorkerThreads(int clientToProxyWorkerThreads)
Set the number of client-to-proxy worker threads to create.
|
ThreadPoolConfiguration |
withProxyToServerWorkerIoRatio(int proxyToServerWorkerIoRatio) |
ThreadPoolConfiguration |
withProxyToServerWorkerThreads(int proxyToServerWorkerThreads)
Set the number of proxy-to-server worker threads to create.
|
private int acceptorThreads
private int clientToProxyWorkerThreads
private int clientToProxyWorkerIoRatio
private int proxyToServerWorkerThreads
private int proxyToServerWorkerIoRatio
public int getClientToProxyWorkerThreads()
public ThreadPoolConfiguration withClientToProxyWorkerThreads(int clientToProxyWorkerThreads)
ProxyServerConstants.DEFAULT_INCOMING_WORKER_THREADS.clientToProxyWorkerThreads - number of client-to-proxy worker threads to createpublic int getClientToProxyWorkerIoRatio()
public ThreadPoolConfiguration withClientToProxyWorkerIoRatio(int clientToProxyWorkerIoRatio)
public int getAcceptorThreads()
public ThreadPoolConfiguration withAcceptorThreads(int acceptorThreads)
ProxyServerConstants.DEFAULT_INCOMING_ACCEPTOR_THREADS.acceptorThreads - number of acceptor threads to createpublic int getProxyToServerWorkerThreads()
public ThreadPoolConfiguration withProxyToServerWorkerThreads(int proxyToServerWorkerThreads)
ProxyServerConstants.DEFAULT_OUTGOING_WORKER_THREADS.proxyToServerWorkerThreads - number of proxy-to-server worker threads to createpublic int getProxyToServerWorkerIoRatio()
public ThreadPoolConfiguration withProxyToServerWorkerIoRatio(int proxyToServerWorkerIoRatio)
Copyright © 2022 Zodiac. All rights reserved.