Package com.softlayer.api.http
Class ThreadPooledHttpClientFactory
java.lang.Object
com.softlayer.api.http.HttpClientFactory
com.softlayer.api.http.ThreadPooledHttpClientFactory
public abstract class ThreadPooledHttpClientFactory extends HttpClientFactory
Class implemented by HTTP client factories that use a Java thread pool
-
Constructor Summary
Constructors Constructor Description ThreadPooledHttpClientFactory()
-
Method Summary
Modifier and Type Method Description abstract void
setThreadPool(ExecutorService threadPool)
By default the thread pool is a cached thread pool (using daemon threads) that is shutdown immediately when it is overwritten by this method or the factory is finalized.Methods inherited from class com.softlayer.api.http.HttpClientFactory
getDefault, getHttpClient
-
Constructor Details
-
ThreadPooledHttpClientFactory
public ThreadPooledHttpClientFactory()
-
-
Method Details
-
setThreadPool
By default the thread pool is a cached thread pool (using daemon threads) that is shutdown immediately when it is overwritten by this method or the factory is finalized. Callers who supply a thread pool are expected to handle its lifecycle. Null can be given here to revert to the default.- Parameters:
threadPool
-
-