From 151de39aa23cccfce2c7a309302e700d12980889 Mon Sep 17 00:00:00 2001 From: Alpar Torok Date: Wed, 9 May 2018 14:29:21 +0300 Subject: [PATCH 1/2] Solve Gradle deprecation warnings around shadowJar - Apply workaround for: johnrengelman/shadow#336 - bump plugin to 2.0.4 Changes between 2.0.2 and 2.0.4 of the plugin: ``` 477db40 12 days ago john.engelman@target.com Release 2.0.4 3e3da37 3 weeks ago john.engelman@target.com Remove internal Gradle API and annotation internal getters on shadow jar. 31e2380 3 weeks ago john.engelman@target.com Close input streams. Closes #364 f712cc8 3 weeks ago john.engelman@target.com Upgrade ASM to 6.1.1 to address perf issues. Closes #374 2f94b2b 3 weeks ago john.engelman@target.com next version 23bbf3d 7 weeks ago john.r.engelman@gmail.com Add some gradle versions. Update changelog for 2.0.3 7435c74 7 weeks ago john.r.engelman@gmail.com Merge pull request #367 from ttsiebzehntt/366-java10 325c002 7 weeks ago info@martinsadowski.de Update ASM to 6.1 94550e5 3 months ago john.r.engelman@gmail.com Merge pull request #356 from sgnewson/update-file-to-files 66b691e 4 months ago john.r.engelman@gmail.com Merge pull request #358 from 3flex/patch-1 14761b1 4 months ago 3flex@users.noreply.github.com fix markdown for User Guide URL in issue template a3f6984 4 months ago newson@synopsys.com update inputs.file to inputs.files, to remove warning ``` closes #30389 --- benchmarks/build.gradle | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/benchmarks/build.gradle b/benchmarks/build.gradle index 1a1145a237a76..1d58a7cf4128f 100644 --- a/benchmarks/build.gradle +++ b/benchmarks/build.gradle @@ -24,22 +24,22 @@ buildscript { } } dependencies { - classpath 'com.github.jengelman.gradle.plugins:shadow:2.0.2' + classpath 'com.github.jengelman.gradle.plugins:shadow:2.0.4' } } apply plugin: 'elasticsearch.build' -// build an uberjar with all benchmarks -apply plugin: 'com.github.johnrengelman.shadow' -// have the shadow plugin provide the runShadow task -apply plugin: 'application' + +// needs to be set here see: https://github.com/johnrengelman/shadow/issues/336 +apply plugin: 'application' // have the shadow plugin provide the runShadow task +mainClassName = 'org.openjdk.jmh.Main' +apply plugin: 'com.github.johnrengelman.shadow' // build an uberjar with all benchmarks // Not published so no need to assemble tasks.remove(assemble) build.dependsOn.remove('assemble') archivesBaseName = 'elasticsearch-benchmarks' -mainClassName = 'org.openjdk.jmh.Main' test.enabled = false From 8f279d2859e8ea8e5213c4a33616ac3c99cc84e3 Mon Sep 17 00:00:00 2001 From: Alpar Torok Date: Thu, 10 May 2018 12:48:20 +0300 Subject: [PATCH 2/2] Improove comment as suggested --- benchmarks/build.gradle | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/benchmarks/build.gradle b/benchmarks/build.gradle index 1d58a7cf4128f..bd80deda89c6f 100644 --- a/benchmarks/build.gradle +++ b/benchmarks/build.gradle @@ -30,7 +30,7 @@ buildscript { apply plugin: 'elasticsearch.build' -// needs to be set here see: https://github.com/johnrengelman/shadow/issues/336 +// order of this seciont matters, see: https://github.com/johnrengelman/shadow/issues/336 apply plugin: 'application' // have the shadow plugin provide the runShadow task mainClassName = 'org.openjdk.jmh.Main' apply plugin: 'com.github.johnrengelman.shadow' // build an uberjar with all benchmarks