Class TestRestTemplate.CustomHttpComponentsClientHttpRequestFactory
java.lang.Object
org.springframework.http.client.HttpComponentsClientHttpRequestFactory
org.springframework.boot.test.web.client.TestRestTemplate.CustomHttpComponentsClientHttpRequestFactory
- All Implemented Interfaces:
Closeable
,AutoCloseable
,DisposableBean
,ClientHttpRequestFactory
- Enclosing class:
- TestRestTemplate
protected static class TestRestTemplate.CustomHttpComponentsClientHttpRequestFactory
extends HttpComponentsClientHttpRequestFactory
HttpComponentsClientHttpRequestFactory
to apply customizations.-
Constructor Summary
ConstructorDescriptionCustomHttpComponentsClientHttpRequestFactory
(TestRestTemplate.HttpClientOption[] httpClientOptions) -
Method Summary
Modifier and TypeMethodDescriptionprotected org.apache.hc.core5.http.protocol.HttpContext
createHttpContext
(HttpMethod httpMethod, URI uri) protected org.apache.hc.client5.http.config.RequestConfig
Methods inherited from class org.springframework.http.client.HttpComponentsClientHttpRequestFactory
close, createHttpUriRequest, createRequest, createRequestConfig, destroy, getHttpClient, mergeRequestConfig, postProcessHttpRequest, setBufferRequestBody, setConnectionRequestTimeout, setConnectTimeout, setHttpClient, setHttpContextFactory, setReadTimeout
-
Constructor Details
-
CustomHttpComponentsClientHttpRequestFactory
public CustomHttpComponentsClientHttpRequestFactory(TestRestTemplate.HttpClientOption[] httpClientOptions)
-
-
Method Details
-
createHttpContext
protected org.apache.hc.core5.http.protocol.HttpContext createHttpContext(HttpMethod httpMethod, URI uri) - Overrides:
createHttpContext
in classHttpComponentsClientHttpRequestFactory
-
getRequestConfig
protected org.apache.hc.client5.http.config.RequestConfig getRequestConfig()
-