diff --git a/CHANGELOG.md b/CHANGELOG.md index 3fcab18..17f87fa 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,3 +1,6 @@ +## Unreleased +- Fix: update to Gradle 7 [#145](https://github.com/logstash-plugins/logstash-input-http/pull/145) + ## 3.4.2 - Docs: added `v8` as an acceptable value for `ecs_compatibility` [#142](https://github.com/logstash-plugins/logstash-input-http/pull/142) diff --git a/build.gradle b/build.gradle index 3de23f9..3e47eb3 100644 --- a/build.gradle +++ b/build.gradle @@ -18,12 +18,12 @@ repositories { } dependencies { - testCompile 'junit:junit:4.12' - testCompile 'org.hamcrest:hamcrest-library:1.3' - testCompile 'org.apache.logging.log4j:log4j-core:2.11.1' + testImplementation 'junit:junit:4.12' + testImplementation 'org.hamcrest:hamcrest-library:1.3' + testImplementation 'org.apache.logging.log4j:log4j-core:2.11.1' - compile 'io.netty:netty-all:4.1.65.Final' - compile 'org.apache.logging.log4j:log4j-api:2.11.1' + implementation 'io.netty:netty-all:4.1.65.Final' + implementation 'org.apache.logging.log4j:log4j-api:2.11.1' } test { @@ -33,13 +33,13 @@ test { } } -task run (type: JavaExec, dependsOn: classes){ +task run (type: JavaExec, dependsOn: classes) { // turn on or off ssl - if(project.hasProperty('providedargs')){ + if (project.hasProperty('providedargs')) { args(providedargs.split(',')) } description = "Plugin testing" - main = "org.logstash.plugins.input.http.Runner" + mainClass = "org.logstash.plugins.input.http.Runner" classpath = sourceSets.main.runtimeClasspath } @@ -49,7 +49,7 @@ task generateGemJarRequiresFile { jars_file.newWriter().withWriter { w -> w << "# AUTOGENERATED BY THE GRADLE SCRIPT. DO NOT EDIT.\n\n" w << "require \'jar_dependencies\'\n" - configurations.runtime.allDependencies.each { + configurations.runtimeClasspath.allDependencies.each { w << "require_jar(\'${it.group}\', \'${it.name}\', \'${it.version}\')\n" } w << "require_jar(\'${project.group}\', \'${project.name}\', \'${project.version}\')\n" @@ -60,8 +60,8 @@ task generateGemJarRequiresFile { task vendor { doLast { String vendorPathPrefix = "vendor/jar-dependencies" - configurations.runtime.allDependencies.each { dep -> - File f = configurations.runtime.filter { it.absolutePath.contains("${dep.group}/${dep.name}/${dep.version}") }.singleFile + configurations.runtimeClasspath.allDependencies.each { dep -> + File f = configurations.runtimeClasspath.filter { it.absolutePath.contains("${dep.group}/${dep.name}/${dep.version}") }.singleFile String groupPath = dep.group.replaceAll('\\.', '/') File newJarFile = file("${vendorPathPrefix}/${groupPath}/${dep.name}/${dep.version}/${dep.name}-${dep.version}.jar") newJarFile.mkdirs() diff --git a/gradle/wrapper/gradle-wrapper.properties b/gradle/wrapper/gradle-wrapper.properties index 5028f28..ffed3a2 100644 --- a/gradle/wrapper/gradle-wrapper.properties +++ b/gradle/wrapper/gradle-wrapper.properties @@ -1,5 +1,5 @@ distributionBase=GRADLE_USER_HOME distributionPath=wrapper/dists -distributionUrl=https\://services.gradle.org/distributions/gradle-5.6.4-bin.zip +distributionUrl=https\://services.gradle.org/distributions/gradle-7.2-bin.zip zipStoreBase=GRADLE_USER_HOME zipStorePath=wrapper/dists