Update Gradle to 7.4.1 (#2078)
* Update Gradle to 7.4.1 Signed-off-by: Andriy Redko <andriy.redko@aiven.io> * Address code review comments, added @PathSensitive(PathSensitivity.RELATIVE) where applicable Signed-off-by: Andriy Redko <andriy.redko@aiven.io>
This commit is contained in:
parent
8f4aec109d
commit
223efe68e6
|
@ -112,7 +112,7 @@ dependencies {
|
|||
api 'commons-io:commons-io:2.7'
|
||||
api "net.java.dev.jna:jna:5.10.0"
|
||||
api 'gradle.plugin.com.github.johnrengelman:shadow:7.1.2'
|
||||
api 'de.thetaphi:forbiddenapis:3.2'
|
||||
api 'de.thetaphi:forbiddenapis:3.3'
|
||||
api 'com.avast.gradle:gradle-docker-compose-plugin:0.14.12'
|
||||
api 'org.apache.maven:maven-model:3.6.2'
|
||||
api 'com.networknt:json-schema-validator:1.0.68'
|
||||
|
|
|
@ -35,7 +35,10 @@ import org.opensearch.gradle.AntTask
|
|||
import org.gradle.api.file.FileCollection
|
||||
import org.gradle.api.tasks.Input
|
||||
import org.gradle.api.tasks.InputFiles
|
||||
import org.gradle.api.tasks.IgnoreEmptyDirectories;
|
||||
import org.gradle.api.tasks.OutputFile
|
||||
import org.gradle.api.tasks.PathSensitive
|
||||
import org.gradle.api.tasks.PathSensitivity
|
||||
import org.gradle.api.tasks.SkipWhenEmpty
|
||||
|
||||
import java.nio.file.Files
|
||||
|
@ -78,6 +81,8 @@ class LicenseHeadersTask extends AntTask {
|
|||
*/
|
||||
@InputFiles
|
||||
@SkipWhenEmpty
|
||||
@IgnoreEmptyDirectories
|
||||
@PathSensitive(PathSensitivity.RELATIVE)
|
||||
List<FileCollection> getJavaFiles() {
|
||||
return project.sourceSets.collect({it.allJava})
|
||||
}
|
||||
|
|
|
@ -46,8 +46,11 @@ import org.gradle.api.DefaultTask;
|
|||
import org.gradle.api.GradleException;
|
||||
import org.gradle.api.file.FileCollection;
|
||||
import org.gradle.api.file.FileTree;
|
||||
import org.gradle.api.tasks.IgnoreEmptyDirectories;
|
||||
import org.gradle.api.tasks.InputFiles;
|
||||
import org.gradle.api.tasks.OutputFile;
|
||||
import org.gradle.api.tasks.PathSensitive;
|
||||
import org.gradle.api.tasks.PathSensitivity;
|
||||
import org.gradle.api.tasks.SkipWhenEmpty;
|
||||
import org.gradle.api.tasks.StopExecutionException;
|
||||
import org.gradle.api.tasks.TaskAction;
|
||||
|
@ -92,6 +95,8 @@ public class FilePermissionsTask extends DefaultTask {
|
|||
*/
|
||||
@InputFiles
|
||||
@SkipWhenEmpty
|
||||
@IgnoreEmptyDirectories
|
||||
@PathSensitive(PathSensitivity.RELATIVE)
|
||||
public FileCollection getFiles() {
|
||||
return GradleUtils.getJavaSourceSets(getProject())
|
||||
.stream()
|
||||
|
|
|
@ -37,9 +37,12 @@ import org.gradle.api.InvalidUserDataException;
|
|||
import org.gradle.api.file.FileCollection;
|
||||
import org.gradle.api.file.FileTree;
|
||||
import org.gradle.api.plugins.JavaPluginConvention;
|
||||
import org.gradle.api.tasks.IgnoreEmptyDirectories;
|
||||
import org.gradle.api.tasks.Input;
|
||||
import org.gradle.api.tasks.InputFiles;
|
||||
import org.gradle.api.tasks.OutputFile;
|
||||
import org.gradle.api.tasks.PathSensitive;
|
||||
import org.gradle.api.tasks.PathSensitivity;
|
||||
import org.gradle.api.tasks.SkipWhenEmpty;
|
||||
import org.gradle.api.tasks.TaskAction;
|
||||
import org.gradle.api.tasks.util.PatternFilterable;
|
||||
|
@ -100,6 +103,8 @@ public class ForbiddenPatternsTask extends DefaultTask {
|
|||
|
||||
@InputFiles
|
||||
@SkipWhenEmpty
|
||||
@IgnoreEmptyDirectories
|
||||
@PathSensitive(PathSensitivity.RELATIVE)
|
||||
public FileCollection getFiles() {
|
||||
return getProject().getConvention()
|
||||
.getPlugin(JavaPluginConvention.class)
|
||||
|
|
|
@ -37,6 +37,7 @@ import org.gradle.api.file.FileCollection;
|
|||
import org.gradle.api.plugins.JavaPluginConvention;
|
||||
import org.gradle.api.tasks.CacheableTask;
|
||||
import org.gradle.api.tasks.Classpath;
|
||||
import org.gradle.api.tasks.IgnoreEmptyDirectories;
|
||||
import org.gradle.api.tasks.InputFiles;
|
||||
import org.gradle.api.tasks.PathSensitive;
|
||||
import org.gradle.api.tasks.PathSensitivity;
|
||||
|
@ -79,6 +80,7 @@ public class LoggerUsageTask extends PrecommitTask {
|
|||
@InputFiles
|
||||
@PathSensitive(PathSensitivity.RELATIVE)
|
||||
@SkipWhenEmpty
|
||||
@IgnoreEmptyDirectories
|
||||
public FileCollection getClassDirectories() {
|
||||
return getProject().getConvention()
|
||||
.getPlugin(JavaPluginConvention.class)
|
||||
|
|
|
@ -47,6 +47,7 @@ import org.gradle.api.specs.Spec;
|
|||
import org.gradle.api.tasks.CacheableTask;
|
||||
import org.gradle.api.tasks.Classpath;
|
||||
import org.gradle.api.tasks.CompileClasspath;
|
||||
import org.gradle.api.tasks.IgnoreEmptyDirectories;
|
||||
import org.gradle.api.tasks.Input;
|
||||
import org.gradle.api.tasks.InputFile;
|
||||
import org.gradle.api.tasks.InputFiles;
|
||||
|
@ -195,6 +196,7 @@ public class ThirdPartyAuditTask extends DefaultTask {
|
|||
|
||||
@Classpath
|
||||
@SkipWhenEmpty
|
||||
@IgnoreEmptyDirectories
|
||||
public Set<File> getJarsToScan() {
|
||||
// These are SelfResolvingDependency, and some of them backed by file collections, like the Gradle API files,
|
||||
// or dependencies added as `files(...)`, we can't be sure if those are third party or not.
|
||||
|
|
|
@ -43,9 +43,12 @@ import org.gradle.api.file.FileSystemOperations;
|
|||
import org.gradle.api.file.FileTree;
|
||||
import org.gradle.api.plugins.JavaPluginConvention;
|
||||
import org.gradle.api.provider.ListProperty;
|
||||
import org.gradle.api.tasks.IgnoreEmptyDirectories;
|
||||
import org.gradle.api.tasks.Input;
|
||||
import org.gradle.api.tasks.InputFiles;
|
||||
import org.gradle.api.tasks.OutputDirectory;
|
||||
import org.gradle.api.tasks.PathSensitive;
|
||||
import org.gradle.api.tasks.PathSensitivity;
|
||||
import org.gradle.api.tasks.SkipWhenEmpty;
|
||||
import org.gradle.api.tasks.SourceSet;
|
||||
import org.gradle.api.tasks.TaskAction;
|
||||
|
@ -112,8 +115,10 @@ public class CopyRestApiTask extends DefaultTask {
|
|||
return skipHasRestTestCheck;
|
||||
}
|
||||
|
||||
@IgnoreEmptyDirectories
|
||||
@SkipWhenEmpty
|
||||
@InputFiles
|
||||
@PathSensitive(PathSensitivity.RELATIVE)
|
||||
public FileTree getInputDir() {
|
||||
FileTree coreFileTree = null;
|
||||
boolean projectHasYamlRestTests = skipHasRestTestCheck || projectHasYamlRestTests();
|
||||
|
|
|
@ -43,9 +43,12 @@ import org.gradle.api.file.FileSystemOperations;
|
|||
import org.gradle.api.file.FileTree;
|
||||
import org.gradle.api.plugins.JavaPluginConvention;
|
||||
import org.gradle.api.provider.ListProperty;
|
||||
import org.gradle.api.tasks.IgnoreEmptyDirectories;
|
||||
import org.gradle.api.tasks.Input;
|
||||
import org.gradle.api.tasks.InputFiles;
|
||||
import org.gradle.api.tasks.OutputDirectory;
|
||||
import org.gradle.api.tasks.PathSensitive;
|
||||
import org.gradle.api.tasks.PathSensitivity;
|
||||
import org.gradle.api.tasks.SkipWhenEmpty;
|
||||
import org.gradle.api.tasks.SourceSet;
|
||||
import org.gradle.api.tasks.TaskAction;
|
||||
|
@ -104,8 +107,10 @@ public class CopyRestTestsTask extends DefaultTask {
|
|||
return sourceSetName;
|
||||
}
|
||||
|
||||
@IgnoreEmptyDirectories
|
||||
@SkipWhenEmpty
|
||||
@InputFiles
|
||||
@PathSensitive(PathSensitivity.RELATIVE)
|
||||
public FileTree getInputDir() {
|
||||
FileTree coreFileTree = null;
|
||||
if (includeCore.get().isEmpty() == false) {
|
||||
|
|
|
@ -1 +1 @@
|
|||
6.6.1
|
||||
7.4.1
|
|
@ -7,6 +7,8 @@
|
|||
*/
|
||||
|
||||
import javax.annotation.Nullable
|
||||
import org.gradle.api.tasks.PathSensitive;
|
||||
import org.gradle.api.tasks.PathSensitivity;
|
||||
import org.gradle.internal.jvm.Jvm
|
||||
|
||||
/**
|
||||
|
@ -178,6 +180,8 @@ configure([
|
|||
class MissingJavadocTask extends DefaultTask {
|
||||
@InputFiles
|
||||
@SkipWhenEmpty
|
||||
@IgnoreEmptyDirectories
|
||||
@PathSensitive(PathSensitivity.RELATIVE)
|
||||
SourceDirectorySet srcDirSet;
|
||||
|
||||
@OutputDirectory
|
||||
|
|
Binary file not shown.
|
@ -11,7 +11,7 @@
|
|||
|
||||
distributionBase=GRADLE_USER_HOME
|
||||
distributionPath=wrapper/dists
|
||||
distributionUrl=https\://services.gradle.org/distributions/gradle-7.3.3-all.zip
|
||||
distributionUrl=https\://services.gradle.org/distributions/gradle-7.4.1-all.zip
|
||||
zipStoreBase=GRADLE_USER_HOME
|
||||
zipStorePath=wrapper/dists
|
||||
distributionSha256Sum=c9490e938b221daf0094982288e4038deed954a3f12fb54cbf270ddf4e37d879
|
||||
distributionSha256Sum=a9a7b7baba105f6557c9dcf9c3c6e8f7e57e6b49889c5f1d133f015d0727e4be
|
||||
|
|
Loading…
Reference in New Issue