You are viewing a plain text version of this content. The canonical link for it is here.
Posted to jira@kafka.apache.org by GitBox <gi...@apache.org> on 2022/04/20 19:28:14 UTC

[GitHub] [kafka] clayburn commented on a diff in pull request #12003: MINOR: Improve Gradle Caching and Fix Deprecations

clayburn commented on code in PR #12003:
URL: https://github.com/apache/kafka/pull/12003#discussion_r854483866


##########
build.gradle:
##########
@@ -1216,12 +1237,16 @@ project(':clients') {
     testRuntimeOnly libs.jacksonJDK8Datatypes
     testImplementation libs.jose4j
     testImplementation libs.jacksonJaxrsJsonProvider
+
+    generator project(':generator')
   }
 
   task createVersionFile() {
-    ext.receiptFile = file("$buildDir/kafka/$buildVersionFileName")
+    def receiptFile = file("$buildDir/kafka/$buildVersionFileName")
+    inputs.property "commitId", commitId

Review Comment:
   Without declaring `commitId` and `version` as inputs to these `createVersionFile` tasks, they will never be UP-TO-DATE and won't be cacheable, so they will always run, even when they would just produce the exact same outputs. See: [Gradle Incremental Build docs](https://docs.gradle.org/current/userguide/more_about_tasks.html#sec:task_inputs_outputs).



-- 
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: jira-unsubscribe@kafka.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org