automq icon indicating copy to clipboard operation
automq copied to clipboard

Test suite failures on Java 21

Open vivekchavan14 opened this issue 5 months ago • 2 comments

Environment: • OS: Ubuntu 24.04.2 LTS • Java: OpenJDK 21.0.8 (Ubuntu 21.0.8+9-Ubuntu-0ubuntu124.04.1) • Gradle: 8.8 • AutoMQ Commit: 014d2d2861 (latest main branch) • Command: ./gradlew build

Issue Description: The test suite fails with 132 total test failures when building on Java 21. The build succeeds when tests are skipped (./gradlew build -x test), indicating this is purely a test environment issue.

Failure Summary: • Metadata module: 131/931 tests failing (85% success rate) • Connect API module: 1/313 tests failing (99% success rate)

Major Failing Test Classes: • ClusterControlManagerTest (21/22 tests failing) • ReplicationControlManagerTest (64/66 tests failing) • QuorumControllerTest (24/34 tests failing) • ProducerIdControlManagerTest (all 5 tests failing) • QuorumControllerMetricsIntegrationTest (all 5 tests failing) • ValuesTest.shouldParseStringListWithMultipleElementTypes() (connect-api)

Sample Error:

org.opentest4j.AssertionFailedError: expected: <MAP> but was: <ARRAY>
    at org.apache.kafka.connect.data.ValuesTest.assertParseStringArrayWithNoSchema(ValuesTest.java:478)

Workaround: Build succeeds with

./gradlew build -x test

vivekchavan14 avatar Jul 29 '25 14:07 vivekchavan14

Hi, The original Apache Kafka test cases have not been fully adapted yet. Therefore, it is necessary to run the test cases through ./gradlew build -x test.

Welcome to participate in the test fix

superhx avatar Jul 30 '25 02:07 superhx

Thanks for the clarification! I'll proceed with

./gradlew build -x test,

I'll try to fix test-cases

vivekchavan14 avatar Jul 30 '25 12:07 vivekchavan14