Putting HTTP/3 in Quarkus 4 to the Test
Introduction
HTTP/3 is the third major version of the Hypertext Transfer Protocol. It preserves the semantics that web developers already know, namely methods, status codes, header fields and message bodies, while it replaces the transport on which these semantics travel. HTTP/1.1 and HTTP/2 rely on the Transmission Control Protocol (TCP), whereas HTTP/3 relies on QUIC, a transport protocol standardized by the Internet Engineering Task Force in RFC 9000 and built on top of the User Datagram Protocol (UDP).
Quarkus 4.0, released in November 2026, introduces an experimental extension named quarkus-http3. With this extension, a Quarkus application serves HTTP/1.1, HTTP/2 and HTTP/3 on one and the same HTTPS port, the first two over TCP and the third over UDP, and a Quarkus REST client is able to call remote services over HTTP/3.
This article studies that extension through a small but realistic application, a service that delivers the many small images of a web page, and through a benchmark that measures what HTTP/3 changes in practice. The article pays particular attention to header compression, which HTTP/2 performs with HPACK and HTTP/3 performs with QPACK, and to the number of network round trips that each protocol requires before the first byte of a response reaches the client, which this article calls the round trip time (RTT) budget of a request.
The article also reports several defects of the extension in its version 4.0.1, together with a defect of the QUIC implementation on which it relies. It tries to explain these defects root causes, and presents the workarounds that the project applies. It concludes that the support of HTTP/3 in Quarkus 4.0.1 conforms to the specifications but has not yet reached the maturity that production use requires, mainly because some requests never complete on networks that lose packets. The complete source code is available in the accompanying GitHub repository, nicolasduminil/http3-quarkus.
From HTTP/1.1 to HTTP/3
Each version of HTTP addresses a limitation of its predecessor. This section therefore follows that evolution, from the multiple connections of HTTP/1.1 through the multiplexing of HTTP/2 to the replacement of TCP by QUIC.
HTTP/1.1 and the cost of connections
HTTP/1.1 transmits one request at a time on a TCP connection and waits for the complete response before sending the next request on the same connection. Browsers compensate for this sequential behavior by opening several connections to the same origin, typically six. Each connection, however, requires its own TCP handshake and its own TLS handshake, and each connection discovers the available bandwidth independently through the slow start mechanism of TCP congestion control.
HTTP/2 and multiplexing
HTTP/2, standardized in RFC 9113, multiplexes many concurrent requests on a single TCP connection. Each request and its response form a stream, identified by a stream number, and the frames of all streams are interleaved on the connection. HTTP/2 also introduced HPACK, a header compression scheme that removes most of the redundancy between the header fields of successive requests.
Head of line blocking in TCP
TCP offers an ordered byte stream. When a segment is lost, the receiving TCP stack withholds every subsequent byte from the application until the retransmission of the lost segment has arrived, even when those subsequent bytes belong to other HTTP/2 streams that are complete. This phenomenon is called transport level head of line blocking. On a reliable network it remains invisible, but on a network that loses packets, a single loss delays every response multiplexed on the connection.

HTTP/3 and QUIC
QUIC moves stream multiplexing into the transport itself. Each HTTP/3 request travels on its own QUIC stream, and QUIC delivers the data of each stream as soon as that stream is complete, independently of losses that affect other streams. QUIC integrates TLS 1.3 into its own handshake, so that a single exchange establishes both the transport state and the encryption keys. QUIC is implemented in user space on top of UDP, which allows it to evolve without changes to operating system kernels, at the cost of a higher processing load than the kernel implementation of TCP.

QUIC provides several further mechanisms which we’re referencing later. Connection identifiers allow a connection to survive a change of the client address, for example when a mobile device moves from a wireless network to a cellular network, a mechanism called connection migration. Session resumption with 0-RTT allows a client that has already connected to a server to send its first request together with its first handshake packet. Address validation allows a server to verify that a client really owns the source address of its packets before the server sends large amounts of data to that address.
Discovering HTTP/3: the Alt-Svc mechanism
A client that receives a URL beginning with https:// has no prior knowledge that the server supports HTTP/3. The client therefore starts with TCP, and the server advertises HTTP/3 through an alternative service, defined in RFC 7838. The advertisement takes the form of a response header field:
Alt-Svc: h3=":8443"; ma=3600
This field states that the same origin is reachable with the protocol identified as h3 on port 8443 of the same host, and that the client may remember this information for 3600 seconds. RFC 7838 also defines an ALTSVC frame for HTTP/2, which conveys the same information outside any response header block. Browsers use the advertisement for subsequent requests, which explains why the first page load of a new site usually happens over HTTP/2 and the following ones over HTTP/3.

Header compression: HPACK and QPACK
Header compression is one of the subjects that we’re examining here in detail. This section explains why the header fields of HTTP deserve compression, presents the principles common to HPACK and QPACK, and shows why the independent streams of QUIC required QPACK to replace HPACK. It also describes how Quarkus 4.0.1 applies QPACK in practice.
Why header compression matters
A modern web page issues dozens of requests to the same origin, and each request carries header fields such as the user agent, the accepted media types, cookies and caching directives. Responses carry security policies, caching directives and entity tags. These fields repeat almost identically from one exchange to the next, and on a page of small resources, such as the map tiles of this project, the header fields can represent a significant share of the transferred bytes.
Principles of header compression
A header field is a pair formed by a name and a value, such as content-type: image/png. The request or response header fields can be compressed and, then, they form a header block.
Header compression involves two components on each connection:
- an encoder that belongs to the sender of a message and converts its list of header fields into a compact header block;
- a decoder that belongs to the receiver and reconstructs the original list from that block.
Each direction of a connection has its own pair: the encoder of the client and the decoder of the server process the requests, while the encoder of the server and the decoder of the client process the responses.
The encoder has tables in which it stores header fields and replaces them, in exchanges, by their associated references. There are two kind of tables: static and dynamic. The static table is a fixed list of common header fields defined by the specification of the protocol. Every implementation contains the same static table, which never changes, and the encoder designates one of its entries by a number called an index. The decoder has the same static tables. The dynamic table starts empty when the connection opens. The encoder inserts into it the header fields that it expects to send again, and it instructs the decoder to perform the same insertions in the same order, so that both components hold identical copies of the table. A header field already present in the dynamic table then travels as an index of one or two bytes. The dynamic table has a maximum size, and the oldest entries leave it when a new entry requires their space.
A header field that neither table contains travels as a literal, that is, as its name and its value written out. The encoder may still reference the name alone in a table and write only the value. Finally, the encoder may apply to each literal string a compression technique, named Huffman coding, that shortens it.
HPACK
HPACK, defined in RFC 7541, applies these techniques to HTTP/2. Its static table contains 61 entries, such as :method: GET or the name content-type without a value. When its encoder sends a literal header field, it can ask the decoder to insert the field into its copy of the dynamic table. The decoder chooses the maximum size of this table, 4096 bytes by default.
HPACK relies on a strict assumption: the decoder processes header blocks in exactly the order in which the encoder produced them, because each block may modify the dynamic table that the next block uses. TCP guarantees this order, since HTTP/2 transmits all frames of a connection on a single ordered byte stream.
Why HTTP/3 needs QPACK
QUIC delivers each stream independently. If HTTP/3 reused HPACK, a header block arriving on one stream could reference a dynamic table entry inserted by a block that is still in transit on another stream, and the decoder would have to wait for that other stream. Header compression would then reintroduce exactly the head of line blocking that QUIC removes.
QPACK, defined in RFC 9204, resolves this problem by separating the modification of the dynamic table from its use. The encoder sends table insertions on a dedicated unidirectional stream, called the encoder stream, and the decoder acknowledges them on another unidirectional stream, called the decoder stream. Each header block declares the number of insertions it requires, the Required Insert Count. A request stream whose header block references entries that have not yet arrived is blocked, and only that stream waits. The decoder announces how many streams it accepts to block through the setting SETTINGS_QPACK_BLOCKED_STREAMS, and the size of its dynamic table through SETTINGS_QPACK_MAX_TABLE_CAPACITY. The encoder may also decide to reference only entries already acknowledged, which avoids blocking entirely at the cost of a lower compression ratio. QPACK provides a larger static table than HPACK, with 99 entries, and keeps Huffman coding.

QPACK in Quarkus 4.0.1
Quarkus serves HTTP/3 through Eclipse Vert.x 5.2.3, which delegates the protocol to Netty 4.2.20. Netty implements HTTP/3 and QPACK in Java, and relies for the QUIC transport on quiche. This is the open source QUIC implementation written in Rust by Cloudflare, which Netty ships as a native library. The QPACK encoder of Netty supports the dynamic table. Vert.x, however, disables dynamic tables by creating the Netty HTTP/3 connection handler with the parameter disableQpackDynamicTable set to true. This is also the default of Netty, in every version from 5.1.0 to 5.2.3, and neither Vert.x nor Quarkus exposes an option to change it, such that to enable dynamic tables. The HTTP/3 server of Quarkus therefore compresses response headers with the static table and with Huffman coding only, and its dynamic table stays empty. While this choice simplifies the implementation and excludes blocked streams, it reduces however the compression ratio for header fields that the static table does not contain.
The HPACK encoder of Netty, used for HTTP/2, populates the dynamic table. Consequently, in this implementation, HTTP/2 uses a dynamic table whereas HTTP/3 doesn’t. The benchmark measures the effect of this difference with a dedicated measurement, presented later.
The Quarkus HTTP/3 extension
The extension quarkus-http3 covers both sides of an exchange. On the server side, it adds a QUIC listener next to the existing HTTPS listener, and on the client side, it allows the Quarkus REST client to call a remote service over HTTP/3. This section presents the configuration that each side requires.
Enabling HTTP/3
The extension requires one dependency:
<dependency>
<groupId>io.quarkus</groupId>
<artifactId>quarkus-http3</artifactId>
</dependency>
With Maven, the extension also selects the native QUIC library of the build platform, netty-codec-native-quic with a classifier such as linux-x86_64, through Maven profile activation. An application built on one platform and deployed on another must declare the classifier of the target platform explicitly.
HTTP/3 mandates TLS 1.3. In development and test modes, the extension generates a certificate automatically when no TLS configuration exists, signed by the Quarkus development certificate authority when that authority is installed, and self-signed otherwise. In production mode, the application must configure TLS through its registry, with a PKCS12 key store, whose location and password come from environment variables:
%prod.quarkus.tls.key-store.p12.path=${TLS_KEYSTORE:/certs/tile-service.p12}
%prod.quarkus.tls.key-store.p12.password=${TLS_KEYSTORE_PASSWORD}
The extension exposes three configuration properties: quarkus.http3.enabled, quarkus.http3.alt-svc and quarkus.http3.alt-svc-max-age. The server then listens on the HTTPS port, 8443 by default, for TCP connections carrying HTTP/1.1 and HTTP/2 and for UDP datagrams carrying QUIC.
The REST client over HTTP/3
A Quarkus REST client is a Java interface annotated with @RegisterRestClient. The attribute configKey of this annotation gives the client a name, which its configuration properties then reuse. In the following example, the operations of the client come from the interface TileApi, presented with the demonstration application:
@RegisterRestClient(configKey = "tiles-h3")
public interface TileH3Client extends TileApi {
}
The name of each property combines three parts. The prefix quarkus.rest-client is fixed and designates the REST client configuration. The middle part is the value of configKey, here tiles-h3, which selects the client that the property concerns. The last part is fixed and names the setting, such as url for the address of the target service or http3 for the protocol. The client switches to HTTP/3 with the setting http3, and its target must be an HTTPS URL:
quarkus.rest-client.tiles-h3.url=https://localhost:8443
quarkus.rest-client.tiles-h3.http3=true
The client connects with QUIC directly, without a preliminary TCP request and without consulting Alt-Svc, and it never falls back to TCP. When UDP is blocked between the client and the service, the request fails once the read timeout of the client expires, with a ProcessingException whose message reads “The timeout of N ms has been exceeded when getting a connection”. The message mentions neither QUIC nor UDP, which deserves attention when diagnosing a firewall that filters UDP. A pure client application must also depend on quarkus-http3, because the client needs the native QUIC library, and the extension then starts an HTTP server and a QUIC listener in the client process as well.
The demonstration application
The concepts presented so far take a concrete form in a demonstration application, which the tests and the benchmark of this article exercise. This section describes the workload that the application serves, the Maven modules that compose it, the way it reports the protocol of each exchange and its errors, and a browser page that shows HTTP/3 at work.
The use case
The application reproduces a common workload of the web: a page that displays many small images at once. A photo gallery, a product catalogue and an interactive map share this pattern, in which the browser requests dozens of images of a few kilobytes at the same moment. This workload is precisely the one where the multiplexing of HTTP/2 and HTTP/3, and the head of line blocking that distinguishes them, make a measurable difference.
The project takes the map described above as its concrete example. This map is too big to be displayed entirely, accordingly, different parts of itself, called views, are displayed as a grid of tiles of 256 by 256 pixels. One view contains 8 by 8 tiles, that is 64 images of about 7 kilobytes each. The URL of each tile carries three integers, /tiles/{z}/{x}/{y}.png, where z selects the level of detail and x and y select the column and the row.
The content of the images is computed from a mathematical figure called the Mandelbrot set. This figure has been chosen because it has the property to produce a distinct image, for every tile, based on a short computation, without having to store or download files. The same image is always produced for the same tile.
The Maven modules
The project consists of a parent POM and six modules, as follows:
- the
tile-commonmodule contains the Jakarta REST interface shared by the server and the client, together with the records that describe tiles and grids; - the
tile-servicemodule contains the Quarkus application that renders the tiles; - the
tile-clientmodule contains a Quarkus command line application that fetches a page of tiles with a chosen protocol; - the
tile-mapmodule contains a web application that displays the map in a browser; - the
tile-server-supportmodule gathers the server-side code thattile-serviceandtile-mapshare, namely the protocol header fields, the HTTP/3 server settings and the error responses; - the
tile-testingmodule provides the test container oftile-serviceto the modules whose tests need it; - the
benchmarkdirectory contains the benchmark tooling outside the Maven build.
The shared interface defines the following operations:
@Path("/tiles")
public interface TileApi {
String IMAGE_PNG = "image/png";
String X_PROTOCOL = "X-Protocol";
@GET
@Path("/{z}/{x}/{y}.png")
@Produces(IMAGE_PNG)
RestResponse<byte[]> tile(@PathParam("z") int z,
@PathParam("x") int x, @PathParam("y") int y);
@GET
@Path("/{z}/{x}/{y}/meta")
@Produces(MediaType.APPLICATION_JSON)
RestResponse<TileMeta> meta(@PathParam("z") int z,
@PathParam("x") int x, @PathParam("y") int y);
@GET
@Path("/grid")
@Produces(MediaType.APPLICATION_JSON)
TileGrid grid(@QueryParam("z") int z, @QueryParam("x") int x,
@QueryParam("y") int y,
@QueryParam("size") @DefaultValue("8") int size);
}
The tile operation returns a PNG image. The grid operation returns an instance of the record TileGrid, serialized as JSON, which describes one view: its level of detail, the coordinates of its first tile, its size and the list of the paths of its size by size tiles, 64 by default. The meta operation returns a small JSON document together with a realistic set of about one kilobyte of response header fields, such as Content-Security-Policy, Strict-Transport-Security and Cache-Control. This last operation exists to measure header compression, because its header fields dominate its body.
The module tile-service implements the interface in TileResource, and tile-client declares three REST client interfaces that extend it, one for each protocol. The operations tile and meta return RestResponse, a specific type of Quarkus REST that carries the body of a response together with its status and its header fields. On the server side, TileResource uses it to add header fields such as ETag to the response. On the client side, it gives access to the header fields received, among which X-Protocol.
Making the protocol visible
The application code is identical for the three protocols, and Quarkus selects the protocol below the application. To make the protocol observable, a Vert.x filter adds the header field X-Protocol to every response, with the value HTTP/1.1, HTTP/2 or HTTP/3 taken from the request as the server received it. The same filter emits the Alt-Svc header field, for a reason explained in the next section.
void register(@Observes Filters filters) {
filters.register(rc -> {
rc.addHeadersEndHandler(v -> decorate(rc));
rc.next();
}, 100);
}
The callback registered with addHeadersEndHandler runs at the moment Vert.x is about to send the response head, after the application has set its status and its header fields. The filter covers the static demonstration page as well as the REST endpoints.
Errors as Problem Details
Every error response follows RFC 9457, Problem Details for HTTP APIs, with the media type application/problem+json. An invalid tile, for example a column that exceeds the number of columns of its level of detail, produces a status 400 with a stable problem type. Unknown paths produce a status 404 in the same format.
Watching HTTP/3 in the browser
Tests and measurements establish what the protocol does, but a browser shows it. The tile-map module is a web application that displays the 64 tiles of a view and the protocol that carried each of them. The application is itself served over HTTP/3: the browser receives its page and its updates from tile-map over HTTP/3, and loads the tiles directly from tile-service, also over HTTP/3.
The page is rendered by Qute, the template engine of Quarkus, through the Quarkus REST resource MapResource. Navigation relies on htmx, a small JavaScript library that supports AJAX-like partial updates, according to attributes placed on the HTML elements. Each button of the map declares the fragment it requests, the element it replaces, and the address that the browser keeps in its history:
<button id="zoom-in" hx-get="/map?{viewport.zoomIn.query}"
hx-target="#map" hx-swap="outerHTML"
hx-push-url="/?{viewport.zoomIn.query}">Zoom in</button>
The Qute template defines the map as a fragment of the page, so that the resource renders either the complete page or the map alone from the same source. The viewport, that is the level of detail and the position of the displayed part of the map, travels in the query string, which keeps the server free of session state and makes every view bookmarkable.
I know that this is an unpopular statement nowadays where Angular, Vue, React and other JavaScript libraries are running riot but, in general, I don’t advocate the idea of JavaScript user interfaces in Java applications. A component framework based on the Servlet API, such as PrimeFaces, would have been more appropriated and was the first candidate for this application. But I got stuck by the fact that, in Quarkus 4.0.1, every Servlet request over HTTP/3 fails with a ClassCastException. This is because the Vert.x adapter of the Quarkus Servlet implementation converts each connection to the class ConnectionBase, which the HTTP/3 connection of Vert.x does not extend. Hence, Qute and htmx in order to avoid the Servlet layer entirely.
The browser reports the protocol through the Resource Timing specification of the W3C. For every resource that a page loads, the browser records an object of the JavaScript interface PerformanceResourceTiming, which holds the timings of the resource and the protocol of the connection in the attribute nextHopProtocol, and the function performance.getEntriesByName() returns these objects for a given URL. A few lines of JavaScript read this attribute when each tile has loaded. They treat a resource decoded without any byte transferred as a response of the browser cache, and report the protocol as unknown when the browser withholds it:
function protocolOf(entry) {
if (!entry) return 'cache';
if (entry.transferSize === 0 && entry.decodedBodySize > 0) return 'cache';
return entry.nextHopProtocol || 'unknown';
}
The browser exposes these details for a resource of another origin only when the response carries the header field Timing-Allow-Origin naming the page origin. tile-service therefore adds this field when the property tiles.timing-allow-origin is set, and the deployments of the map set it to the origin of tile-map. The benchmark leaves it unset, so that the header bytes that it measures remain unchanged.
A click on a tile adds a second HTTP/3 connection to the scene. The browser sends an htmx request to tile-map, which fetches the metadata of the tile from tile-service with the Quarkus REST client configured for HTTP/3. The returned fragment shows the metadata, the protocol that tile-service reports in its X-Protocol header field, and the duration of the request. This way the page documents a chain in which the browser talks to tile-map and tile-map talks to tile-service, both over HTTP/3. The client declares the operation with the return type Uni of Mutiny, the reactive programming library of Quarkus, in which a Uni represents a single result that arrives later. tile-map can therefore bound the request itself:
return tiles.meta(z, x, y)
.ifNoItem().after(config.metaTimeout()).fail()
.map(response -> Templates.index$meta(...))
.onFailure().recoverWithItem(failure ->
Templates.index$metaFailure(tile, reason(failure)));
The reader may be surprised to find the reactive style in this code, at a time when virtual threads, available since Java 21, allow a sequential implementation to wait for a response at almost no cost. This choice follows from the behavior of the HTTP/3 client, and not from a preference of style, as the explanation of the pipeline shows.
The pipeline above reads as follows. The call ifNoItem().after(...).fail() sets a time limit, given by the property tiles.map.meta-timeout and turns into a failure a response that has not arrived when it expires. This time limit is necessary, because the read timeout of the REST client never ends an HTTP/3 request and because a request whose end of stream is lost waits indefinitely. The reactive style is the appropriate choice here because it allows the request to be canceled. A sequential implementation, running on a virtual thread, would declare the operation with the blocking return type RestResponse<TileMeta>. With such a blocking client, the sequential style offers no direct means of canceling the request: the only limit the call accepts is the read timeout, which HTTP/3 ignores. An external mechanism, such as a Future awaited with a time limit, releases the waiting thread, while the request itself continues and its HTTP/3 stream remains open on the connection. The Uni returned by the reactive client, by contrast, can be canceled: when the time limit expires, Mutiny cancels the subscription and the client aborts the HTTP/3 stream. The reactive pipeline thus expresses the time limit, the cancellation of the request and the fallback in a single expression, and occupies no thread while the response is pending.
Browsers impose a condition of their own on HTTP/3. With the self-signed certificate of this project, Firefox uses HTTP/3 only after the preference network.http.http3.disable_when_third_party_roots_found is set to false. Chromium follows Alt-Svc only for certificates issued by an authority it knows, so that it needs command line flags that force QUIC for the two origins. With the Firefox preference, the page shows the discovery mechanism at work. The first load uses HTTP/2 for the page and for the 64 tiles, because the browser knows neither origin yet. The second load uses HTTP/3 for the page, the tiles and every update. The test MapBrowserTest drives Firefox through Playwright, a library that controls browsers from Java, and verifies against a tile-service container, in every build, that the second load and the following update travel over HTTP/3.
A second page of tile-map turns the map into a comparison lab. The Compose profile lab starts a second instance of tile-service on the port 9443, which advertises no HTTP/3 and therefore serves its tiles over HTTP/2 only. The second instance shares the network namespace of the first, so that the netem sidecar of the benchmark shapes the packets of both origins identically. The page fetches the same 64 tiles from both origins at the same time and shows, for each origin:
- the protocols used;
- the time spent opening a new connection;
- the total load time;
- the waterfall in which every request appears as a bar between its start and its end.
Each run adds a distinct query string to the tile addresses, so that the browser fetches every tile over the network instead of reusing its cache. Buttons apply the network profiles lan, wan, lossy and degraded. tile-map writes the requested profile into the directory that the sidecar watches and waits for its acknowledgement. Since the browser runs on the host, outside the emulated network, the sidecar applies the whole delay of a profile to the packets that the servers send, instead of dividing it between both sides as for the benchmark.
The waterfalls make the round trips visible: the 64 requests leave together, and their responses arrive in successive bands separated by one round trip as the congestion window grows. In the runs performed here, the HTTP/3 origin was slower than the HTTP/2 origin in every profile. A single run, however, reflects a single draw of the emulated losses and varies widely from one run to the next. Two limits of the measurement deserve mention. Firefox reports a fixed allowance of 300 bytes for the header fields of every response. With Docker, the browser opens its TCP connections to a local port proxy placed before the emulated network, whereas its QUIC packets cross that network, so a new HTTP/2 connection appears about one round trip faster than it is.
Defects of quarkus-http3 4.0.1 and their workarounds
The development of this project revealed three defects of the extension in its version 4.0.1, and the section that follows describes two limitations of the Vert.x HTTP/3 client on which the extension relies. Each defect was reproduced on a minimal application containing only quarkus-rest, quarkus-http3 and a single resource.
HTTP/2 responses lose their header fields
With the extension enabled, HTTP/2 responses reached the client with a header block containing the status alone, and the static page never completed. The cause lies in the handler that the extension registers to advertise HTTP/3. For HTTP/2 requests, this handler calls writeAltSvc(), which in Vert.x 5.2.3 writes an ALTSVC frame through writeCustomFrame(), and that method sends the response head before writing the frame. Since the handler runs before the application, the head leaves the server with the default status and with an empty set of header fields, and every header field that the application sets afterward is lost. The defect is tracked as quarkusio/quarkus#58786.
The workaround consists of three steps:
- the configuration disables the handler of the extension with
quarkus.http3.alt-svc=false; - the application advertises HTTP/3 with the
Alt-Svcheader field instead of theALTSVCframe, which exists for HTTP/2 only; - the filter presented earlier adds that header field through
addHeadersEndHandler, so that nothing is sent before the application has finished.
A dedicated test sends an HTTP/2 request with the REST client and verifies that the full header set arrives, and this test fails as soon as the handler of the extension is enabled again.
Disabling HTTP/3 prevents the application from starting
Setting quarkus.http3.enabled=false causes the packaged application to fail at startup in production mode, with the message “HTTP/3 requires TLS but no HTTPS server was configured”, even when TLS is configured. The build step that verifies TLS runs although the extension is disabled, and it inspects a flag that only the disabled component sets. The only effective way to run without HTTP/3 is therefore to remove the dependency, for instance in a dedicated Maven profile. This project keeps HTTP/3 enabled and is not affected.
The request header limit applies to TCP only
The property quarkus.http.limits.max-header-size limits the size of request headers on HTTP/1.1 connections, where an oversized request receives the status 431. Over HTTP/3, the same request was accepted with the status 200, because Vert.x leaves the HTTP/3 setting MAX_FIELD_SECTION_SIZE unlimited and Quarkus does not map its property onto it. The project applies the limit itself through an HttpServerConfigCustomizer, the extension point that Quarkus offers to adjust the Vert.x server configuration:
@Override
public void customizeHttpsServer(HttpServerConfig server,
ServerSSLOptions sslOptions) {
server.getQuicConfig().setClientAddressValidation(
config.quic().addressValidation());
Http3ServerConfig http3 = Objects.requireNonNullElseGet(
server.getHttp3Config(), Http3ServerConfig::new);
Http3Settings settings = Objects.requireNonNullElseGet(
http3.getInitialSettings(), Http3Settings::new);
server.setHttp3Config(http3.setInitialSettings(
settings.setMaxFieldSectionSize(maxHeaderSize.asLongValue())));
}
With this customizer, the server refuses oversized requests over HTTP/3, but it does so by closing the whole QUIC connection, which also aborts every other request multiplexed on that connection, whereas HTTP/1.1 answers with the status 431. When the server closes the connection in this way, the Vert.x HTTP/3 client leaves the pending request incomplete indefinitely, and the REST client built on it disregards its read timeout, while curl reports the closure within a few milliseconds. The test of this behavior therefore uses the Vert.x client directly with a bounded wait.
The customizer also sets the QUIC address validation mode, whose effect on latency the benchmark examines in detail.
Limitations of the Vert.x HTTP/3 client
The HTTP client of Vert.x 5.2.3, on which the Quarkus REST client relies, shows two further limitations over HTTP/3. Both belong to Vert.x rather than to the extension, and reports to the Vert.x project describe them.
Request timeouts
The REST client passes its property read-timeout to the Vert.x option RequestOptions.setTimeout. This option bounds two waits: the establishment of the connection and the wait for data from the server once the request is sent. A Vert.x program independent of Quarkus has set the wait for data to 2 seconds and then measured the server behavior against three scenarios: a complete response, no response at all, and a response whose headers and first body bytes arrive before the server stops sending. The program waited at most 10 seconds for each request.
| Server behaviour | HTTP/1.1 | HTTP/2 | HTTP/3 |
|---|---|---|---|
| Complete response | 277 ms | 62 ms | 77 ms |
| No response | Timeout after 2 s | Timeout after 2 s | Pending after 10 s |
| Body interrupted | Pending after 10 s | Pending after 10 s | Pending after 10 s |
The table reveals two distinct behaviors. Over HTTP/3, the expiry of the timeout never ends a request. When the timeout expires, the client sends a STOP_SENDING frame, which asks the server to stop sending on that stream. But the client neither closes its own stream nor fails the request. Therefore, it waits for a reaction that a stalled or departed server never sends. A request pending on a QUIC connection that the server closes remains incomplete in the same way. Over every protocol, the client cancels the timeout as soon as the response headers arrive, so that a body interrupted after the headers remains unbounded, whereas the documentation of the option states that the timeout also applies to the response body.
The cancellation of the timeout at the arrival of the headers becomes critical in combination with a defect of quiche, which the subsection “HTTP/3 requests that never complete”, later in this article, describes in detail: when the packet that carries the end of a stream is lost, quiche never retransmits it. The client then receives the complete body, but the end of the stream never arrives. An HTTP/3 request of the REST client that meets this defect therefore waits indefinitely, whatever its read timeout. In order to work around, the tests and tile-map consequently bound their HTTP/3 calls themselves, as follows:
- the metadata request of
tile-mapwith a Mutiny time limit; - the page test of
tile-servicewith a limit on the whole page; - the test of the request header limit with a bounded wait on the Vert.x client.
The receive buffer of QUIC sockets
A QUIC endpoint receives all its connections through one UDP socket. When datagrams arrive faster than the application reads them and the receive buffer of the socket is full, the kernel discards each further datagram before QUIC sees it and increments its counter UdpRcvbufErrors, which the command nstat displays. On Linux, a socket that requests no particular size receives the buffer defined by the kernel parameter net.core.rmem_default, 208 kilobytes by default.
QUIC recovers a discarded datagram like any lost packet, at the cost of a probe timeout and of a reduced congestion window, except when the datagram carries the end of a stream, which the quiche defect never retransmits. The page test of tile-service met this case on the loopback interface, as the section “Testing over three protocols” below details: 64 requests in flight produce about 430 kilobytes of responses at once, and the kernel discarded up to 130 datagrams in a single run.
Vert.x 5.2.3 sizes the buffers of TCP sockets through TcpConfig.setReceiveBufferSize, whereas its QUIC configuration offers no equivalent setting, and the QUIC socket keeps the system default. An application can therefore enlarge this buffer only for the whole host, through net.core.rmem_default, a remedy whose effect this project has not measured. The QUIC implementation quic-go, for comparison, requests a receive buffer of 7 megabytes and warns at startup when the system grants less.
Testing over three protocols
The tests follow an integration first approach. The service tests start the complete application with @QuarkusTest, which also starts the HTTPS listener and the QUIC listener with an automatically generated certificate. REST Assured verifies the functional contract, the Problem Details responses and the Alt-Svc header over HTTP/1.1, since REST Assured speaks HTTP/1.1 only. The Quarkus REST client, configured once with http2=true and once with http3=true, verifies that the server observes the expected protocol through the X-Protocol header field, that the 64 tiles of a page arrive over a single HTTP/3 connection with 16 requests in flight, and that the header set of the meta operation survives QPACK compression intact.
With 64 requests in flight, the responses reach the client in a burst of about 430 kilobytes, which exceeds the default receive buffer of 208 kilobytes, of a Linux UDP socket. The kernel discards between 2 and 130 datagrams in each run as its counter UdpRcvbufErrors shows, even on the loopback interface. QUIC retransmits most of them, but a discarded end of stream triggers the defect described in the subsection “HTTP/3 requests that never complete”, and the test then waits indefinitely, since the read timeout of the REST client never ends an HTTP/3 request. With 16 requests in flight, ten consecutive runs discarded no datagram. The subsection “The receive buffer of QUIC sockets”, in the section “Limitations of the Vert.x HTTP/3 client” above, explains why the application cannot enlarge the receive buffer itself. The test additionally bounds the whole page to 30 seconds, so that a lost end of stream produces a failure instead of a blocked build.
The client tests start the container image of the service with Testcontainers. Testcontainers publishes TCP ports only, so the test binds the UDP port explicitly, on the same host port as the TCP port, because the HTTP/3 client connects to the port of the configured URL:
.withCreateContainerCmdModifier(cmd -> {
Ports bindings = cmd.getHostConfig().getPortBindings();
bindings.bind(ExposedPort.tcp(8443),
Ports.Binding.bindPort(quicPort));
bindings.bind(ExposedPort.udp(8443),
Ports.Binding.bindPort(quicPort));
})
The container also publishes its TCP port alone on a second host port, with no UDP binding. A dedicated HTTP/3 client, TileH3DownClient, targets this second port with a read timeout of 5000 ms. The test verifies that this client never falls back to the open TCP port: its request fails after about five seconds with the message “The timeout of 5000 ms has been exceeded when getting a connection”.
Deployment
The container image exposes the port 8443 for both TCP and UDP, and Docker Compose publishes both:
ports:
- "8443:8443/tcp"
- "8443:8443/udp"
On Kubernetes, the extension quarkus-minikube generates the Deployment and the Service from the configuration of the application, and the build deploys them on Minikube. Serving HTTP/3 from a cluster requires adjustments to the generated manifest, concerning the keystore, the ports of the Service and the port that Alt-Svc announces, each of which this project has verified on Minikube 1.38 with Kubernetes 1.35.
The keystore reaches the pod through a Secret, which holds the PKCS#12 file and its password:
kubectl create secret generic tile-tls \
--from-file=tile-service.p12=benchmark/certs/tile-service.p12 \
--from-literal=password=changeit
The configuration mounts this Secret at /certs, where the production profile expects the keystore, and maps the password onto the variable TLS_KEYSTORE_PASSWORD:
quarkus.kubernetes.secret-volumes.certs.secret-name=tile-tls
quarkus.kubernetes.secret-volumes.certs.default-mode=0440
quarkus.kubernetes.security-context.fs-group=185
quarkus.kubernetes.mounts.certs.path=/certs
quarkus.kubernetes.mounts.certs.read-only=true
quarkus.kubernetes.env.mapping.tls-keystore-password.from-secret=tile-tls
quarkus.kubernetes.env.mapping.tls-keystore-password.with-key=password
Quarkus mounts Secret volumes with the mode 0600 by default, which reserves the file to the user root, whereas the Quarkus container image runs the application as the user 185. The mode 0440, combined with the group 185 that the property fs-group assigns to the volume, grants the application read access and keeps the keystore unreadable for other users of the container.
The Service must expose the port 8443 over both transport protocols. Kubernetes accepts a Service in which the same port number appears once for TCP and once for UDP, but the manifest generator of Quarkus 4.0.1 retains a single port for each container port number, so that the properties quarkus.kubernetes.ports.* cannot declare both. The project therefore supplies the ports of the Service in the file src/main/kubernetes/minikube.yml, which Quarkus merges into the generated manifest:
apiVersion: v1
kind: Service
metadata:
name: tile-service
spec:
ports:
- name: http
port: 80
targetPort: 8080
protocol: TCP
- name: https
port: 8443
targetPort: 8443
nodePort: 30443
protocol: TCP
- name: quic
port: 8443
targetPort: 8443
nodePort: 30443
protocol: UDP
The Service of type NodePort publishes HTTP/1.1 and HTTP/2 on the port 30443 of the node over TCP, and HTTP/3 on the same port over UDP. Keeping one port number for the three protocols matters, because the REST client configured for HTTP/3 connects to the UDP port of its URL, and because a browser reaches HTTP/3 through the port that the Alt-Svc header announces.
The port returned by the Alt-Svc header requires an adjustment as well. The filter of the application advertises by default the local port of the connection, which inside the pod is 8443, while clients reach the service on the port 30443 of the node. The property tiles.alt-svc.port, defined in the configuration interface ProtocolConfig of the module tile-server-support, replaces the local port with the published one in the Alt-Svc header field. The following line of the configuration sets it:
quarkus.kubernetes.env.vars.tiles-alt-svc-port=30443
The extension turns this line into the environment variable TILES_ALT_SVC_PORT of the container, which Quarkus maps to the property tiles.alt-svc.port. Without this property, a client following the Alt-Svc header advertisement would send its QUIC packets to the port 8443 of the node, where no service listens.
The build produces the container image directly in the Docker daemon of Minikube and applies the manifest:
eval $(minikube docker-env)
mvn install -DskipTests -pl tile-service -am \
-Dquarkus.container-image.build=true \
-Dquarkus.kubernetes.deploy=true
The requests below from the host verify the deployment. An HTTP/2 request receives the advertisement with the published port, an HTTP/3 request reaches the service over UDP, and curl, given a file in which it records alternative services, sends its first request over HTTP/2 and its second request over HTTP/3:
$ curl -sk --http2 -D- -o /dev/null \
https://$(minikube ip):30443/tiles/3/2/1/meta
HTTP/2 200
x-protocol: HTTP/2
alt-svc: h3=":30443"; ma=3600
$ curl -sk --http3-only -D- -o /dev/null \
https://$(minikube ip):30443/tiles/3/2/1/meta
HTTP/3 200
x-protocol: HTTP/3
$ for i in 1 2; do curl -sk --alt-svc alt-svc.txt -o /dev/null \
-w '%{http_version}\n' https://$(minikube ip):30443/tiles/3/2/1.png; done
2
3
On a cluster in a cloud environment, a Service of type LoadBalancer replaces the NodePort, and the load balancer must then forward UDP as well as TCP on the same port, a capability that varies between providers.
Counting round trips
The number of round trips that precede the RTT is, together with header compression, a subject that we’re examining in detail here. This section first counts these round trips in theory for each protocol, then explains how the address validation of QUIC can add one more, and finally measures them on the demonstration application.
The theoretical budget
Before a client receives the first byte of a response, it exchanges a number of messages with the server, and each exchange costs one round trip time. Over TCP and TLS 1.3, the TCP handshake costs one round trip, the TLS handshake costs a second round trip, and the request and its response cost a third. QUIC combines the transport handshake and the TLS handshake, so a new HTTP/3 connection costs one round trip for the handshake and a second one for the request. With 0-RTT, a client that resumes a previous session sends its request in its first packet, and the response arrives after a single round trip.

Address validation and the Retry packet
A QUIC server may answer the first packet of a client with a Retry packet that carries a token. The client must then repeat its first packet with this token, which proves that it receives traffic at its source address. This mechanism protects the server against attackers who forge the source address of their packets, either to make the server send its larger handshake responses to a victim, an attack called amplification, or to exhaust the server with connection attempts. The protection costs one additional round trip for every new connection.
Vert.x configures QUIC servers with the address validation mode BASIC by default, which sends a Retry packet to every new client and uses tokens without cryptographic protection. The mode NONE disables the Retry packet, and the mode CRYPTO signs the tokens with a key that the application provides. Quarkus exposes none of these modes, and this project makes them configurable through the property tiles.quic.address-validation and the customizer shown earlier. qlog is the event log format that the QUIC working group of the IETF is standardizing, in which an endpoint records every packet that it sends or receives, together with the frames that the packet contains. The qlog traces recorded by h2load, the load generator presented with the benchmark, confirm the mechanism: with the mode BASIC, the client receives exactly one Retry packet per connection, and with the mode NONE it receives none.
Measuring the round trips
curl reports several timestamps for each request. For TCP, time_connect marks the completion of the TCP handshake and time_appconnect marks the completion of the TLS handshake. For HTTP/3, curl built with ngtcp2 records time_connect when the first packet of the server arrives and time_appconnect when the QUIC handshake completes. In both cases, time_starttransfer marks the arrival of the first byte of the response. Dividing these times by the round trip time configured in the network emulation expresses them in round trips.
The benchmark measures each combination of network profile, protocol and connection mode with 50 requests, each of which opens a new connection. Three connection modes are measured:
- a cold connection starts without any prior state;
- a resumed connection presents the TLS session ticket obtained by a previous connection;
- an early data connection presents the same ticket and additionally asks
curlto send its request as 0-RTT data.
curl stops any request after 20 seconds, and such a request counts as a failed sample, excluded from the medians.
On the emulated wide area network, with a round trip time of 50 milliseconds, cold connections give the following medians:
| Connection | Encryption established | First response byte |
|---|---|---|
| HTTP/1.1, TCP and TLS 1.3 | 108.1 ms (2.16 RTT) | 159.0 ms (3.18 RTT) |
| HTTP/2, TCP and TLS 1.3 | 108.1 ms (2.16 RTT) | 159.3 ms (3.19 RTT) |
HTTP/3, address validation BASIC |
106.6 ms (2.13 RTT) | 159.0 ms (3.18 RTT) |
HTTP/3, address validation NONE |
56.7 ms (1.13 RTT) | 109.0 ms (2.18 RTT) |
The measured time in the table above are slightly longer that they should. The first response byte of HTTP/2, for example, arrives after 159.3 milliseconds, while it should have come after 150 milliseconds for three round trips of 50 ms. The additional time of 9.3 milliseconds represent the time that the client and the server spend computing, such as the cryptographic operations of the handshake and the handling of the request, and not time spent on the network. With the default configuration of Quarkus, the Retry packet consumes the round trip that QUIC saves, and a new HTTP/3 connection costs exactly as many round trips as a new HTTP/2 connection. With the mode NONE, HTTP/3 reaches the budget that its design promises and delivers the first response byte one round trip earlier, 50 milliseconds on this network.
The time to the first response byte of cold connections across all profiles confirms this result:
| Connection | lan |
wan |
lossy |
degraded |
|---|---|---|---|---|
| HTTP/1.1 | 3.6 ms | 159.0 ms (3.18 RTT) | 168.7 ms (3.37 RTT) | 162.3 ms (3.25 RTT) |
| HTTP/2 | 3.2 ms | 159.3 ms (3.19 RTT) | 164.0 ms (3.28 RTT) | 162.1 ms (3.24 RTT) |
HTTP/3, BASIC |
3.9 ms | 159.0 ms (3.18 RTT) | 162.8 ms (3.26 RTT) | 161.3 ms (3.23 RTT) |
HTTP/3, NONE |
3.7 ms | 109.0 ms (2.18 RTT) | 108.8 ms (2.18 RTT) | 108.7 ms (2.17 RTT) |
The report of the benchmark draws these medians as a chart, in which each bar splits the time to the first response byte into three parts: the connection, up to time_connect, the TLS or QUIC handshake, up to time_appconnect, and the request, up to the first response byte. With BASIC, the first packet of the server is the Retry packet, so the connection part already lasts one round trip and the handshake needs a second one. With NONE, the first packets of the server already carry the handshake, which completes almost immediately after them.

On the local profile, where a round trip costs about 0.1 millisecond, the four configurations remain within one millisecond of each other, and the processing time dominates. On the three emulated networks, the medians stay at three round trips for TCP and for HTTP/3 with BASIC, and at two round trips for HTTP/3 with NONE, because most handshakes of a sample of 50 encounter no loss. Losses appear in the 95th percentile. With 5 percent loss, it reaches 1638 milliseconds for HTTP/1.1, 1358 milliseconds for HTTP/2 and 1414 milliseconds for HTTP/3 with BASIC, which is consistent with the initial retransmission timeout of one second. HTTP/3 with NONE reaches 351 milliseconds, and the present measurements leave the cause of this difference open. In addition, up to four HTTP/3 requests out of 50 exceeded the time limit in the groups measured with loss, 21 requests out of 600 in total, a consequence of the defect described in the subsection “HTTP/3 requests that never complete” of the benchmark results.
Resumed connections give the same medians as cold connections for every protocol, within one millisecond on the wide area network and within six milliseconds on the networks with loss. For TCP this result follows from TLS 1.3 itself, whose session resumption saves the certificate exchange and its verification but keeps the same number of round trips. The chart of resumed connections therefore reproduces the chart of cold connections:

Early data connections give the same medians as well, within the same margins. curl reports tls_earlydata equal to zero for every connection, consistent with the fact that Vert.x never enables early data on its QUIC server, whatever the configuration. The request therefore waits for the end of the handshake, as in a cold connection, and 0-RTT stays unused:

The benchmark
The benchmark compares HTTP/1.1, HTTP/2 and HTTP/3 on the demonstration application under network conditions that range from a local network to a distant network that loses packets. This section describes the containers that take part in the measurements, the way they emulate a wide area network, and the network profiles and scenarios measured, before it presents the results, including the requests that never complete and the effect of header compression.
Topology
The benchmark runs in Docker Compose. The service container receives a sidecar container that shares its network namespace, and a benchmark container hosts h2load and curl, both built from source with HTTP/3 support. curl 8.23.0 and h2load 1.71.0 implement QUIC with the ngtcp2 1.26.0 library and HTTP/3 with the nghttp3 1.19.0 library, and both rely on OpenSSL 3.6.5 for the TLS 1.3 handshake and the packet protection. Both sides of the connection pass through an emulated wide area network, which the next section describes.

Emulating the wide area network
The containers of Docker Compose communicate through a virtual bridge inside a single machine, where a round trip lasts less than a tenth of a millisecond and no packet is lost. The benchmark therefore degrades this path artificially with the traffic control facility of the Linux kernel. Every network interface of Linux owns a queueing discipline, abbreviated qdisc, which decides when each outgoing packet leaves the interface and whether it leaves at all. The command tc replaces this discipline, and the discipline netem, for network emulator, holds each outgoing packet for a configured delay and discards a configured proportion of the packets. A qdisc governs the outgoing packets of its interface only, so emulating both directions of a connection requires one discipline on each side.
The client side is the interface eth0 of the benchmark container, which carries the requests and the acknowledgements that h2load and curl send. The server side is the interface eth0 of tile-service, which carries the responses. Changing a qdisc requires the Linux capability NET_ADMIN, and the image of tile-service contains neither the tc command nor that capability. A sidecar container, built from the benchmark image, therefore joins the network namespace of tile-service through the Compose setting network_mode: "service:tile-service", and receives the capability NET_ADMIN. The sidecar sees the same interface as the service and shapes its outgoing packets, while the application container keeps its minimal image and runs without any additional privilege.
netem:
image: simplex-software/tile-bench:1.0.1
network_mode: "service:tile-service"
cap_add:
- NET_ADMIN
command: ["/benchmark/netem.sh", "--watch"]
The script benchmark/netem.sh defines the four profiles and applies them on each side with a single command:
tc qdisc replace dev eth0 root netem \
delay "${delay}ms" loss "${loss}%" limit 10000
| Profile | Round trip time | Delay on each side | Loss on each side | Expected loss on a round trip |
|---|---|---|---|---|
lan |
unchanged | 0 ms | 0 % | 0 % |
wan |
50 ms | 25 ms | 0 % | 0 % |
lossy |
50 ms | 25 ms | 1 % | 1.99 % |
degraded |
50 ms | 25 ms | 5 % | 9.75 % |
Each side adds half of the round trip time, so that a request and its response together accumulate the delay of the profile. Each side discards the full loss rate of the profile, so that each direction loses packets at that rate independently of the other. Therefore, a request and its response, carried by one packet each, both arrive with the probability (1 − p)², where p is the loss rate of the profile. An exchange fails with the probability given in the last column. The emulation operates below the transport layer, so it treats the TCP segments of HTTP/1.1 and HTTP/2 and the UDP datagrams of HTTP/3 identically, including the handshake packets, the acknowledgements and the Retry packets.
The parameter limit sets the number of packets that the discipline may hold at once. netem keeps every delayed packet in its queue, and its default limit of 1000 packets, held for 25 milliseconds, would overflow as soon as a sender exceeded 40000 packets per second. The overflow would discard packets beyond the configured rate, so the benchmark raises the limit to 10000 packets, and the configured loss rate remains the only source of loss.
The two sides change their profile together through a shared directory, benchmark/results/.netem, mounted in both containers. Before measuring a profile, the scripts run.sh and rtt.sh apply it to the client side, write its name into the file request of that directory, and wait for the file applied to contain the same name. The sidecar checks the file request every 200 milliseconds, applies the requested profile to the server side, and writes its name into the file applied. If the acknowledgement takes more than ten seconds, the script stops with an error, so that no measurement ever runs with a single shaped side. When a script ends, it restores the profile lan on both sides. tile-map uses the same exchange for the buttons of its comparison lab, with the variable NETEM_SIDES=1 that places the whole delay on the server side, because the browser runs on the host, outside the emulated network.
A measurement independent of the benchmark tools verifies the emulation. A container providing ping joined the network namespace of the benchmark container and sent 3000 echo requests of 1200 bytes to tile-service for each profile:
| Profile | Average round trip | Echo requests lost | Observed loss | Expected loss |
|---|---|---|---|---|
lan |
0.07 ms | 0 out of 3000 | 0 % | 0 % |
wan |
50.1 ms | 0 out of 3000 | 0 % | 0 % |
lossy |
50.1 ms | 65 out of 3000 | 2.2 % | 1.99 % |
degraded |
50.1 ms | 265 out of 3000 | 8.8 % | 9.75 % |
The observed losses lie within the statistical variation of a sample of 3000 exchanges, and the round trip exceeds the configured 50 milliseconds by about 0.1 millisecond, the time spent crossing the bridge. The QUIC stack of h2load reaches the same conclusion: the median of the smoothed round trip time, the estimate that QUIC maintains from its acknowledgements and that h2load reports for each HTTP/3 run, averages 51.5 milliseconds over the runs of the profile wan.
This emulation reproduces a long network path with random losses, whose characteristics define the scope of the results:
- constant delay: every packet waits exactly the configured delay, so packets arrive in the order in which they were sent;
- independent losses: each packet is lost independently of the others, at the configured rate;
- unlimited bandwidth: congestion control reacts to the emulated losses alone;
- symmetric directions: both directions have the same delay, the same loss rate and the same capacity.
The results of this benchmark therefore characterize the protocols on a distant path with random and independent losses. In a mobile or congested link, the delay may vary, the losses may come in bursts and the bandwidth may be limited and often lower upstream than downstream. Such case calls for a richer model, which netem supports, for example with its Gilbert-Elliott loss model, named loss gemodel, dedicated to losses in bursts.
The emulation can be inspected while it runs. The sidecar keeps the profile last applied, and the statistics of its discipline count the packets that it has sent and discarded:
docker compose up -d --wait tile-service netem
docker compose exec netem tc -s qdisc show dev eth0
Profiles and scenarios
The following network profiles are measured:
lanadds no delay and no loss;wanadds a round trip time of 50 milliseconds;lossyadds the same delay and a loss rate of 1 percent;degradedadds the same delay and a loss rate of 5 percent.
The following scenarios are measured with h2load:
- the page load scenario fetches the 64 tiles of one view, with six connections for HTTP/1.1, as a browser would open, and with one connection carrying 64 concurrent streams for HTTP/2 and HTTP/3;
- the throughput scenario sends 10000 requests from 32 clients;
- the header scenario requests the
metaoperation 1000 times, sequentially and then with 64 concurrent streams, in four variants: HTTP/1.1 as the uncompressed baseline, HTTP/2 with the default HPACK dynamic table, HTTP/2 with a dynamic table of size zero, and HTTP/3.
Before each profile, every protocol receives 2000 warm up requests, so that the measurements reflect a server whose code the Java virtual machine has already compiled.
Results
The page load scenario runs ten times for each profile and protocol. The following table gives the median duration of one page load over the runs in which every request succeeded, and states how many of the ten runs contained a failed request. The address validation mode NONE was measured for HTTP/3 only, since it concerns QUIC alone.
| Profile | HTTP/1.1 | HTTP/2 | HTTP/3, BASIC |
HTTP/3, NONE |
|---|---|---|---|---|
wan |
717.6 ms | 408.9 ms | 418.0 ms | 371.9 ms |
lossy |
1022.5 ms | 486.8 ms | 826.7 ms, 2 runs failed | 803.6 ms |
degraded |
2081.8 ms | 1255.8 ms | 3490.5 ms, 3 runs failed | 3587.4 ms, 1 run failed |
On the wide area network, HTTP/1.1 needs about 718 milliseconds, because its six connections each transmit about eleven requests one after the other, and each request costs one round trip. HTTP/2 and HTTP/3 multiplex the 64 requests on a single connection and shorten this duration by about 40 percent. HTTP/3 with BASIC and HTTP/2 differ by 9 milliseconds, while HTTP/3 with NONE saves 46 milliseconds, close to the round trip of the Retry packet that this mode removes.
With packet loss, HTTP/3 performs worse than HTTP/2, even in the runs without failed requests, although QUIC removes the head of line blocking that penalizes HTTP/2 over TCP. Two properties of the implementation can contribute to this result. HTTP/3 transmits the header block of a response in a HEADERS frame and its body in DATA frames, both on the stream of the request. The traces show that the server sends each response in three separate packets, one carrying the HEADERS frame, one carrying the DATA frame and one carrying the end of the stream. Accordingly, each response is exposed to three potential losses where TCP coalesces the same bytes into fewer segments. The loss recovery and the congestion control of quiche also differ from those of the Linux TCP stack. The present measurements leave the respective weight of these two contributions open. Every failed run, in turn, has a single cause, presented in the subsection “HTTP/3 requests that never complete” below.
On the local profile, the page load times depend on the state of the Java virtual machine more than on the protocol. In the full benchmark run, which warms up and measures HTTP/1.1, HTTP/2 and HTTP/3 in turn, the medians are 36.2 milliseconds for HTTP/1.1, 33.2 for HTTP/2 and 36.9 for HTTP/3 with BASIC. In a run that warms up and measures HTTP/3 alone, the median falls to 12.0 milliseconds with NONE and to 12.6 milliseconds with BASIC. The two address validation modes thus give the same result, as expected when a round trip costs 0.1 millisecond, and the local profile serves only to verify that the service itself adds no significant latency.
The throughput scenario sends 10000 requests from 32 clients, with ten concurrent streams per client for HTTP/2 and HTTP/3, three times for each profile and protocol. The table gives the median rate over the runs without failed requests.
| Profile | HTTP/1.1 | HTTP/2 | HTTP/3, BASIC |
|---|---|---|---|
lan |
5068 req/s | 8318 req/s | 10381 req/s, 1 run out of 3 without failure |
wan |
618 req/s | 5454 req/s | 5304 req/s |
lossy |
435 req/s | 1527 req/s | every run failed |
degraded |
234 req/s | 600 req/s | every run failed |
On the wide area network, HTTP/2 and HTTP/3 deliver about nine times the rate of HTTP/1.1, because each client keeps ten requests in flight instead of one. Every HTTP/3 run with loss lost requests, between 72 and 102 out of 10000 with 1 percent loss and between 9 and 33 with 5 percent loss. Two of the three runs on the local profile lost 3 and 9 requests. HTTP/1.1 and HTTP/2 completed every request of every run.
HTTP/3 requests that never complete
The qlog traces recorded by h2load and curl show the same sequence for every request that failed. The client receives the complete response body, and the packet that follows the body is lost. When a sender receives no acknowledgement within a delay that QUIC derives from the measured round trip time, called the probe timeout, it sends a probe packet to provoke one. The server then sends only probes containing a PING frame, which requests an acknowledgement and carries no data, and the stream never ends, so that the request remains pending until the client gives up.

The cause lies in quiche, at the revision be47c50 that Netty 4.2.20 4.2.21 still bundle. QUIC carries the bytes of each stream in STREAM frames, each of which states the offset of its bytes in the stream. Vert.x ends each response with a separate STREAM frame that carries no data and only the FIN flag, which marks the end of the stream. The defect unfolds in three steps.
- The method
SendBuf::is_complete()ofquicheconsiders the sending side of a stream complete when the peer has acknowledged every byte from offset zero to the final offset. A STREAM frame of length zero covers no byte, so the acknowledgement of the DATA frame alone satisfies this condition. - When this acknowledgement arrives,
quichefinds the stream complete in both directions and releases it. - When
quichelater declares the packet carrying the FIN lost, it finds no stream for the lost frame and discards the frame instead of retransmitting it.
Lost packets that carry data are retransmitted correctly, because their acknowledgement is still missing when the loss is detected. The defect therefore affects only the end of stream, and only when its packet is lost after the data packets have been acknowledged. A single connection that carries many requests, such as the sequential header scenario or a throughput client, eventually meets this case, and the connection then stops making progress for that stream. The local profile loses no packet by emulation, and the two failed throughput runs there are consistent with the datagrams that the kernel discards when the QUICK socket receive buffer is full.
The quiche project corrected the defect in the commits af8788e, which tracks the acknowledgement of the FIN separately, and 1128f94, which keeps a pending FIN schedulable after the data has been acknowledged. Both commits are more recent than the revision that Netty bundles, and a report to the Netty project requests the update of the bundled revision. Until Netty updates quiche and Vert.x and Quarkus adopt that release, HTTP/3 in Quarkus 4.0.1 should be considered unreliable on networks that lose packets, a condition common on wireless and mobile networks.
Header compression results
The header scenario gives the following medians over three runs. Header compression depends on the sequence of header fields and not on the network, and every variant transmits the same number of header bytes on the four profiles and in both the sequential and the concurrent form, with one exception discussed below.
| Variant | Response header bytes | Savings |
|---|---|---|
| HTTP/1.1 | 789000 | 0 % |
| HTTP/2, HPACK dynamic table | 16697 | 97.9 % |
| HTTP/2, HPACK static table only | 721001 | 9.5 % |
| HTTP/3, QPACK static table only | 471000 | 38.9 % |
HPACK with its dynamic table reduces the repeated header set of the meta operation to a few bytes per response, because every field becomes a one byte index after its first occurrence. When the client limits the HPACK dynamic table to zero, the savings fall to about 10 percent, which comes from the static table alone, since Netty applies Huffman coding only to long strings. QPACK as configured by Vert.x saves about 39 percent: the static table contributes the same kind of reduction as for HPACK, and the systematic Huffman coding of the literal values contributes the rest. The comparison shows that the gap between HTTP/2 and HTTP/3 in this measurement reflects an implementation choice of Vert.x rather than a property of QPACK, since RFC 9204 provides a dynamic table equivalent to that of HPACK, and an encoder using it can be expected to reach comparable savings on such repetitive header sets.
The exception concerns the sequential form of HTTP/3 on the profiles with loss. In this form, the scenario sends its 1000 requests one after the other on a single connection, and each response carries 471 bytes of header fields, so a complete run transmits 471000 bytes. With 1 percent loss, the median run transmitted only 9420 bytes, that is the header fields of about 20 responses. With 5 percent loss only 4239 bytes, that is about 9 responses. In both cases, the run stopped at the first response whose end of stream was lost, as described in the subsection “HTTP/3 requests that never complete”, and the connection carried no further request. The responses received before that point keep the compression ratio of 38.9 percent.
Running the project
This section gathers the commands that build, test and run every part of the project, from the unit tests to the complete benchmark. All commands run from the root directory of the project.
Prerequisites
The project requires Java 25, Maven 3.9 and Docker with Docker Compose. The integration tests start containers through Testcontainers, so the Docker daemon must be running before the build. The browser tests of tile-map drive Firefox through Playwright, which downloads its browsers into ~/.cache/ms-playwright on its first run. On Linux, Firefox additionally needs system libraries, which a single command installs:
sudo npx playwright@1.65.1 install-deps firefox
A browser and curl complete the list for the manual steps. The curl of most Linux distributions supports HTTP/1.1 and HTTP/2 only, and the benchmark image of the project provides a curl built with HTTP/3 support. pandoc displays the summary of the benchmark in the terminal.
Building and testing
A single Maven command compiles the six modules, builds the container images simplex-software/tile-service:1.0.1 and simplex-software/tile-map:1.0.1, and runs every test:
mvn install -Dquarkus.container-image.build=true
Maven builds the modules in dependency order, so the image of tile-service exists before the tests of tile-client and tile-map start it as a container. The tests are organized by module as follows.
| Module | Test classes | Verified behaviour |
|---|---|---|
tile-service |
TileResourceTest |
Functional contract over HTTP/1.1, Alt-Svc header, Problem Details responses |
tile-service |
TileHttp2Test, TileHttp3Test |
Protocol observed by the server, 64 tiles over a single QUIC connection, header set intact after QPACK |
tile-service |
RestrictedServiceTest, Http3ServerCustomizerTest, DeploymentOverridesTest |
Request header limit on both transports, address validation mode, advertised port and Timing-Allow-Origin |
tile-client |
TileClientTest, TileClientMainTest |
Each client speaks its protocol against the container, the HTTP/3 client never falls back to TCP, invalid arguments |
tile-map |
ViewportTest, MapPageTest, LabPageTest |
Navigation arithmetic, rendering of the page and of its fragments, error responses |
tile-map |
MapHttp3Test, MapMetaTest, UnreachableServiceTest |
Page served over HTTP/3, metadata fetched from the container over HTTP/3, time limit with an unreachable service |
tile-map |
LabNetworkTest, LabEnabledTest |
Exchange of network profiles with the sidecar, including the time limit when the sidecar never answers |
tile-map |
MapBrowserTest, LabBrowserTest |
Firefox discovers HTTP/3 through Alt-Svc, and each panel of the lab loads its tiles over its own protocol |
Once the images exist, the tests of one module, or a single test class, run without rebuilding the others:
mvn test -pl tile-service
mvn test -pl tile-map -Dtest=MapBrowserTest
The continuous integration pipeline in .circleci/config.yml runs the same steps on a virtual machine that provides a Docker daemon: it builds the images without tests, installs the Firefox libraries, runs mvn verify, and checks that the report generator of the benchmark compiles and runs.
Running the service and the client
In development mode, Quarkus generates a self-signed certificate and serves the service on the port 8443:
mvn -pl tile-service quarkus:dev
The packaged image runs with the certificate of the project, which a script generates once. Its subject alternative names cover localhost, 127.0.0.1 and the service name tile-service:
./benchmark/certs.sh
docker compose up -d --wait tile-service
Two requests from the benchmark image show the same resource over HTTP/2 and over HTTP/3. The x-protocol header field of each response reports the protocol that the server observed, and the HTTP/2 response carries the Alt-Svc advertisement:
docker compose run --rm bench curl -sk --http2 -D - -o /dev/null \
https://tile-service:8443/tiles/3/2/1.png
docker compose run --rm bench curl -sk --http3-only -D - -o /dev/null \
https://tile-service:8443/tiles/3/2/1.png
The command line client fetches the 64 tiles of one view with the protocol given as its argument, h1, h2 or h3, and an optional origin given as three further arguments z x y:
$ java -Dtiles.url=https://localhost:8443 \
-jar tile-client/target/quarkus-app/quarkus-run.jar h3
protocol requested : h3
protocol observed : HTTP/3
tiles fetched : 64
first request : 432 ms (connection setup included)
median of others : 119 ms
total wall time : 580 ms
total bytes : 432863
The first request includes the opening of the connection and the startup of the client, and the 63 following requests share the connection that it opened.
Running the map and the comparison lab
The Compose profile lab starts tile-map on the port 8090, tile-service on the port 8443, the HTTP/2 only instance tile-service-h2 on the port 9443 and the netem sidecar. Two variables adapt tile-service and the sidecar to a browser running on the host: TIMING_ALLOW_ORIGIN names the origin of tile-map, so that its page may read the protocol of each tile, and NETEM_SIDES=1 applies the whole delay of a network profile to the packets that the servers send.
TIMING_ALLOW_ORIGIN=https://localhost:8090 NETEM_SIDES=1 \
docker compose --profile lab up -d --wait
The browser then requires three steps, because the certificate of the project is self-signed:
- Open
https://localhost:8443/tiles/0/0/0.png, thenhttps://localhost:9443/tiles/0/0/0.png, thenhttps://localhost:8090, and accept the certificate on each origin. A browser presents no certificate prompt for an image of another origin, so each origin needs a visit of its own. - In Firefox, open
about:configand setnetwork.http.http3.disable_when_third_party_roots_foundtofalse. Chromium instead needs the flags--origin-to-force-quic-on=localhost:8090,localhost:8443and--ignore-certificate-errors-spki-list, whose value theREADME.mdfile of the project explains how to compute. - Reload the map. The first load travels over HTTP/2 and delivers the
Alt-Svcadvertisements, and the second load travels over HTTP/3, which the green outline of each tile confirms.
A click on a tile shows its metadata, fetched by tile-map from tile-service over HTTP/3. The link at the top of the map opens the lab at https://localhost:8090/lab, where the button Run again fetches both panels and the buttons lan, wan, lossy and degraded change the emulated network. The following command stops every container of the lab:
docker compose --profile lab down
On Minikube, the Secret and the build of tile-service presented in the section “Deployment” come first. Each application then receives the address of the node, because each one refers to the other through it:
eval $(minikube docker-env)
node=$(minikube ip)
env=quarkus.kubernetes.env.vars
mvn install -DskipTests -pl tile-service -am \
-Dquarkus.container-image.build=true \
-Dquarkus.kubernetes.deploy=true \
-D$env.tiles-timing-allow-origin=https://$node:30090
mvn install -DskipTests -pl tile-map \
-Dquarkus.container-image.build=true \
-Dquarkus.kubernetes.deploy=true \
-D$env.tiles-map-service-url=https://$node:30443
The map is then available at https://<node address>:30090, over TCP and UDP on the same port. The lab page explains on Minikube that its comparison requires the Compose profile, which provides the second origin and the sidecar.
Running the benchmark
The benchmark consists of two measurement scripts and one report program. The script run.sh runs the h2load scenarios and rtt.sh measures the round trips of individual requests with curl. Both run inside the benchmark image and append one CSV row per measurement to a file, without displaying any result. The program Report.java then reads these CSV files and writes the readable summary beside them, and the script charts.sh converts the charts of the summary into PNG images. The script all.sh chains the two measurement scripts, the report program and the conversion.
Running the complete benchmark
The script benchmark/all.sh generates the certificate when it is missing, starts the service and the sidecar with the address validation mode BASIC, runs run.sh and rtt.sh, repeats the HTTP/3 measurements with the mode NONE, stops the containers, and runs the report. A complete run takes about two hours:
./benchmark/all.sh
Where the results are written
Without further setting, every output lands in the directory benchmark/results, the directory whose files this article presents:
| File | Written by | Content |
|---|---|---|
results.csv |
run.sh |
One row per h2load run: duration, request rate, latencies, header bytes, losses |
raw/ |
run.sh |
The JSON output and the log of every h2load run |
rtt-raw.csv |
rtt.sh |
One row per curl request: the timings of the connection, of TLS and of the first byte |
summary.md |
Report.java |
The tables of this article, computed from both CSV files |
rtt.csv |
Report.java |
The medians of rtt-raw.csv per group |
rtt.svg, rtt-resumed.svg, rtt-earlydata.svg |
Report.java |
The charts of the round trips |
rtt.png, rtt-resumed.png, rtt-earlydata.png |
charts.sh |
The same charts as images, for publishing platforms that accept no SVG |
The file to open after a run is therefore summary.md. It is a Markdown file, and pandoc displays its tables as aligned columns in the terminal, as the commands of the sections on short runs and on single scripts show, where --columns=200 keeps the widest table on one line. The report runs again on existing measurements without repeating them:
java benchmark/Report.java benchmark/results
The script charts.sh converts the SVG charts into PNG images through rsvg-convert, run in a temporary Alpine container, so that no local installation is required. It runs again after each report, on the directory that the report has written:
benchmark/charts.sh benchmark/results
The measurement files
The two CSV files are the only source of the published figures. The scripts append to them and never rewrite them, and every other file of the directory derives from them, so that deleting summary.md, rtt.csv or the charts loses nothing that the report cannot recompute. Both files carry a header line, and a new file receives one before its first row.
The file results.csv contains one row per h2load run. Its times are in milliseconds:
| Column | Meaning |
|---|---|
scenario |
page-load, throughput, headers-sequential or headers-concurrent |
profile |
The network profile: lan, wan, lossy or degraded |
validation |
The QUIC address validation mode of the service, BASIC or NONE |
protocol |
h1, h2 or h3 |
variant |
default, or table0 for HTTP/2 with an HPACK dynamic table of size zero |
iteration |
The rank of the run within its group |
duration_ms, req_s |
The duration of the run and its request rate |
request_median_ms, request_p95_ms |
The median and the 95th percentile of the request times |
connect_median_ms, connect_p95_ms |
The same statistics for the connection establishment |
ttfb_median_ms, ttfb_p95_ms |
The same statistics for the first response byte |
header_bytes, header_savings_pct |
The header bytes on the wire and the savings relative to their decompressed size |
packets_lost, smoothed_rtt_ms |
The QUIC statistics of h2load, present for HTTP/3 only |
failed |
The number of requests that failed, raised an error or exceeded the h2load time limit |
The file rtt-raw.csv contains one row per curl request for the tile /tiles/3/2/1.png. Its times are in seconds, measured by curl from the start of the request:
| Column | Meaning |
|---|---|
profile, validation, protocol |
As in results.csv |
mode |
cold for a new TLS session, resumed for a session resumed from a saved ticket, earlydata for a resumed session that also requests 0-RTT |
sample |
The rank of the request within its group |
time_connect |
The end of the transport connection |
time_appconnect |
The end of the TLS handshake, which QUIC performs together with its own handshake |
time_pretransfer, time_starttransfer, time_total |
The sending of the request, the first response byte and the last response byte |
http_version |
The protocol that curl actually used |
tls_earlydata |
The number of bytes that curl sent as early data |
exit_code |
The exit code of curl, where any value other than zero marks a failed request, mostly the expiry of its time limit |
How the report computes the summary
Report.java is a single file Java program, which the Java launcher compiles and runs in one step, without Maven. It takes the directory that holds the two CSV files as its only argument, benchmark/results by default, reads both files, and writes summary.md, rtt.csv and the charts into that same directory, replacing the previous versions. A missing CSV file produces empty tables.
The report forms groups and reduces each group to a few statistics:
- A row of HTTP/3 becomes
h3-basicorh3-noneaccording to its validation mode, which separates the two configurations of QUIC in every table. The report ignores the rows of HTTP/1.1 and HTTP/2 measured with the modeNONE, since this mode concerns QUIC only. - The round trip table groups the rows of
rtt-raw.csvby profile, protocol and mode. It counts the requests whose exit code differs from zero as failed and excludes them, then computes the median and the 95th percentile of each curl time. It also divides each time by the round trip time of the profile, 50 milliseconds forwan,lossyanddegraded, which expresses it as a number of round trips. The filertt.csvcontains these statistics, and the charts show the medians of the connection, of the handshake and of the first byte as stacked bars, one chart for each mode. - The page load and throughput tables group the rows of
results.csvby scenario, profile, protocol and variant. They count the runs that contain at least one failed request, and they compute the median and the 95th percentile over the other runs only, because a single request that waits until the h2load time limit would otherwise dominate the result. - The header compression table keeps every run, since its byte counts are meaningful even when a request fails, and reports the median of the header bytes and of the savings.
Two consequences follow for the use of the report. Every row present in a CSV file enters its group, so that a second run with the same settings adds iterations to the first one instead of replacing it. Moreover, the round trip times of the profiles are written in the program itself, in the constant PROFILE_RTT_MS, which must follow any change of the delays in netem.sh.
Short runs that keep the published results intact
Because both scripts append to their CSV files, a short run made in benchmark/results mixes its rows with the published measurements. The variable RESULTS_DIR of all.sh names a subdirectory of benchmark/results that receives both CSV files and the report instead. The subdirectory debug stays outside version control. Environment variables also reduce the scope of a run:
PROFILESselects the network profiles;PROTOCOLSthe protocols amongh1,h2andh3;SCENARIOStheh2loadscenarios amongpage-load,throughputandheaders;ITERATIONSandREPEATSthe number of runs of the page load scenario and of the other scenarios;SAMPLESthe number ofcurlrequests per group.
The following command measures the page load and the round trips over HTTP/2 and HTTP/3 on the wide area network in less than two minutes, then displays the summary:
RESULTS_DIR=debug PROFILES=wan PROTOCOLS="h2 h3" SCENARIOS=page-load \
ITERATIONS=2 REPEATS=1 SAMPLES=5 ./benchmark/all.sh
pandoc -f gfm -t plain --columns=200 benchmark/results/debug/summary.md
The JSON files of h2load always go to benchmark/results/raw, which version control ignores, and a later run with the same scenario, profile, protocol and iteration replaces them.
Running a single script
The scripts run.sh and rtt.sh also run on their own, against a service started as shown earlier. The variable RESULTS_CSV designates the output file of run.sh and RTT_OUT that of rtt.sh, both as paths inside the container, where benchmark is mounted at /benchmark. Without them, the scripts append to the published files. The directory must exist before the run, because a directory that the container creates belongs to the user root, and the report then cannot write into it. The report runs on the directory that holds the two files:
mkdir -p benchmark/results/debug
docker compose up -d --wait tile-service netem
docker compose run --rm -e PROFILES=wan -e PROTOCOLS="h2 h3" \
-e SCENARIOS=page-load -e ITERATIONS=2 \
-e RESULTS_CSV=/benchmark/results/debug/results.csv bench ./run.sh
docker compose run --rm -e PROFILES=wan -e PROTOCOLS="h2 h3" \
-e SAMPLES=5 -e RTT_OUT=/benchmark/results/debug/rtt-raw.csv \
bench ./rtt.sh
docker compose --profile bench down
java benchmark/Report.java benchmark/results/debug
benchmark/charts.sh benchmark/results/debug
pandoc -f gfm -t plain --columns=200 benchmark/results/debug/summary.md
Rows accumulate across runs in the same files, with all.sh as with the scripts alone, so removing results.csv and rtt-raw.csv from benchmark/results/debug before a new exploration keeps its summary limited to that exploration.
Limitations
The extension is experimental, and its configuration and behavior may change. WebSocket connections use HTTP/1.1 or HTTP/2, because Vert.x supports no WebSocket over HTTP/3. Many corporate networks filter UDP, in which case browsers keep using HTTP/2 after a failed attempt, whereas the REST client configured for HTTP/3 fails. Native compilation requires the QUIC native library of the target platform. On networks that lose packets, some HTTP/3 requests never complete, because of the quiche defect that Netty 4.2.20 bundles. The read timeout of the REST client never ends an HTTP/3 request, so every HTTP/3 call needs a time limit of its own. The receive buffer of the QUIC sockets keeps the system default, which a burst of responses can exceed even on the loopback interface.
Conclusion
The quarkus-http3 extension fulfils its essential promise. With a dependency and a few properties, a Quarkus 4.0.1 application serves HTTP/1.1, HTTP/2 and HTTP/3 on one HTTPS port, advertises HTTP/3 to its clients, and calls other services over HTTP/3 with the REST client. Three defects of the extension required workarounds in this project:
- the loss of the HTTP/2 response header fields caused by the
ALTSVCframe; - the startup failure when HTTP/3 is disabled;
- the request header limit that applies to TCP only.
Each workaround remains small and is covered by a test that detects when it becomes unnecessary.
The measurements show that the advantage of HTTP/3 depends on its configuration. With the default address validation mode BASIC, the Retry packet consumes the round trip that QUIC saves, and a new HTTP/3 connection delivers its first response byte after three round trips, exactly as HTTP/2 over TCP and TLS 1.3 does. With the mode NONE, the first response byte arrives after two round trips, 50 milliseconds earlier on the emulated wide area network, and a page of 64 tiles loads 46 milliseconds faster. This mode removes the verification of the client address. The choice between the two modes therefore weighs one round trip per new connection against the protection of the server from connection attempts with forged addresses, and it belongs to the operators of each deployment. Session resumption and 0-RTT, the third mechanism that QUIC offers to save round trips, remain unused, since Vert.x never enables early data, whatever the configuration.
Header compression shows the same distance between the protocol and its implementation. QPACK provides a dynamic table equivalent to that of HPACK, but Vert.x disables it, and HTTP/3 saves 39 percent of the header bytes of the repetitive meta operation, where HTTP/2 saves 98 percent. Applications that send large and repetitive header fields, such as cookies or authorization tokens, therefore transmit more header bytes over HTTP/3 than over HTTP/2 with Quarkus 4.0.1.
On networks that lose packets, the current stack reverses the expected result. HTTP/3 loads a page more slowly than HTTP/2 with 1 and 5 percent loss, and some requests never complete, because the quiche revision that Netty bundles discards a lost end of stream instead of retransmitting it. Since the HTTP client of Vert.x never ends an HTTP/3 request through its timeout, such a request blocks its caller until a time limit set by the application ends it. The quiche project has corrected this defect, and its correction reaches Quarkus applications once Netty, then Vert.x and Quarkus, adopt it. Until then, an application that targets wireless or mobile users benefits from keeping HTTP/2 available alongside HTTP/3, and a service that calls other services across networks with loss benefits from configuring its REST client for HTTP/2.
HTTP/3 in Quarkus 4.0.1 is therefore an experimental capability that already demonstrates the mechanisms of QUIC and the integration of a modern protocol into a Java framework, and whose performance advantages depend on choices made in Vert.x, Netty and quiche. This support is conformant, but it has not yet reached the maturity that production use requires, for four reasons established in this article:
- requests that never complete on networks that lose packets;
- the three defects of the extension;
- the optimizations of the protocol that remain disabled, namely the QPACK dynamic table, 0-RTT and the configuration of address validation;
- the experimental status that Quarkus itself assigns to the extension.
The benchmark of this project can be run again with each new release of these components. By gathering the following:
- the round trip saved by the removal of the Retry packet;
- the round trip that 0-RTT would save;
- the compression ratio that the QPACK dynamic table would provide;
- the behavior of HTTP/3 on networks that lose packets;
running repeatedly the benchmark makes the progression of these advantages directly measurable.