Jimexist commented on code in PR #2602:
URL: https://github.com/apache/thrift/pull/2602#discussion_r867695178


##########
.github/workflows/build.yml:
##########
@@ -131,11 +131,111 @@ jobs:
       - name: Run make for java
         run: make -C lib/java
 
+      - name: Run make install for java
+        run: make -C lib/java install
+
+      - name: Upload java libthrift artifacts
+        uses: actions/upload-artifact@v3
+        with:
+          name: libthrift
+          if-no-files-found: error
+          path: ~/.m2/repository/org/apache/thrift
+
       - name: Run make check for java
         run: make -C lib/java check
 
+      - name: Run make precross for java
+        run: make -C lib/java precross
+
+      - name: Upload java precross artifacts
+        uses: actions/upload-artifact@v3
+        with:
+          name: java-precross
+          if-no-files-found: error
+          path: |
+            lib/java/build/functionalTestJar/
+            lib/java/build/runclient
+            lib/java/build/runnonblockingserver
+            lib/java/build/runserver
+            lib/java/build/runservletserver
+          retention-days: 3
+
       - name: Run make for kotlin
         run: make -C lib/kotlin
 
       - name: Run make check for kotlin
         run: make -C lib/kotlin check
+
+      - name: Run make precross for kotlin
+        run: make -C lib/kotlin precross
+
+      - name: Upload kotlin precross artifacts
+        uses: actions/upload-artifact@v3
+        with:
+          name: kotlin-precross
+          if-no-files-found: error
+          path: |
+            lib/kotlin/cross-test-client/build/install/TestClient/
+            lib/kotlin/cross-test-server/build/install/TestServer/
+          retention-days: 3
+
+  cross-test:
+    needs:
+      - lib-java-kotlin
+    strategy:
+      matrix:
+        test_regex:
+          - "(binary)"
+          - "(header|json)"
+          - "(compact|multiplexed)"
+    runs-on: ubuntu-20.04
+    steps:
+      - uses: actions/checkout@v3
+      - uses: actions/setup-python@v3
+        with:
+          python-version: "3.x"
+      - uses: actions/setup-java@v3
+        with:
+          distribution: temurin
+          # here we intentionally use java 8 so that we also verify java 11 
compiles to version 8
+          java-version: 8
+          cache: "gradle"
+
+      - name: Download java precross artifacts
+        uses: actions/download-artifact@v3
+        with:
+          name: java-precross
+          path: lib/java/build
+
+      - name: Download kotlin precross artifacts
+        uses: actions/download-artifact@v3
+        with:
+          name: kotlin-precross
+          path: lib/kotlin
+
+      - name: Set back executable flags
+        run: |
+          chmod a+x \
+            lib/java/build/run* \
+            lib/kotlin/cross-test-client/build/install/TestClient/bin/* \
+            lib/kotlin/cross-test-server/build/install/TestServer/bin/*
+
+      - name: Run precross

Review Comment:
   ```suggestion
         - name: Run cross test
   ```



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to