|
||||||||||
| 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 | |
|---|---|
java.util.concurrent.ExecutorService |
getCallbackExecutor()
|
long |
getConnectionPoolTimeToLive()
|
long |
getConnectionTimeout()
|
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. |
int |
getMaxCacheEntries()
|
long |
getMaxCacheObjectSize()
|
int |
getMaxConnectionsPerHost()
|
long |
getMaxEntitySize()
|
com.atlassian.util.concurrent.Effect<Request> |
getRequestPreparer()
|
long |
getRequestTimeout()
|
long |
getSocketTimeout()
|
java.lang.String |
getThreadPrefix()
|
java.lang.String |
getUserAgent()
|
void |
setCallbackExecutor(java.util.concurrent.ExecutorService callbackExecutor)
|
void |
setConnectionPoolTimeToLive(int connectionPoolTimeToLive,
java.util.concurrent.TimeUnit timeUnit)
|
void |
setConnectionTimeout(int connectionTimeout,
java.util.concurrent.TimeUnit timeUnit)
Sets how long, in milliseconds, to wait for a TCP connection |
void |
setIoSelectInterval(int ioSelectInterval,
java.util.concurrent.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 |
setMaxCacheEntries(int maxCacheEntries)
|
void |
setMaxCacheObjectSize(long maxCacheObjectSize)
|
void |
setMaxConnectionsPerHost(int maxConnectionsPerHost)
|
void |
setMaxEntitySize(long maxEntitySize)
param maxEntitySize The maximum entity size in bytes |
void |
setRequestPreparer(com.atlassian.util.concurrent.Effect<Request> requestPreparer)
|
void |
setRequestTimeout(int requestTimeout,
java.util.concurrent.TimeUnit timeUnit)
|
void |
setSocketTimeout(int socketTimeout,
java.util.concurrent.TimeUnit timeUnit)
|
void |
setThreadPrefix(java.lang.String threadPrefix)
|
void |
setUserAgent(java.lang.String userAgent)
|
| 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,
java.util.concurrent.TimeUnit timeUnit)
public long getConnectionTimeout()
public void setConnectionTimeout(int connectionTimeout,
java.util.concurrent.TimeUnit timeUnit)
connectionTimeout - Timeout value, defaults to 5000 millisecondstimeUnit - The time unitpublic long getSocketTimeout()
public void setSocketTimeout(int socketTimeout,
java.util.concurrent.TimeUnit timeUnit)
socketTimeout - How long to wait for data, defaults to 20 secondstimeUnit - The time unitpublic long getRequestTimeout()
public void setRequestTimeout(int requestTimeout,
java.util.concurrent.TimeUnit timeUnit)
requestTimeout - How long to wait for the entire request. Defaults to 30 seconds.timeUnit - The time unitpublic java.lang.String getUserAgent()
public void setUserAgent(java.lang.String userAgent)
userAgent - The user agent stringpublic java.lang.String getThreadPrefix()
public void setThreadPrefix(java.lang.String threadPrefix)
threadPrefix - Name prefix to use for spawned threadspublic long getConnectionPoolTimeToLive()
public void setConnectionPoolTimeToLive(int connectionPoolTimeToLive,
java.util.concurrent.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 void setMaxEntitySize(long maxEntitySize)
public void setCallbackExecutor(java.util.concurrent.ExecutorService callbackExecutor)
public java.util.concurrent.ExecutorService getCallbackExecutor()
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||