Conversation
Update from hyper 0.14 to hyper 1.0 ecosystem, matching the eventsource-client dependency. This includes: - Upgrade http crate from 0.2 to 1.0 - Use hyper-util for legacy Client API - Use http-body-util for body types - Update hyper-rustls from 0.24 to 0.27 - Update all trait bounds and type annotations - Add tower as direct dependency for Service trait BREAKING CHANGE: hyper-related trait bounds have changed for custom connector implementations. The Future associated type now requires Unpin bound, and trait bounds have been updated to use tower::Service and hyper_util::client::legacy::connect types.
Introduce a generic HttpTransport trait to decouple the SDK from specific HTTP client implementations. This follows the pattern established in eventsource-client. - Add transport.rs with HttpTransport trait and error types - Add transport_hyper.rs with hyper 1.0 implementation - Make hyper an optional dependency via feature flags - Use Bytes for request bodies (supports binary and empty) - Stream response bodies via ByteStream type alias This commit adds the abstraction without changing existing code.
Convert feature requester and polling data source to use the generic HttpTransport trait instead of hyper Client directly. - Replace HyperFeatureRequester<C> with HttpFeatureRequester<T> - Replace HyperFeatureRequesterBuilder with HttpFeatureRequesterBuilder - Update PollingDataSourceBuilder to accept transport - Stream and collect response body for JSON parsing - Remove hyper-specific imports and trait bounds - Update test helpers to use HyperTransport BREAKING CHANGE: PollingDataSourceBuilder generic parameter changed from connector (C) to transport (T: HttpTransport).
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
BEGIN_COMMIT_OVERRIDE
feat!: Replace local hyper dependency with new launchdarkly-sdk-transport
feat!: Remove deprecated initialized_async function
feat!: Allow filtering all_flags_state to mobile only
feat: Support synchronous event sending with new flush_blocking method
feat!: Add native-tls feature
feat: Choose crypto library with crypto-(aws-lc-rs|openssl) features
feat!: Enable event compression by default
END_COMMIT_OVERRIDE