Closed Lolf1010 closed 1 year ago
Found the reason: It only works (HTTP/2 + InputStream) only works with HTTPS. Not sure why it works with other bodies like String 🤷
The use of HTTPS in tests can mean significantly more effort. The bug should be reopened.
Running into this issue. Is there a workaround other than setting http version in client to 1.1? Anything I can do with wiremock options?
Proposal
It should work with both HTTP-Versions? Or can these Exception come from another place other than Wiremock ? If i create a "real" server using com.sun.net.httpserver.HttpServer then it works 🤷 If i dont send a stream but a byteArray of the stream (inefficient) then it works
Exceptions:
Reproduction steps
In JUnit5-Test regular WireMock.stubFor(...) without RequestBody-Matcher and then build HTTPClient using HTTPClient causes Exception with HTTP/2 but not HTTP/1.1 no additional headers specified
Debug-Log
--> looks like it does support "h2c" same as in the upgrade-request, but does not work 🤷 --> or is this more likely a problem in jetty ?
References