Skip to content

[PsrHttpMessageBridge] Support php-http/discovery for auto-detecting PSR-17 factories #51197

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Aug 1, 2023

Conversation

derrabus
Copy link
Member

@derrabus derrabus commented Jul 31, 2023

Q A
Branch? 6.4
Bug fix? no
New feature? yes
Deprecations? no
Tickets N/A
License MIT
Doc PR TODO

This PR follows the example of Symfony\Component\HttpClient\Psr18Client and makes all dependencies of PsrHttpFactory optional.

If php-http/discovery is not installed, I'm falling back to @Nyholm's implementation if it's available. This is consistent with Psr18Client's behavior. However, I wonder if this is the right course of action, given that php-http/discovery already handles the problem of discovering an implementation well.

@derrabus derrabus force-pushed the improvement/psr-discovery branch from e872db1 to 47b4992 Compare July 31, 2023 16:47
@fabpot
Copy link
Member

fabpot commented Aug 1, 2023

Thank you @derrabus.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants