Skip to content

Auto-configured WebClient no longer uses context's ReactorResourceFactory #46658

@jorgegueyer

Description

@jorgegueyer

Hi All!

After updating my project to Spring 3.5.4, the behaviour of my application has changed:

With Spring Boot 3.4.8, I could override the ReactorResourceFactory bean and to provide my custom implementation to create a Reactor Http Client. With the new version (Spring Boot 3.5.4), this component isn't used in any way, even though the Spring Boot configuration provides a default bean. Also, the documentation the both versions
say the ReactorResourceFactory bean can be override by developers:

I provide a sample to show this problem: https://github.com/jorgegueyer/reactor-resource-factory-issue

To reproduce the problem, the class ReactorResourceFactoryIssueApplicationTests must be executed with the different versions of Spring Boot defined in the pom.xml.

The test class provides a configuration class to overwrite the ReactorResourceFactory default bean with a custom implementation where we add some traces when the getLoopResources() and getConnectionProvider() method are invoked.

Using the version 3.4.8, we can see the following traces in the console:

ReactorResourceFactoryIssueApplicationTests in 1.415 seconds (process running for 2.459)
Getting the ConnectionProvider
Getting the LoopResources

Using the version 3.5.4 this traces don't appear.

Metadata

Metadata

Assignees

No one assigned

    Labels

    status: supersededAn issue that has been superseded by anothertype: regressionA regression from a previous release

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions