-
Notifications
You must be signed in to change notification settings - Fork 271
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
chore(fuzz): address hyper deprecations in fuzz tests #3455
Merged
Conversation
This file contains 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
this is a follow-up commit related to 24dc5d8 (#3445). see <linkerd/linkerd2#8733> for more information on upgrading to hyper 1.0. --- this addresses hyper deprecations in the http/1 tests for the inbound proxy. prior, we made use of `tower::ServiceExt::oneshot`, which consumes a service and drops it after sending a request and polling the response future to completion. <https://docs.rs/tower/0.5.2/src/tower/util/oneshot.rs.html#96-100> tower is not a 1.0 library yet, so `SendRequest` does not provide an implementation of `tower::Service` in hyper's 1.0 interface: - <https://docs.rs/hyper/0.14.31/hyper/client/conn/struct.SendRequest.html#impl-Service%3CRequest%3CB%3E%3E-for-SendRequest%3CB%3E> - <https://docs.rs/hyper/1.5.1/hyper/client/conn/http1/struct.SendRequest.html#trait-implementations> consequentially, we must drop the sender ourselves after receiving a response now. --- this commit *also* addresses hyper deprecations in the http/1 downgrade tests for the inbound proxy. because these tests involve a http/2 client and an http/1 server, we take the choice of inlining the body of `http_util::connect_and_accept()` rather than introducing a new, third `http_util::connect_and_accept_http_downgrade()` function. we will refactor these helper functions in follow-on commits. NB: because `ContextError` is internal to the `linkerd-app-test` crate, we do not wrap the errors. these are allegedly used by the fuzzing tests (_see f.ex #986 and #989_), but for our purposes with respect to the inbound proxy we can elide them rather than making `ctx()` a public method. --- Signed-off-by: katelyn martin <[email protected]>
this removes `connect_and_accept(..)`. this will break fuzzing builds, but it is not used elsewhere. Signed-off-by: katelyn martin <[email protected]>
Signed-off-by: katelyn martin <[email protected]>
this commit addresses other breakage found in the fuzz tests, tied to other previous work. after these changes, one can observe that the fuzz tests build and run once more by running the following: ```sh cargo +nightly fuzz run --fuzz-dir=linkerd/app/inbound/fuzz/ fuzz_target_1 ``` Signed-off-by: katelyn martin <[email protected]>
Signed-off-by: katelyn martin <[email protected]>
i see in the repository's github actions that the fuzzing action has been disabled, so i've confirmed that fuzzing tests build manually. |
olix0r
approved these changes
Dec 13, 2024
Base automatically changed from
kate/hyper-1.x-inbound-http1-client-deprecations
to
main
December 13, 2024 16:13
cratelyn
added a commit
that referenced
this pull request
Dec 13, 2024
this commit removes a duplicate function that was errantly defined, due to some issues when merging previous (interdependent) pr's. see - #3455 - #3454 - linkerd/linkerd2#8733 Signed-off-by: katelyn martin <[email protected]>
This was referenced Dec 13, 2024
cratelyn
added a commit
that referenced
this pull request
Dec 13, 2024
…3461) this commit removes a duplicate function that was errantly defined, due to some issues when merging previous (interdependent) pr's. see - #3455 - #3454 - linkerd/linkerd2#8733 Signed-off-by: katelyn martin <[email protected]>
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.
nb: this branch is based upon #3454.
see linkerd/linkerd2#8733 for more information on upgrading to hyper 1.0.
refactor(app/test): remove unused
http_util::connect_and_accept(..)
this removes
connect_and_accept(..)
. this will break fuzzing builds,but it is not used elsewhere.
chore(fuzz): address hyper deprecation in inbound fuzz tests
this commit addresses hyper deprecations in the inbound proxy's fuzz tests.
note that this commit does not compile. it was observed that some breakage had
accrued, because ci does not seem to be properly checking the fuzz tests.
chore(fuzz): address preëxisting fuzz breakage
this commit addresses breakage found in the fuzz tests, tied to
other previous work.
after these changes, one can observe that the fuzz tests build and run
once more by running the following: