Class SetupHttpClientRequestFactory
- java.lang.Object
-
- com.atlassian.confluence.api.impl.sal.AbstractHttpClientFactory
-
- com.atlassian.confluence.api.impl.sal.SetupHttpClientRequestFactory
-
- All Implemented Interfaces:
com.atlassian.sal.api.net.NonMarshallingRequestFactory<com.atlassian.sal.api.net.Request<?,?>>
,com.atlassian.sal.api.net.RequestFactory<com.atlassian.sal.api.net.Request<?,?>>
public class SetupHttpClientRequestFactory extends AbstractHttpClientFactory
A specialisation of the standard SALHttpClientRequestFactory
which configures the connection parameters usingConfluenceHttpParameters
rather than using SAL's own defaults.In confluence 5.9, the system property specified by
SystemPropertiesConnectionConfig.HTTP_CONNECTION_TIMEOUT_PROPERTY_NAME
andSystemPropertiesConnectionConfig.HTTP_SOCKET_TIMEOUT_PROPERTY_NAME
will be used to override the value in confluence, if they are provided.- Since:
- 7.0.1
-
-
Field Summary
-
Fields inherited from class com.atlassian.confluence.api.impl.sal.AbstractHttpClientFactory
classLoaderAdvisor, httpClientRequestFactory
-
-
Constructor Summary
Constructors Constructor Description SetupHttpClientRequestFactory(org.springframework.aop.Advisor classLoaderAdvisor)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description com.atlassian.sal.api.net.Request
createRequest(com.atlassian.sal.api.net.Request.MethodType methodType, String url)
-
Methods inherited from class com.atlassian.confluence.api.impl.sal.AbstractHttpClientFactory
supportsHeader
-
-
-
-
Method Detail
-
createRequest
public com.atlassian.sal.api.net.Request createRequest(com.atlassian.sal.api.net.Request.MethodType methodType, String url)
- Returns:
- a request which has its connection and socket timeout set to the configured values in confluence, or the values specified
by the system properties
SystemPropertiesConnectionConfig.HTTP_CONNECTION_TIMEOUT_PROPERTY_NAME
andSystemPropertiesConnectionConfig.HTTP_SOCKET_TIMEOUT_PROPERTY_NAME
if they are set.
-
-