adoroszlai commented on code in PR #9014:
URL: https://github.com/apache/hadoop/pull/9014#discussion_r4690741131


##########
.github/workflows/tmpl_build_and_test.yml:
##########
@@ -176,6 +176,12 @@ jobs:
           java-version: ${{ inputs.java }}
           cache: 'maven'
           check-latest: false
+      # ./mvnw downloads maven-wrapper.jar into the workspace, which 
setup-java does not cache
+      - name: Cache Maven wrapper jar
+        uses: actions/cache@27d5ce7f107fe9357f9df03efb73ab90386fccae # v5.0.5
+        with:
+          path: .mvn/wrapper/maven-wrapper.jar
+          key: maven-wrapper-jar-${{ 
hashFiles('.mvn/wrapper/maven-wrapper.properties') }}

Review Comment:
   `type=only-script` (the default type) would not use the wrapper jar at all.  
What do you think about switching to that?  Like:
   
   ```diff
   --- .mvn/wrapper/maven-wrapper.properties
   +++ .mvn/wrapper/maven-wrapper.properties
   @@ -16,8 +16,6 @@
    # limitations under the License.
    #
    wrapperVersion=3.3.4
   -distributionType=source
   +distributionType=only-script
    
distributionUrl=https://repo.maven.apache.org/maven2/org/apache/maven/apache-maven/3.9.15/apache-maven-3.9.15-bin.zip
    
distributionSha256Sum=b0d9292f06c5faded31ddcb6cb69099f316d6fea40a7778624b259bad9fed18a
   
-wrapperUrl=https://repo.maven.apache.org/maven2/org/apache/maven/wrapper/maven-wrapper/3.3.4/maven-wrapper-3.3.4.jar
   
-wrapperSha256Sum=4e2fbf6554bc8a4702cdfdd3bef464f423393d784ddbb037216320ce55d5e4e1
   ```
   
   (`mvnw` also would need to be updated via `mvn wrapper:wrapper`.)
   
   CC @pan3793



-- 
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]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to