This is an automated email from the ASF dual-hosted git repository.

nicholasjiang pushed a commit to branch branch-0.6
in repository https://gitbox.apache.org/repos/asf/celeborn.git


The following commit(s) were added to refs/heads/branch-0.6 by this push:
     new 39ac38f9c [CELEBORN-2173] jersey-test-framework-core dependency should 
exclude junit5 dependencies to execute java test cases for CI
39ac38f9c is described below

commit 39ac38f9c5fd9dc56bd71a14845e9b3f9acde425
Author: Nicholas Jiang <[email protected]>
AuthorDate: Mon Oct 13 14:02:41 2025 +0800

    [CELEBORN-2173] jersey-test-framework-core dependency should exclude junit5 
dependencies to execute java test cases for CI
    
    ### What changes were proposed in this pull request?
    
    `jersey-test-framework-core` dependency should exclude `junit5` 
dependencies to execute java test cases for CI.
    
    ### Why are the changes needed?
    
    Modules including `service` don't ececute java test cases in CI at present, 
which caused by `jersey-test-framework-core` dependency including `junit5` 
dependencies. Troubleshooting process is as follows:
    
    ```
    $ mvn clean test -pl service
    ...
    2025-10-12T03:16:09.6151210Z [INFO] --- surefire:3.0.0-M7:test 
(default-test)  celeborn-service_2.12 ---
    2025-10-12T03:16:09.6158919Z [WARNING]  Parameter 'systemProperties' is 
deprecated: Use systemPropertyVariables instead.
    2025-10-12T03:16:09.6196031Z [INFO] Surefire report directory: 
/home/runner/work/celeborn/celeborn/service/target/surefire-reports
    2025-10-12T03:16:09.6199880Z [INFO] Using auto detected provider 
org.apache.maven.surefire.junitplatform.JUnitPlatformProvider
    2025-10-12T03:16:12.2891789Z [INFO]
    2025-10-12T03:16:12.2892250Z [INFO] 
-------------------------------------------------------
    2025-10-12T03:16:12.2892718Z [INFO]  T E S T S
    2025-10-12T03:16:12.2893111Z [INFO] 
-------------------------------------------------------
    2025-10-12T03:16:12.5286757Z [INFO]
    2025-10-12T03:16:12.5287379Z [INFO] Results:
    2025-10-12T03:16:12.5287893Z [INFO]
    2025-10-12T03:16:12.5288446Z [INFO] Tests run: 0, Failures: 0, Errors: 0, 
Skipped: 0
    ...
    ```
    
    `maven-surefire-plugin` uses 
`org.apache.maven.surefire.junitplatform.JUnitPlatformProvider` instead of 
`org.apache.maven.surefire.junit4.JUnit4Provider`, which causes the java test 
cases to not run. The reason why `maven-surefire-plugin` uses 
`org.apache.maven.surefire.junitplatform.JUnitPlatformProvider` is that 
`jersey-test-framework-core` dependency has `junit5` dependencies but the java 
test cases use `junit4`.
    
    ```
    $ mvn dependency:tree -pl service
    ...
    [INFO] +- 
org.glassfish.jersey.test-framework:jersey-test-framework-core:jar:2.39.1:test
    [INFO] |  +- jakarta.xml.bind:jakarta.xml.bind-api:jar:2.3.3:compile
    [INFO] |  +- org.glassfish.jersey.media:jersey-media-jaxb:jar:2.39.1:test
    [INFO] |  +- org.junit.jupiter:junit-jupiter:jar:5.9.1:test
    [INFO] |  |  +- org.junit.jupiter:junit-jupiter-api:jar:5.9.1:test
    [INFO] |  |  |  +- org.opentest4j:opentest4j:jar:1.2.0:test
    [INFO] |  |  |  +- org.junit.platform:junit-platform-commons:jar:1.9.1:test
    [INFO] |  |  |  \- org.apiguardian:apiguardian-api:jar:1.1.2:test
    [INFO] |  |  +- org.junit.jupiter:junit-jupiter-params:jar:5.9.1:test
    [INFO] |  |  \- org.junit.jupiter:junit-jupiter-engine:jar:5.9.1:test
    [INFO] |  |     \- org.junit.platform:junit-platform-engine:jar:1.9.1:test
    ...
    ```
    
    ### Does this PR introduce _any_ user-facing change?
    
    No.
    
    ### How was this patch tested?
    
    CI.
    
    Closes #3503 from SteNicholas/CELEBORN-2173.
    
    Authored-by: Nicholas Jiang <[email protected]>
    Signed-off-by: SteNicholas <[email protected]>
    (cherry picked from commit 79c6bf652e88d066f9142d711e931be07054db25)
    Signed-off-by: SteNicholas <[email protected]>
---
 master/pom.xml                                               | 11 +++++++++++
 pom.xml                                                      | 12 ++++++++++++
 worker/pom.xml                                               | 11 +++++++++++
 .../storage/local/DiskMapPartitionDataWriterSuiteJ.java      |  6 ------
 4 files changed, 34 insertions(+), 6 deletions(-)

diff --git a/master/pom.xml b/master/pom.xml
index b2b2b06cd..82645092b 100644
--- a/master/pom.xml
+++ b/master/pom.xml
@@ -135,6 +135,17 @@
       <artifactId>jmh-generator-annprocess</artifactId>
       <scope>test</scope>
     </dependency>
+    <!-- for SSL support -->
+    <dependency>
+      <groupId>org.bouncycastle</groupId>
+      <artifactId>bcprov-jdk18on</artifactId>
+      <scope>test</scope>
+    </dependency>
+    <dependency>
+      <groupId>org.bouncycastle</groupId>
+      <artifactId>bcpkix-jdk18on</artifactId>
+      <scope>test</scope>
+    </dependency>
   </dependencies>
 
   <build>
diff --git a/pom.xml b/pom.xml
index b6ec07fae..f7301be39 100644
--- a/pom.xml
+++ b/pom.xml
@@ -604,6 +604,18 @@
             <groupId>jakarta.servlet</groupId>
             <artifactId>jakarta.servlet-api</artifactId>
           </exclusion>
+          <exclusion>
+            <groupId>org.junit.jupiter</groupId>
+            <artifactId>junit-jupiter-api</artifactId>
+          </exclusion>
+          <exclusion>
+            <groupId>org.junit.jupiter</groupId>
+            <artifactId>junit-jupiter-engine</artifactId>
+          </exclusion>
+          <exclusion>
+            <groupId>org.junit.platform</groupId>
+            <artifactId>junit-platform-launcher</artifactId>
+          </exclusion>
         </exclusions>
       </dependency>
 
diff --git a/worker/pom.xml b/worker/pom.xml
index ad6b1156b..a44d756af 100644
--- a/worker/pom.xml
+++ b/worker/pom.xml
@@ -135,6 +135,17 @@
       <artifactId>httpcore5-h2</artifactId>
       <scope>test</scope>
     </dependency>
+    <!-- for SSL support -->
+    <dependency>
+      <groupId>org.bouncycastle</groupId>
+      <artifactId>bcprov-jdk18on</artifactId>
+      <scope>test</scope>
+    </dependency>
+    <dependency>
+      <groupId>org.bouncycastle</groupId>
+      <artifactId>bcpkix-jdk18on</artifactId>
+      <scope>test</scope>
+    </dependency>
   </dependencies>
 
   <build>
diff --git 
a/worker/src/test/java/org/apache/celeborn/service/deploy/worker/storage/local/DiskMapPartitionDataWriterSuiteJ.java
 
b/worker/src/test/java/org/apache/celeborn/service/deploy/worker/storage/local/DiskMapPartitionDataWriterSuiteJ.java
index 329d7f90f..5f750f895 100644
--- 
a/worker/src/test/java/org/apache/celeborn/service/deploy/worker/storage/local/DiskMapPartitionDataWriterSuiteJ.java
+++ 
b/worker/src/test/java/org/apache/celeborn/service/deploy/worker/storage/local/DiskMapPartitionDataWriterSuiteJ.java
@@ -163,12 +163,6 @@ public class DiskMapPartitionDataWriterSuiteJ {
 
     assertEquals(length.get(), bytesWritten);
     assertEquals(new File(fileWriter.getFilePath()).length(), bytesWritten);
-    assert 
scala.collection.JavaConverters.asJavaCollectionConverter(source.histograms().toSeq())
-        .asJavaCollection().stream()
-        .anyMatch(
-            histogram ->
-                histogram.name().equals(WorkerSource.PARTITION_FILE_SIZE())
-                    && histogram.histogram().getSnapshot().getMax() > 0);
   }
 
   private byte[] generateData(int partitionId) {

Reply via email to