Class ConfluenceHttpClientRequestFactory
- java.lang.Object
-
- com.atlassian.confluence.api.impl.sal.ConfluenceHttpClientRequestFactory
-
- 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 ConfluenceHttpClientRequestFactory extends Object implements com.atlassian.sal.api.net.NonMarshallingRequestFactory<com.atlassian.sal.api.net.Request<?,?>>
A specialisation of the standard SALHttpClientRequestFactorywhich configures the connection parameters usingConfluenceHttpParametersrather than using SAL's own defaults.In confluence 5.9, the system property specified by
SystemPropertiesConnectionConfig.HTTP_CONNECTION_TIMEOUT_PROPERTY_NAMEandSystemPropertiesConnectionConfig.HTTP_SOCKET_TIMEOUT_PROPERTY_NAMEwill be used to override the value in confluence, if they are provided.- Since:
- 5.7.2
-
-
Constructor Summary
Constructors Constructor Description ConfluenceHttpClientRequestFactory(SettingsManager settingsManager, org.springframework.aop.Advisor classLoaderAdvisor)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description com.atlassian.sal.api.net.RequestcreateRequest(com.atlassian.sal.api.net.Request.MethodType methodType, String url)booleansupportsHeader()
-
-
-
Constructor Detail
-
ConfluenceHttpClientRequestFactory
public ConfluenceHttpClientRequestFactory(SettingsManager settingsManager, org.springframework.aop.Advisor classLoaderAdvisor)
-
-
Method Detail
-
createRequest
public com.atlassian.sal.api.net.Request createRequest(com.atlassian.sal.api.net.Request.MethodType methodType, String url)- Specified by:
createRequestin interfacecom.atlassian.sal.api.net.RequestFactory<com.atlassian.sal.api.net.Request<?,?>>- 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_NAMEandSystemPropertiesConnectionConfig.HTTP_SOCKET_TIMEOUT_PROPERTY_NAMEif they are set.
-
supportsHeader
public boolean supportsHeader()
- Specified by:
supportsHeaderin interfacecom.atlassian.sal.api.net.RequestFactory<com.atlassian.sal.api.net.Request<?,?>>
-
-