Skip to content
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

fix(transport): use HttpsConnector in HyperTransport #1899

Open
wants to merge 2 commits into
base: main
Choose a base branch
from

Conversation

yash-atreya
Copy link
Member

Motivation

Currently the HyperTransport uses the HttpConnector as the default connector making it impossible to use: ProviderBuilder::new().on_builtin("https://..") when the hyper feature is enabled as it will always throw "invalid URL, scheme is not http".

Solution

Use HttpsConnector from the hyper_tls lib as default in HyperTransport.

PR Checklist

  • Added Tests
  • Added Documentation
  • Breaking changes

Copy link
Member

@mattsse mattsse left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm okay with making this the default personally but wonder if we should also feature gate this? like we do with reqwest

@@ -37,6 +37,7 @@ tracing = { workspace = true, optional = true }
http-body-util = { workspace = true, optional = true }
hyper = { workspace = true, default-features = false, optional = true }
hyper-util = { workspace = true, features = ["full"], optional = true }
hyper-tls = { workspace = true, optional = true }
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this now adds native-tls by default, should this be configurable instead?

@yash-atreya
Copy link
Member Author

I'm okay with making this the default personally but wonder if we should also feature gate this? like we do with request

@mattsse feature gated behind "hyper-tls"

@yash-atreya yash-atreya requested a review from mattsse January 8, 2025 14:20
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants