You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@cxf.apache.org by "Andriy Redko (Jira)" <ji...@apache.org> on 2024/05/27 12:15:00 UTC

[jira] [Resolved] (CXF-9017) Regression in proxy-based restful client

     [ https://issues.apache.org/jira/browse/CXF-9017?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Andriy Redko resolved CXF-9017.
-------------------------------
    Resolution: Duplicate

> Regression in proxy-based restful client
> ----------------------------------------
>
>                 Key: CXF-9017
>                 URL: https://issues.apache.org/jira/browse/CXF-9017
>             Project: CXF
>          Issue Type: Bug
>            Reporter: Ivan Iliev
>            Priority: Critical
>
> The memory leak fix introduced in https://issues.apache.org/jira/browse/CXF-8946 breaks the way the ClientProxyImpl works. It passes its ClientConfiguration down to sub-proxies. When those sub-proxies get garbage collected, that configuration gets closed. One of the objects that are closed is AbstractConduitSelector -> conduits.
> After that, any newly created sub-proxies will have misconfigured clients. For example, we are configuring TLSClientParameters on the conduit of the root, which gets wiped out and therefore the new child clients can no longer connect.
> {code:java}
> API api = JAXRSClientFactory.create(endpoint, <API.class>, getCxfProviders(), true); // root proxy
> configure(api);//add TLSClientParameters
> SomeResource s = api.getSomeResource(); // sub-proxy
> ....
> <garbage collect s and its underlying client>
> SomeOtherResource s2 = api.get(); //broken{code}



--
This message was sent by Atlassian Jira
(v8.20.10#820010)