Skip to content

HADOOP-19610. S3A: ITests to run under JUnit5 #7814

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 4 commits into
base: trunk
Choose a base branch
from

Conversation

steveloughran
Copy link
Contributor

Fixing parameterized ITests in hadoop-aws to work under Junit 5.

This is on top of PR #7785

For code changes:

  • Does the title or this PR starts with the corresponding JIRA issue id (e.g. 'HADOOP-17799. Your PR title ...')?
  • Object storage: have the integration tests been executed and the endpoint declared according to the connector-specific documentation?
  • If adding new dependencies to the code, are these dependencies licensed in a way that is compatible for inclusion under ASF 2.0?
  • If applicable, have you updated the LICENSE, LICENSE-binary, NOTICE-binary files?

* junit.jupiter and junit.vintage => 5.13.3
* junit.platform => 1.13.3
* Surefire => 3.5.3. Without that tests weren't being found.
* cut a duplicate and conflicting import of mockito-jupiter;
  maven was warning of this.
pick up changes of apache#5567 to pull out setting of stack trace
and failIfNoSpecifiedTests to build properties with our
chosen values.
@steveloughran
Copy link
Contributor Author

Seems to kick off the tests in parallel. There are three runs, the last with no tests executed. But its elapsed time is exactly those of the other two executions added up (16.38 + 12.42
=28.8)

-------------------------------------------------------
[INFO] Running org.apache.hadoop.fs.s3a.performance.ITestCreateFileCost
[INFO] Running org.apache.hadoop.fs.s3a.performance.ITestCreateFileCost
[INFO] Tests run: 11, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 16.38 s -- in org.apache.hadoop.fs.s3a.performance.ITestCreateFileCost
[INFO] Running org.apache.hadoop.fs.s3a.performance.ITestCreateFileCost
[INFO] Tests run: 11, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 12.42 s -- in org.apache.hadoop.fs.s3a.performance.ITestCreateFileCost
[INFO] Tests run: 0, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 28.89 s -- in org.apache.hadoop.fs.s3a.performance.ITestCreateFileCost
[INFO] 
[INFO

@steveloughran
Copy link
Contributor Author

comparison execution time

[INFO] Running org.apache.hadoop.fs.s3a.performance.ITestCreateFileCost
[INFO] Tests run: 22, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 25.591 s - in org.apache.hadoop.fs.s3a.performance.ITestCreateFileCost

note that both test runs were in a single process, so even if the log showed three test suites running at the same time, only one process is running

37302 surefirebooter-20250717193759647_3.jar -Xmx4096m -Xss2m -XX:+HeapDumpOnOutOfMemoryError -XX:+IgnoreUnrecognizedVMOptions --add-opens=java.base/java.io=ALL-UNNAMED --add-opens=java.base/java.lang=ALL-UNNAMED --add-opens=java.base/java.lang.reflect=ALL-UNNAMED --add-opens=java.base/java.math=ALL-UNNAMED --add-opens=java.base/java.net=ALL-UNNAMED --add-opens=java.base/java.text=ALL-UNNAMED --add-opens=java.base/java.util=ALL-UNNAMED --add-opens=java.base/java.util.concurrent=ALL-UNNAMED --add-opens=java.base/java.util.zip=ALL-UNNAMED --add-opens=java.base/sun.security.util=ALL-UNNAMED --add-opens=java.base/sun.security.x509=ALL-UNNAMED --enable-native-access=ALL-UNNAMED

I don't think that is good, because we do have shared state (filesystem cache etc) which will interfere with each other

@hadoop-yetus
Copy link

🎊 +1 overall

Vote Subsystem Runtime Logfile Comment
+0 🆗 reexec 1m 32s Docker mode activated.
_ Prechecks _
+1 💚 dupname 0m 0s No case conflicting files found.
+0 🆗 codespell 0m 0s codespell was not available.
+0 🆗 detsecrets 0m 0s detect-secrets was not available.
+0 🆗 xmllint 0m 0s xmllint was not available.
+1 💚 @author 0m 0s The patch does not contain any @author tags.
+1 💚 test4tests 0m 0s The patch appears to include 1 new or modified test files.
_ trunk Compile Tests _
+0 🆗 mvndep 69m 56s Maven dependency ordering for branch
+1 💚 mvninstall 42m 24s trunk passed
+1 💚 compile 18m 6s trunk passed with JDK Ubuntu-11.0.27+6-post-Ubuntu-0ubuntu120.04
+1 💚 compile 15m 22s trunk passed with JDK Private Build-1.8.0_452-8u452-gaus1-0ubuntu120.04-b09
+1 💚 checkstyle 4m 46s trunk passed
+1 💚 mvnsite 3m 13s trunk passed
+1 💚 javadoc 3m 3s trunk passed with JDK Ubuntu-11.0.27+6-post-Ubuntu-0ubuntu120.04
+1 💚 javadoc 2m 51s trunk passed with JDK Private Build-1.8.0_452-8u452-gaus1-0ubuntu120.04-b09
+0 🆗 spotbugs 0m 43s branch/hadoop-project no spotbugs output file (spotbugsXml.xml)
+0 🆗 spotbugs 0m 38s branch/hadoop-client-modules/hadoop-client-integration-tests no spotbugs output file (spotbugsXml.xml)
+1 💚 shadedclient 42m 3s branch has no errors when building and testing our client artifacts.
_ Patch Compile Tests _
+0 🆗 mvndep 3m 14s Maven dependency ordering for patch
+1 💚 mvninstall 1m 37s the patch passed
+1 💚 compile 17m 5s the patch passed with JDK Ubuntu-11.0.27+6-post-Ubuntu-0ubuntu120.04
+1 💚 javac 17m 5s the patch passed
+1 💚 compile 15m 20s the patch passed with JDK Private Build-1.8.0_452-8u452-gaus1-0ubuntu120.04-b09
+1 💚 javac 15m 20s the patch passed
+1 💚 blanks 0m 0s The patch has no blanks issues.
+1 💚 checkstyle 4m 39s the patch passed
+1 💚 mvnsite 3m 9s the patch passed
+1 💚 javadoc 2m 58s the patch passed with JDK Ubuntu-11.0.27+6-post-Ubuntu-0ubuntu120.04
+1 💚 javadoc 2m 51s the patch passed with JDK Private Build-1.8.0_452-8u452-gaus1-0ubuntu120.04-b09
+0 🆗 spotbugs 0m 37s hadoop-project has no data from spotbugs
+0 🆗 spotbugs 0m 39s hadoop-client-modules/hadoop-client-integration-tests has no data from spotbugs
+1 💚 shadedclient 40m 58s patch has no errors when building and testing our client artifacts.
_ Other Tests _
+1 💚 unit 0m 36s hadoop-project in the patch passed.
+1 💚 unit 3m 37s hadoop-aws in the patch passed.
+1 💚 unit 3m 0s hadoop-azure in the patch passed.
+1 💚 unit 0m 37s hadoop-client-integration-tests in the patch passed.
+1 💚 asflicense 1m 7s The patch does not generate ASF License warnings.
318m 37s
Subsystem Report/Notes
Docker ClientAPI=1.51 ServerAPI=1.51 base: https://ci-hadoop.apache.org/job/hadoop-multibranch/job/PR-7814/1/artifact/out/Dockerfile
GITHUB PR #7814
Optional Tests dupname asflicense compile javac javadoc mvninstall mvnsite unit shadedclient codespell detsecrets xmllint spotbugs checkstyle
uname Linux 4917720f972a 5.15.0-139-generic #149-Ubuntu SMP Fri Apr 11 22:06:13 UTC 2025 x86_64 x86_64 x86_64 GNU/Linux
Build tool maven
Personality dev-support/bin/hadoop.sh
git revision trunk / aea678c
Default Java Private Build-1.8.0_452-8u452-gaus1-0ubuntu120.04-b09
Multi-JDK versions /usr/lib/jvm/java-11-openjdk-amd64:Ubuntu-11.0.27+6-post-Ubuntu-0ubuntu120.04 /usr/lib/jvm/java-8-openjdk-amd64:Private Build-1.8.0_452-8u452-gaus1-0ubuntu120.04-b09
Test Results https://ci-hadoop.apache.org/job/hadoop-multibranch/job/PR-7814/1/testReport/
Max. process+thread count 534 (vs. ulimit of 5500)
modules C: hadoop-project hadoop-tools/hadoop-aws hadoop-tools/hadoop-azure hadoop-client-modules/hadoop-client-integration-tests U: .
Console output https://ci-hadoop.apache.org/job/hadoop-multibranch/job/PR-7814/1/console
versions git=2.25.1 maven=3.6.3 spotbugs=4.2.2
Powered by Apache Yetus 0.14.0 https://yetus.apache.org

This message was automatically generated.

@steveloughran steveloughran changed the title S3/hadoop 19610 itests junit5 HADOOP-19610. S3A: ITests to run under JUnit5 Jul 18, 2025
These map to "flaky", "rootfilesystem" and "scale" Junit 5 tags.

Goals
-can control which tests are run
-tests which are flaky due to external factors like network underflow
 can be skipped by CI builds.

Add Class attribute @ParamString, where goal is to provide a string
of the formatted parameterized values.

@ParamString("performance-%s")

There's no implementation of this (yet); may need a different way
of doing it later. Goal is to make it possible to use in path names.
JUnit4 methodName did this, but I am not sure about JUnit 5
...this is a placeholder.

ITestS3AContractSeek is class parameterized.
@hadoop-yetus
Copy link

🎊 +1 overall

Vote Subsystem Runtime Logfile Comment
+0 🆗 reexec 8m 16s Docker mode activated.
_ Prechecks _
+1 💚 dupname 0m 0s No case conflicting files found.
+0 🆗 codespell 0m 0s codespell was not available.
+0 🆗 detsecrets 0m 0s detect-secrets was not available.
+0 🆗 xmllint 0m 0s xmllint was not available.
+1 💚 @author 0m 0s The patch does not contain any @author tags.
+1 💚 test4tests 0m 0s The patch appears to include 10 new or modified test files.
_ trunk Compile Tests _
+0 🆗 mvndep 44m 7s Maven dependency ordering for branch
+1 💚 mvninstall 20m 39s trunk passed
+1 💚 compile 8m 29s trunk passed with JDK Ubuntu-11.0.27+6-post-Ubuntu-0ubuntu120.04
+1 💚 compile 7m 34s trunk passed with JDK Private Build-1.8.0_452-8u452-gaus1-0ubuntu120.04-b09
+1 💚 checkstyle 2m 1s trunk passed
+1 💚 mvnsite 3m 10s trunk passed
+1 💚 javadoc 2m 46s trunk passed with JDK Ubuntu-11.0.27+6-post-Ubuntu-0ubuntu120.04
+1 💚 javadoc 2m 34s trunk passed with JDK Private Build-1.8.0_452-8u452-gaus1-0ubuntu120.04-b09
+0 🆗 spotbugs 0m 33s branch/hadoop-project no spotbugs output file (spotbugsXml.xml)
+0 🆗 spotbugs 0m 26s branch/hadoop-client-modules/hadoop-client-integration-tests no spotbugs output file (spotbugsXml.xml)
+1 💚 shadedclient 21m 33s branch has no errors when building and testing our client artifacts.
_ Patch Compile Tests _
+0 🆗 mvndep 0m 30s Maven dependency ordering for patch
+1 💚 mvninstall 1m 37s the patch passed
+1 💚 compile 8m 11s the patch passed with JDK Ubuntu-11.0.27+6-post-Ubuntu-0ubuntu120.04
+1 💚 javac 8m 11s the patch passed
+1 💚 compile 7m 46s the patch passed with JDK Private Build-1.8.0_452-8u452-gaus1-0ubuntu120.04-b09
+1 💚 javac 7m 46s the patch passed
+1 💚 blanks 0m 0s The patch has no blanks issues.
-0 ⚠️ checkstyle 1m 55s /results-checkstyle-root.txt root: The patch generated 3 new + 2 unchanged - 0 fixed = 5 total (was 2)
+1 💚 mvnsite 3m 5s the patch passed
+1 💚 javadoc 2m 42s the patch passed with JDK Ubuntu-11.0.27+6-post-Ubuntu-0ubuntu120.04
+1 💚 javadoc 2m 35s the patch passed with JDK Private Build-1.8.0_452-8u452-gaus1-0ubuntu120.04-b09
+0 🆗 spotbugs 0m 27s hadoop-project has no data from spotbugs
+0 🆗 spotbugs 0m 25s hadoop-client-modules/hadoop-client-integration-tests has no data from spotbugs
+1 💚 shadedclient 24m 20s patch has no errors when building and testing our client artifacts.
_ Other Tests _
+1 💚 unit 0m 18s hadoop-project in the patch passed.
+1 💚 unit 18m 32s hadoop-common in the patch passed.
+1 💚 unit 2m 45s hadoop-aws in the patch passed.
+1 💚 unit 2m 28s hadoop-azure in the patch passed.
+1 💚 unit 0m 26s hadoop-client-integration-tests in the patch passed.
+1 💚 asflicense 0m 41s The patch does not generate ASF License warnings.
211m 27s
Subsystem Report/Notes
Docker ClientAPI=1.51 ServerAPI=1.51 base: https://ci-hadoop.apache.org/job/hadoop-multibranch/job/PR-7814/2/artifact/out/Dockerfile
GITHUB PR #7814
Optional Tests dupname asflicense compile javac javadoc mvninstall mvnsite unit shadedclient codespell detsecrets xmllint spotbugs checkstyle
uname Linux 63d1f6ad482c 5.15.0-143-generic #153-Ubuntu SMP Fri Jun 13 19:10:45 UTC 2025 x86_64 x86_64 x86_64 GNU/Linux
Build tool maven
Personality dev-support/bin/hadoop.sh
git revision trunk / f6e890a
Default Java Private Build-1.8.0_452-8u452-gaus1-0ubuntu120.04-b09
Multi-JDK versions /usr/lib/jvm/java-11-openjdk-amd64:Ubuntu-11.0.27+6-post-Ubuntu-0ubuntu120.04 /usr/lib/jvm/java-8-openjdk-amd64:Private Build-1.8.0_452-8u452-gaus1-0ubuntu120.04-b09
Test Results https://ci-hadoop.apache.org/job/hadoop-multibranch/job/PR-7814/2/testReport/
Max. process+thread count 1509 (vs. ulimit of 5500)
modules C: hadoop-project hadoop-common-project/hadoop-common hadoop-tools/hadoop-aws hadoop-tools/hadoop-azure hadoop-client-modules/hadoop-client-integration-tests U: .
Console output https://ci-hadoop.apache.org/job/hadoop-multibranch/job/PR-7814/2/console
versions git=2.25.1 maven=3.6.3 spotbugs=4.2.2
Powered by Apache Yetus 0.14.0 https://yetus.apache.org

This message was automatically generated.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants