Skip to content

Enable io_uring testing in CI#5633

Open
vietj wants to merge 9 commits intomasterfrom
enable-io-uring-ci
Open

Enable io_uring testing in CI#5633
vietj wants to merge 9 commits intomasterfrom
enable-io-uring-ci

Conversation

@vietj
Copy link
Copy Markdown
Member

@vietj vietj commented Jun 30, 2025

  • Add new job to actions
  • TransportTest#testNoNative does not check for io_uring
  • Remove no io_uring transport assumptions where possible (e.g. not yet possible for tests that require Unix Domain Socket or file regions support)

@vietj vietj added this to the 5.1.0 milestone Jun 30, 2025
@vietj vietj self-assigned this Jun 30, 2025
@vietj vietj force-pushed the enable-io-uring-ci branch from 58cb672 to 3776d51 Compare November 3, 2025 16:26
@vietj vietj force-pushed the enable-io-uring-ci branch from 3776d51 to 8e7963e Compare March 6, 2026 18:13
@vietj
Copy link
Copy Markdown
Member Author

vietj commented Mar 12, 2026

@tsegismont you might want to only keep io_uring profile in github action for tryiung this

@tsegismont
Copy link
Copy Markdown
Member

@tsegismont you might want to only keep io_uring profile in github action for tryiung this

Initially, yes. We'll get some feedback faster and save some useless job runs. Eventually, we need to make sure there are no regressions.

@tsegismont tsegismont force-pushed the enable-io-uring-ci branch 3 times, most recently from f745db2 to 6da17b4 Compare April 28, 2026 14:07
@tsegismont tsegismont assigned tsegismont and unassigned vietj Apr 28, 2026
@tsegismont
Copy link
Copy Markdown
Member

@vietj PTAL, the PR is now ready for review

tsegismont added 5 commits May 5, 2026 14:44
Fixes Http1xTest.testIdleTimeoutInfiniteSkipOfControlCharactersState

With io_uring, file regions are not supported so ChunkedWriteHandler is present.
As a result computeChannelName returned "chunkedWriter", placing the HTTP decoder after the IdleStateHandler in the inbound pipeline.
This caused the IdleStateHandler to see raw bytes instead of decoded HTTP objects, so any incoming data (even unparseable control characters) would reset the idle timer.
The fix consists in swapping the check order so the HTTP decoder is always inserted before the IdleStateHandler, ensuring idle timeout is based on HTTP-level activity.

This also fixes NetBandwidthLimitingTest, Http1xTest#testPipeliningOrder and NetTest.

Signed-off-by: Thomas Segismont <tsegismont@gmail.com>
With io_uring, 1MB fits entirely in the kernel send buffer, so the write operation completes before the peer's connection close is detected.

Signed-off-by: Thomas Segismont <tsegismont@gmail.com>
testFailedQueueMessages passes, not sure why it didn't pass before.

In testDrainReentrancy, we can't check for writability after flushing, because with io_uring the writability is updated asynchronously when the write operation completes.

Signed-off-by: Thomas Segismont <tsegismont@gmail.com>
It only checked EPOLL and KQUEUE

Signed-off-by: Thomas Segismont <tsegismont@gmail.com>
Not supported yet with io_uring

See netty/netty#16718

Signed-off-by: Thomas Segismont <tsegismont@gmail.com>
@tsegismont tsegismont force-pushed the enable-io-uring-ci branch from f710487 to bcbdf67 Compare May 5, 2026 13:52
Re-enable the NativeIoUring matrix entry in ci-matrix-5.x.yml.

Added an io_uring_supported input so that 5.0 scheduled builds don't try to run tests with io_uring.
We need to do this because a matrix definition cannot contain expressions.
When 5.1 is released, we can remove this param.

Also when running test with io_uring transport, we must raise the locked memory limit and configure io_uring ring sizes.
Otherwise, tests fail because the default 8MB limit is reached.

Signed-off-by: Thomas Segismont <tsegismont@gmail.com>
@tsegismont tsegismont force-pushed the enable-io-uring-ci branch from bcbdf67 to 432362d Compare May 5, 2026 14:48
@tsegismont
Copy link
Copy Markdown
Member

@vietj PTAL, the PR has been updated as per our review today

@tsegismont
Copy link
Copy Markdown
Member

@vietj this PR has been rebased on master, and since then we get this persistent failure on CI:

Error:  io.vertx.tests.json.jackson.JacksonReadConstraintsTest.testDefaultConstraints -- Time elapsed: 1.636 s <<< ERROR!
java.lang.OutOfMemoryError: Java heap space
	at java.base/java.util.Arrays.copyOfRange(Arrays.java:4030)
	at java.base/java.lang.StringLatin1.newString(StringLatin1.java:715)
	at java.base/java.lang.StringBuilder.toString(StringBuilder.java:452)
	at com.fasterxml.jackson.core.util.TextBuffer.contentsAsString(TextBuffer.java:503)
	at com.fasterxml.jackson.core.json.ReaderBasedJsonParser.getText(ReaderBasedJsonParser.java:297)
	at com.fasterxml.jackson.databind.deser.std.UntypedObjectDeserializerNR.deserialize(UntypedObjectDeserializerNR.java:81)
	at com.fasterxml.jackson.databind.deser.std.MapDeserializer._deserializeNoNullChecks(MapDeserializer.java:891)
	at com.fasterxml.jackson.databind.deser.std.MapDeserializer._readAndBindStringKeyMap(MapDeserializer.java:623)
	at com.fasterxml.jackson.databind.deser.std.MapDeserializer.deserialize(MapDeserializer.java:450)
	at com.fasterxml.jackson.databind.deser.std.MapDeserializer.deserialize(MapDeserializer.java:31)
	at com.fasterxml.jackson.databind.deser.DefaultDeserializationContext.readRootValue(DefaultDeserializationContext.java:342)
	at com.fasterxml.jackson.databind.ObjectMapper._readValue(ObjectMapper.java:5023)
	at com.fasterxml.jackson.databind.ObjectMapper.readValue(ObjectMapper.java:3104)
	at io.vertx.core.json.jackson.DatabindCodec.fromParser(DatabindCodec.java:112)
	at io.vertx.core.json.jackson.DatabindCodec.fromString(DatabindCodec.java:76)
	at io.vertx.core.json.JsonObject.fromJson(JsonObject.java:1227)
	at io.vertx.core.json.JsonObject.<init>(JsonObject.java:52)
	at io.vertx.tests.json.jackson.JacksonReadConstraintsTestBase.testMaxStringLength(JacksonReadConstraintsTestBase.java:74)
	at io.vertx.tests.json.jackson.JacksonReadConstraintsTestBase.testReadConstraints(JacksonReadConstraintsTestBase.java:38)
	at io.vertx.tests.json.jackson.JacksonReadConstraintsTest.testDefaultConstraints(JacksonReadConstraintsTest.java:26)
	at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
	at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
	at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
	at java.base/java.lang.reflect.Method.invoke(Method.java:566)
	at org.junit.runners.model.FrameworkMethod$1.runReflectiveCall(FrameworkMethod.java:59)
	at org.junit.internal.runners.model.ReflectiveCallable.run(ReflectiveCallable.java:12)
	at org.junit.runners.model.FrameworkMethod.invokeExplosively(FrameworkMethod.java:56)
	at org.junit.internal.runners.statements.InvokeMethod.evaluate(InvokeMethod.java:17)
	at org.junit.runners.ParentRunner$3.evaluate(ParentRunner.java:306)
	at org.junit.runners.BlockJUnit4ClassRunner$1.evaluate(BlockJUnit4ClassRunner.java:100)
	at org.junit.runners.ParentRunner.runLeaf(ParentRunner.java:366)
	at org.junit.runners.BlockJUnit4ClassRunner.runChild(BlockJUnit4ClassRunner.java:103)

This is io_uring only and unfortunately I can't reproduce on my machine.

Does that ring a bell?

tsegismont added 2 commits May 6, 2026 11:26
And upload files as artifacts in GH, if any.

Signed-off-by: Thomas Segismont <tsegismont@gmail.com>
Signed-off-by: Thomas Segismont <tsegismont@gmail.com>
@tsegismont tsegismont force-pushed the enable-io-uring-ci branch 2 times, most recently from 1dde325 to 4adcb71 Compare May 6, 2026 16:35
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants