Package com.codebarrel.tenant.api.http
Class HttpClientFactoryImpl
java.lang.Object
com.codebarrel.tenant.api.http.HttpClientFactoryImpl
- All Implemented Interfaces:
HttpClientFactory
TODO: Replace ApacheHttpClientFactory usages in favour of this class to aid testing, particularly for lambdas
-
Constructor Summary
ConstructorsConstructorDescriptionHttpClientFactoryImpl(ApacheHttpClientFactory apacheHttpClientFactory, AddonProperties addonProperties) -
Method Summary
Modifier and TypeMethodDescriptioncreate(Environment env) Creates a HttpClient for dealing with the execution of requestscreate(Environment env, HttpRequestLogger requestLogger) Creates a HttpClient with a custom request logger.
-
Constructor Details
-
HttpClientFactoryImpl
@Inject public HttpClientFactoryImpl(ApacheHttpClientFactory apacheHttpClientFactory, AddonProperties addonProperties)
-
-
Method Details
-
create
Description copied from interface:HttpClientFactoryCreates a HttpClient for dealing with the execution of requests- Specified by:
createin interfaceHttpClientFactory- Returns:
- New HttpClient client
-
create
Description copied from interface:HttpClientFactoryCreates a HttpClient with a custom request logger.- Specified by:
createin interfaceHttpClientFactory
-