[
https://issues.apache.org/jira/browse/CAMEL-13497?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Stephan Siano updated CAMEL-13497:
----------------------------------
Priority: Minor (was: Major)
> Setting a clientConfig parameter always creates new cookie store per endpoint
> -----------------------------------------------------------------------------
>
> Key: CAMEL-13497
> URL: https://issues.apache.org/jira/browse/CAMEL-13497
> Project: Camel
> Issue Type: Bug
> Components: camel-ahc
> Affects Versions: 2.23.2
> Reporter: Stephan Siano
> Assignee: Stephan Siano
> Priority: Minor
>
> If a clientConfig parameter is defined for an ahc endpoint, a new cookie
> store will be created on the endpoint, regardless of the configuration set to
> the clientConfig parameter.
> This makes it impossible to have an endpoint without a cookie store, when
> this parameter is set (which also means that the clientConfig parameter and
> the cookieHandler paramter do not work together).
> The root cause for this issue is that AhcComponent.cloneConfig() is called at
> several places in the code to create a configuration builder from the
> provided configuration. This method is calling new
> DefaultAsyncHttpClientConfig.Builder(clientConfig), to create that new
> builder, but this call will create a new cookie store on each invocation and
> provide it to the new builder. This means even if the cookie store is set to
> null in the provided configuration the client for the endpoint will be
> created with a cloned configuration, which will then have a new cookie store.
--
This message was sent by Atlassian JIRA
(v7.6.3#76005)