|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectcom.atlassian.httpclient.api.factory.HttpClientOptions
public final class HttpClientOptions
Configuration options for the http client instance and its caching system
| Constructor Summary | |
|---|---|
HttpClientOptions()
|
|
| Method Summary | |
|---|---|
ExecutorService |
getCallbackExecutor()
|
long |
getConnectionPoolTimeToLive()
|
long |
getConnectionTimeout()
|
List<String> |
getDheDisabledHosts()
|
long |
getIoSelectInterval()
Determines time interval in milliseconds at which the I/O reactor wakes up to check for timed out sessions and session requests. |
int |
getIoThreadCount()
Determines the number of I/O dispatch threads to be used by the I/O reactor. |
long |
getLeaseTimeout()
|
int |
getMaxCacheEntries()
|
long |
getMaxCacheObjectSize()
|
int |
getMaxCallbackThreadPoolSize()
|
int |
getMaxConnectionsPerHost()
|
long |
getMaxEntitySize()
|
ProxyOptions |
getProxyOptions()
|
com.atlassian.util.concurrent.Effect<Request> |
getRequestPreparer()
|
long |
getRequestTimeout()
|
long |
getSocketTimeout()
|
String |
getThreadPrefix()
|
String |
getUserAgent()
|
void |
setCallbackExecutor(ExecutorService callbackExecutor)
|
void |
setConnectionPoolTimeToLive(int connectionPoolTimeToLive,
TimeUnit timeUnit)
|
void |
setConnectionTimeout(int connectionTimeout,
TimeUnit timeUnit)
Sets how long, in milliseconds, to wait for a TCP connection |
void |
setDheDisabledHosts(List<String> dheDisabledHosts)
Disable DHE ciphers for certain hosts, to workaround a bug in JDK6. |
void |
setIoSelectInterval(int ioSelectInterval,
TimeUnit timeUnit)
Defines time interval in milliseconds at which the I/O reactor wakes up to check for timed out sessions and session requests. |
void |
setIoThreadCount(int ioThreadCount)
|
void |
setLeaseTimeout(long leaseTimeout)
|
void |
setMaxCacheEntries(int maxCacheEntries)
|
void |
setMaxCacheObjectSize(long maxCacheObjectSize)
|
void |
setMaxCallbackThreadPoolSize(int maxCallbackThreadPoolSize)
|
void |
setMaxConnectionsPerHost(int maxConnectionsPerHost)
|
void |
setMaxEntitySize(long maxEntitySize)
param maxEntitySize The maximum entity size in bytes |
void |
setProxyOptions(ProxyOptions proxyOptions)
Set proxy options for the client |
void |
setRequestPreparer(com.atlassian.util.concurrent.Effect<Request> requestPreparer)
|
void |
setRequestTimeout(int requestTimeout,
TimeUnit timeUnit)
|
void |
setSocketTimeout(int socketTimeout,
TimeUnit timeUnit)
|
void |
setThreadPrefix(String threadPrefix)
|
void |
setTrustSelfSignedCertificates(boolean trustSelfSignedCertificates)
|
void |
setUserAgent(String userAgent)
|
boolean |
trustSelfSignedCertificates()
|
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public HttpClientOptions()
| Method Detail |
|---|
public int getIoThreadCount()
10
public void setIoThreadCount(int ioThreadCount)
ioThreadCount - The number of I/O dispatch threads to be used by the I/O reactor.
May not be negative or zero.public long getIoSelectInterval()
1000 milliseconds.
public void setIoSelectInterval(int ioSelectInterval,
TimeUnit timeUnit)
public long getConnectionTimeout()
public void setConnectionTimeout(int connectionTimeout,
TimeUnit timeUnit)
connectionTimeout - Timeout value, defaults to 5000 millisecondstimeUnit - The time unitpublic long getSocketTimeout()
public void setSocketTimeout(int socketTimeout,
TimeUnit timeUnit)
socketTimeout - How long to wait for data, defaults to 20 secondstimeUnit - The time unitpublic long getRequestTimeout()
public void setRequestTimeout(int requestTimeout,
TimeUnit timeUnit)
requestTimeout - How long to wait for the entire request. Defaults to 30 seconds.timeUnit - The time unitpublic String getUserAgent()
public void setUserAgent(String userAgent)
userAgent - The user agent stringpublic String getThreadPrefix()
public void setThreadPrefix(String threadPrefix)
threadPrefix - Name prefix to use for spawned threadspublic long getConnectionPoolTimeToLive()
public void setConnectionPoolTimeToLive(int connectionPoolTimeToLive,
TimeUnit timeUnit)
connectionPoolTimeToLive - How long to allow connections to live in the pooltimeUnit - The time unitpublic int getMaxConnectionsPerHost()
public void setMaxConnectionsPerHost(int maxConnectionsPerHost)
maxConnectionsPerHost - How many connections are allowed per hostpublic long getMaxCacheObjectSize()
public void setMaxCacheObjectSize(long maxCacheObjectSize)
maxCacheObjectSize - The max cache object size in bytespublic int getMaxCacheEntries()
public void setMaxCacheEntries(int maxCacheEntries)
maxCacheEntries - The max cache entriespublic com.atlassian.util.concurrent.Effect<Request> getRequestPreparer()
public void setRequestPreparer(com.atlassian.util.concurrent.Effect<Request> requestPreparer)
requestPreparer - The effect to apply before the request is executedpublic long getMaxEntitySize()
public long getLeaseTimeout()
public void setLeaseTimeout(long leaseTimeout)
leaseTimeout - The maximum time request to be kept in queue before execution, after timeout - request will be removedpublic void setMaxEntitySize(long maxEntitySize)
public int getMaxCallbackThreadPoolSize()
public void setMaxCallbackThreadPoolSize(int maxCallbackThreadPoolSize)
maxCallbackThreadPoolSize - The maximum number of threads that can be used for executing callbackspublic void setCallbackExecutor(ExecutorService callbackExecutor)
public ExecutorService getCallbackExecutor()
public void setTrustSelfSignedCertificates(boolean trustSelfSignedCertificates)
public boolean trustSelfSignedCertificates()
public void setProxyOptions(@Nonnull
ProxyOptions proxyOptions)
proxyOptions - Proxy options created using ProxyOptions.ProxyOptionsBuilder.public ProxyOptions getProxyOptions()
public List<String> getDheDisabledHosts()
public void setDheDisabledHosts(List<String> dheDisabledHosts)
dheDisabledHosts -
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||