forked from elastic/elasticsearch
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Update gradle wrapper to 7.4 (elastic#81963) (elastic#83886)
* Make ForbiddenApisPrecommitPlugin plugin Gradle 8.0 compatible * Fix deprecations on ignoring empty folders for task inputs * Update Gradle wrapper to 7.4 GA
- Loading branch information
Showing
13 changed files
with
229 additions
and
75 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
4 changes: 2 additions & 2 deletions
4
build-tools-internal/gradle/wrapper/gradle-wrapper.properties
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,6 @@ | ||
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-all.zip | ||
zipStoreBase=GRADLE_USER_HOME | ||
zipStorePath=wrapper/dists | ||
distributionSha256Sum=c9490e938b221daf0094982288e4038deed954a3f12fb54cbf270ddf4e37d879 | ||
distributionSha256Sum=cd5c2958a107ee7f0722004a12d0f8559b4564c34daad7df06cffd4d12a426d0 |
102 changes: 102 additions & 0 deletions
102
build-tools-internal/performance/elasticsearch-build-tool-update.scenarios
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,102 @@ | ||
# Can specify scenarios to use when none are specified on the command line | ||
default-scenarios = ["buildConfiguration_master", "buildConfiguration_branch", "single_project_master", "single_project_branch", "precommit_master", "precommit_branch"] | ||
|
||
buildConfiguration_branch { | ||
title = "configuration phase (@testGitCommit@)" | ||
tasks = ["help"] | ||
gradle-args = ["--no-scan", "--no-build-cache"] | ||
run-using = cli // value can be "cli" or "tooling-api" | ||
daemon = warm // value can be "warm", "cold", or "none" | ||
warm-ups = 5 | ||
iterations = 10 | ||
system-properties { | ||
"BUILD_PERFORMANCE_TEST" = "true" | ||
} | ||
git-checkout = { | ||
build = "@testGitCommit@" | ||
} | ||
} | ||
|
||
buildConfiguration_master { | ||
title = "configuration phase (master)" | ||
tasks = ["help"] | ||
gradle-args = ["--no-scan", "--no-build-cache"] | ||
run-using = cli // value can be "cli" or "tooling-api" | ||
daemon = warm // value can be "warm", "cold", or "none" | ||
warm-ups = 5 | ||
iterations = 10 | ||
system-properties { | ||
"BUILD_PERFORMANCE_TEST" = "true" | ||
} | ||
git-checkout = { | ||
build = "master" | ||
} | ||
} | ||
|
||
precommit_branch { | ||
title = "precommit (@testGitCommit@)" | ||
cleanup-tasks = ["clean"] | ||
tasks = ["precommit"] | ||
gradle-args = ["--no-scan", "--no-build-cache"] | ||
run-using = cli // value can be "cli" or "tooling-api" | ||
daemon = warm // value can be "warm", "cold", or "none" | ||
warm-ups = 5 | ||
iterations = 10 | ||
system-properties { | ||
"BUILD_PERFORMANCE_TEST" = "true" | ||
} | ||
git-checkout = { | ||
build = "@testGitCommit@" | ||
} | ||
} | ||
|
||
precommit_master { | ||
title = "precommit (master)" | ||
cleanup-tasks = ["clean"] | ||
tasks = ["precommit"] | ||
gradle-args = ["--no-scan", "--no-build-cache"] | ||
run-using = cli // value can be "cli" or "tooling-api" | ||
daemon = warm // value can be "warm", "cold", or "none" | ||
warm-ups = 5 | ||
iterations = 10 | ||
system-properties { | ||
"BUILD_PERFORMANCE_TEST" = "true" | ||
} | ||
git-checkout = { | ||
build = "master" | ||
} | ||
} | ||
|
||
single_project_branch { | ||
title = "single project (@testGitCommit@)" | ||
tasks = [":server:precommit"] | ||
gradle-args = ["--no-scan"] | ||
apply-abi-change-to = "server/src/main/java/org/elasticsearch/bootstrap/BootstrapInfo.java" | ||
run-using = cli // value can be "cli" or "tooling-api" | ||
daemon = warm // value can be "warm", "cold", or "none" | ||
warm-ups = 5 | ||
iterations = 10 | ||
system-properties { | ||
"BUILD_PERFORMANCE_TEST" = "true" | ||
} | ||
git-checkout = { | ||
build = "@testGitCommit@" | ||
} | ||
} | ||
|
||
single_project_master { | ||
title = "single project (master)" | ||
tasks = [":server:precommit"] | ||
gradle-args = ["--no-scan"] | ||
apply-abi-change-to = "server/src/main/java/org/elasticsearch/bootstrap/BootstrapInfo.java" | ||
run-using = cli // value can be "cli" or "tooling-api" | ||
daemon = warm // value can be "warm", "cold", or "none" | ||
warm-ups = 5 | ||
iterations = 10 | ||
system-properties { | ||
"BUILD_PERFORMANCE_TEST" = "true" | ||
} | ||
git-checkout = { | ||
build = "master" | ||
} | ||
} |
32 changes: 32 additions & 0 deletions
32
...nal/src/main/java/org/elasticsearch/gradle/internal/precommit/CheckForbiddenApisTask.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,32 @@ | ||
/* | ||
* Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one | ||
* or more contributor license agreements. Licensed under the Elastic License | ||
* 2.0 and the Server Side Public License, v 1; you may not use this file except | ||
* in compliance with, at your election, the Elastic License 2.0 or the Server | ||
* Side Public License, v 1. | ||
*/ | ||
|
||
package org.elasticsearch.gradle.internal.precommit; | ||
|
||
import de.thetaphi.forbiddenapis.gradle.CheckForbiddenApis; | ||
|
||
import org.gradle.api.file.FileTree; | ||
import org.gradle.api.tasks.IgnoreEmptyDirectories; | ||
|
||
/** | ||
* This implementation is used to fix gradle 8 compatibility of | ||
* the CheckForbiddenApis task which is built with gradle 4 support | ||
* in mind. | ||
* */ | ||
public class CheckForbiddenApisTask extends CheckForbiddenApis { | ||
|
||
/** | ||
* Add additional annotation to make this input gradle 8 compliant. | ||
* Otherwise we see a deprecation warning here starting with gradle 7.4 | ||
* */ | ||
@Override | ||
@IgnoreEmptyDirectories | ||
public FileTree getClassFiles() { | ||
return super.getClassFiles(); | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.