Http Client should support Http/2
See original GitHub issueDescription
Quarkus httpClient (quarkus-rest-client) should be able to works over http/2
as the server-side does. Otherwise, if we use quarkus-rest-client
for example to exchange data between microservices, then the server(even if is able to talk on Http/2
) will talk on the same protocol as the client libraries (Http1.1
).
Implementation ideas
Well, I will try to support several clients over the same interface (StrategyPattern
). So quarkus-rest-client
must be just the common interface of several HttpClient as …VertxHttpClient
(that supports Http/2
), OkHttp3
, ApacheHttpClient
…etc And then depends on your configuration, you should have some specific application.properties
.
Example:
Lets add the proposal common HttpClient interface quarkus-rest-client
and an implementation interface smallrye-mutiny-vertx-web-client
Dependencies:
<dependency>
<groupId>io.quarkus</groupId>
<artifactId>quarkus-rest-client</artifactId>
</dependency>
<dependency>
<groupId>io.smallrye.reactive</groupId>
<artifactId>smallrye-mutiny-vertx-web-client</artifactId>
</dependency>
application.properties
quarkus.client.http.http2=true
quarkus.client.http.ssl=true
quarkus.client.http.alpn=true
quarkus.client.http.truststore=META-INF/resources/client.keystore
quarkus.client.http.hostverified=false
Thank U!.
External references:
Issue Analytics
- State:
- Created 3 years ago
- Reactions:2
- Comments:10 (9 by maintainers)
It looks like we would have to upgrade to HttpClient 5.0. I don’t know yet what the implications would be, but I think it’s a great idea.
I think it would be good to do so