vert.x icon indicating copy to clipboard operation
vert.x copied to clipboard

Feature/http3 support 5.x

Open imz87 opened this issue 1 year ago • 18 comments

Motivation This PR introduces support for HTTP/3 in Vert.x, leveraging the existing HTTP/3 facilities provided by Netty. The motivation behind this change is to bring the latest HTTP protocol version to Vert.x, allowing developers to take advantage of the performance improvements and new features that HTTP/3 offers, such as reduced latency, improved security, and better handling of packet loss.

Currently, the PR focuses on adding HTTP/3 support for the client side only. This is the first step towards full HTTP/3 integration in Vert.x. The server-side implementation will be addressed in a subsequent PR, and comprehensive testing will be conducted at that stage.

By enabling HTTP/3 support on the client side, this change positions Vert.x to remain a competitive and modern toolkit for reactive applications. It allows developers to begin experimenting with and utilizing HTTP/3 in their client applications, paving the way for broader adoption once server-side support is complete.

Co-Authored: @zekronium

imz87 avatar Sep 10 '24 15:09 imz87

@vietj It should be good for review and open for changes if needed

zekronium avatar Oct 28 '24 05:10 zekronium

@zekronium for now it is on hold until HTTP/3 is part of Netty 4.2 branch

vietj avatar Oct 28 '24 07:10 vietj

@vietj Why not have it as an optional dependency. Might take while, whilst other projects are already using it such as netty reactor

zekronium avatar Oct 29 '24 14:10 zekronium

Do you have some numbers to share? we tested HTTP/3 for internal networking (internal RPC) and it shows it performant bad than HTTP/2,

He-Pin avatar Dec 05 '24 08:12 He-Pin

@imz87 I had to make some internal changes, you should rebase this branch over latest master

vietj avatar Dec 05 '24 09:12 vietj

@imz87 I had to make some internal changes, you should rebase this branch over latest master @vietj , sure, I'll rebase my branch onto the latest master.

imz87 avatar Dec 05 '24 18:12 imz87

Do you have some numbers to share? we tested HTTP/3 for internal networking (internal RPC) and it shows it performant bad than HTTP/2,

@He-Pin I haven't tested HTTP/3 against anything yet, so I don't have any numbers or statistics to share at this time. I just added Http3Test.java, which is similar to Http2Test.java and serves as a kind of unit test.

imz87 avatar Dec 05 '24 18:12 imz87

@imz87 I had to make some internal changes, you should rebase this branch over latest master @vietj , sure, I'll rebase my branch onto the latest master.

@vietj , I just rebased onto the latest master.

imz87 avatar Dec 05 '24 20:12 imz87

Hi @vietj ,

I noticed that there's a NetSocket implementation for HTTP/2, and it seems to be used for WebSocket as well. Is something similar required for HTTP/3? Specifically, would we need a WebSocket based on an HTTP/3 connection?

Thanks, Iman

imz87 avatar Jan 21 '25 20:01 imz87

See https://github.com/netty/netty/issues/14739

vietj avatar Jan 29 '25 14:01 vietj

@imz87 yes this is needed, the main use case is HTTP CONNECT that tunnels a NetSocket.

vietj avatar Jan 29 '25 14:01 vietj

@imz87 yes this is needed, the main use case is HTTP CONNECT that tunnels a NetSocket.

Ok, thanks for your response.

imz87 avatar Jan 29 '25 18:01 imz87

Looking forward to this so I can switch from websockets to http3 streams.

indiealexh avatar Feb 15 '25 07:02 indiealexh

Looking forward to this so I can switch from websockets to http3 streams.

Great to hear! We're excited for you to try it out.

imz87 avatar Feb 15 '25 08:02 imz87

@imz87 can you rebase this to laster master ?

vietj avatar Feb 26 '25 17:02 vietj

@imz87 can you rebase this to laster master ?

@vietj It's done!

imz87 avatar Feb 27 '25 10:02 imz87

https://github.com/netty/netty/pull/14979 🎆

indiealexh avatar Apr 04 '25 21:04 indiealexh

netty/netty#14979 🎆

Still need http3 codec

zekronium avatar Apr 04 '25 23:04 zekronium