Record Class ClientHttpRequestFactorySettings
java.lang.Object
java.lang.Record
org.springframework.boot.web.client.ClientHttpRequestFactorySettings
- Record Components:
connectTimeout
- the connect timeoutreadTimeout
- the read timeoutbufferRequestBody
- if request body buffering is usedsslBundle
- the SSL bundle providing SSL configuration
public record ClientHttpRequestFactorySettings(Duration connectTimeout, Duration readTimeout, Boolean bufferRequestBody, SslBundle sslBundle)
extends Record
Settings that can be applied when creating a
ClientHttpRequestFactory
.- Since:
- 3.0.0
- See Also:
-
Field Summary
Modifier and TypeFieldDescriptionstatic final ClientHttpRequestFactorySettings
Use defaults for theClientHttpRequestFactory
which can differ depending on the implementation. -
Constructor Summary
ConstructorDescriptionClientHttpRequestFactorySettings
(Duration connectTimeout, Duration readTimeout, Boolean bufferRequestBody) ClientHttpRequestFactorySettings
(Duration connectTimeout, Duration readTimeout, Boolean bufferRequestBody, SslBundle sslBundle) Create a newClientHttpRequestFactorySettings
instance. -
Method Summary
Modifier and TypeMethodDescriptionReturns the value of thebufferRequestBody
record component.Returns the value of theconnectTimeout
record component.final boolean
Indicates whether some other object is "equal to" this one.final int
hashCode()
Returns a hash code value for this object.Returns the value of thereadTimeout
record component.Returns the value of thesslBundle
record component.final String
toString()
Returns a string representation of this record class.withBufferRequestBody
(Boolean bufferRequestBody) Return a newClientHttpRequestFactorySettings
instance with an updated buffer request body setting.withConnectTimeout
(Duration connectTimeout) Return a newClientHttpRequestFactorySettings
instance with an updated connect timeout setting .withReadTimeout
(Duration readTimeout) Return a newClientHttpRequestFactorySettings
instance with an updated read timeout setting.withSslBundle
(SslBundle sslBundle) Return a newClientHttpRequestFactorySettings
instance with an updated SSL bundle setting.
-
Field Details
-
DEFAULTS
Use defaults for theClientHttpRequestFactory
which can differ depending on the implementation.
-
-
Constructor Details
-
ClientHttpRequestFactorySettings
public ClientHttpRequestFactorySettings(Duration connectTimeout, Duration readTimeout, Boolean bufferRequestBody, SslBundle sslBundle) Create a newClientHttpRequestFactorySettings
instance.- Parameters:
connectTimeout
- the connection timeoutreadTimeout
- the read timeoutbufferRequestBody
- the bugger request bodysslBundle
- the ssl bundle- Since:
- 3.1.0
-
ClientHttpRequestFactorySettings
-
-
Method Details
-
withConnectTimeout
Return a newClientHttpRequestFactorySettings
instance with an updated connect timeout setting .- Parameters:
connectTimeout
- the new connect timeout setting- Returns:
- a new
ClientHttpRequestFactorySettings
instance
-
withReadTimeout
Return a newClientHttpRequestFactorySettings
instance with an updated read timeout setting.- Parameters:
readTimeout
- the new read timeout setting- Returns:
- a new
ClientHttpRequestFactorySettings
instance
-
withBufferRequestBody
Return a newClientHttpRequestFactorySettings
instance with an updated buffer request body setting.- Parameters:
bufferRequestBody
- the new buffer request body setting- Returns:
- a new
ClientHttpRequestFactorySettings
instance
-
withSslBundle
Return a newClientHttpRequestFactorySettings
instance with an updated SSL bundle setting.- Parameters:
sslBundle
- the new SSL bundle setting- Returns:
- a new
ClientHttpRequestFactorySettings
instance - Since:
- 3.1.0
-
toString
Returns a string representation of this record class. The representation contains the name of the class, followed by the name and value of each of the record components. -
hashCode
public final int hashCode()Returns a hash code value for this object. The value is derived from the hash code of each of the record components. -
equals
Indicates whether some other object is "equal to" this one. The objects are equal if the other object is of the same class and if all the record components are equal. All components in this record class are compared withObjects::equals(Object,Object)
. -
connectTimeout
Returns the value of theconnectTimeout
record component.- Returns:
- the value of the
connectTimeout
record component
-
readTimeout
Returns the value of thereadTimeout
record component.- Returns:
- the value of the
readTimeout
record component
-
bufferRequestBody
Returns the value of thebufferRequestBody
record component.- Returns:
- the value of the
bufferRequestBody
record component
-
sslBundle
Returns the value of thesslBundle
record component.- Returns:
- the value of the
sslBundle
record component
-