[Rename] refactor the gradle directory. (#276)
Refactor the `gradle` directory as part of the renaming to OpenSearch work. Signed-off-by: Rabi Panda <adnapibar@gmail.com>
This commit is contained in:
parent
fafa4fc941
commit
e81ecda4d3
|
@ -1,5 +1,5 @@
|
|||
import org.elasticsearch.gradle.OS
|
||||
import org.elasticsearch.gradle.info.BuildParams
|
||||
import org.opensearch.gradle.OS
|
||||
import org.opensearch.gradle.info.BuildParams
|
||||
import org.gradle.initialization.BuildRequestMetaData
|
||||
|
||||
import java.util.concurrent.TimeUnit
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
import org.elasticsearch.gradle.Version
|
||||
import org.elasticsearch.gradle.info.BuildParams
|
||||
import org.opensearch.gradle.Version
|
||||
import org.opensearch.gradle.info.BuildParams
|
||||
|
||||
ext.bwcTaskName = { Version version ->
|
||||
return "v${version}#bwcTest"
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
import org.elasticsearch.gradle.ExportElasticsearchBuildResourcesTask
|
||||
import org.elasticsearch.gradle.info.BuildParams
|
||||
import org.elasticsearch.gradle.testclusters.ElasticsearchCluster
|
||||
import org.opensearch.gradle.ExportOpenSearchBuildResourcesTask
|
||||
import org.opensearch.gradle.info.BuildParams
|
||||
import org.opensearch.gradle.testclusters.OpenSearchCluster
|
||||
|
||||
// Common config when running with a FIPS-140 runtime JVM
|
||||
if (BuildParams.inFipsJvm) {
|
||||
|
@ -29,7 +29,7 @@ if (BuildParams.inFipsJvm) {
|
|||
def bcTlsFips = dependencies.create('org.bouncycastle:bctls-fips:1.0.9')
|
||||
|
||||
pluginManager.withPlugin('java') {
|
||||
TaskProvider<ExportElasticsearchBuildResourcesTask> fipsResourcesTask = project.tasks.register('fipsResources', ExportElasticsearchBuildResourcesTask)
|
||||
TaskProvider<ExportOpenSearchBuildResourcesTask> fipsResourcesTask = project.tasks.register('fipsResources', ExportOpenSearchBuildResourcesTask)
|
||||
fipsResourcesTask.configure {
|
||||
outputDir = fipsResourcesDir
|
||||
copy fipsSecurity.name
|
||||
|
@ -46,7 +46,7 @@ if (BuildParams.inFipsJvm) {
|
|||
}
|
||||
}
|
||||
|
||||
pluginManager.withPlugin("elasticsearch.testclusters") {
|
||||
pluginManager.withPlugin("opensearch.testclusters") {
|
||||
afterEvaluate {
|
||||
// This afterEvaluate hooks is required to avoid deprecated configuration resolution
|
||||
// This configuration can be removed once system modules are available
|
||||
|
@ -61,9 +61,9 @@ if (BuildParams.inFipsJvm) {
|
|||
extraConfigFile "fips_java.security", fipsSecurity
|
||||
extraConfigFile "fips_java.policy", fipsPolicy
|
||||
extraConfigFile "cacerts.bcfks", fipsTrustStore
|
||||
systemProperty 'java.security.properties', '=${ES_PATH_CONF}/fips_java.security'
|
||||
systemProperty 'java.security.policy', '=${ES_PATH_CONF}/fips_java.policy'
|
||||
systemProperty 'javax.net.ssl.trustStore', '${ES_PATH_CONF}/cacerts.bcfks'
|
||||
systemProperty 'java.security.properties', '=${OPENSEARCH_PATH_CONF}/fips_java.security'
|
||||
systemProperty 'java.security.policy', '=${OPENSEARCH_PATH_CONF}/fips_java.policy'
|
||||
systemProperty 'javax.net.ssl.trustStore', '${OPENSEARCH_PATH_CONF}/cacerts.bcfks'
|
||||
systemProperty 'javax.net.ssl.trustStorePassword', 'password'
|
||||
systemProperty 'javax.net.ssl.keyStorePassword', 'password'
|
||||
systemProperty 'javax.net.ssl.keyStoreType', 'BCFKS'
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
|
||||
// we do not want any of these dependencies on the compilation classpath
|
||||
// because they could then be used within Elasticsearch
|
||||
// because they could then be used within OpenSearch
|
||||
List<String> FORBIDDEN_DEPENDENCIES = [
|
||||
'guava'
|
||||
]
|
||||
|
|
|
@ -17,7 +17,7 @@
|
|||
* under the License.
|
||||
*/
|
||||
|
||||
import org.elasticsearch.gradle.BuildPlugin
|
||||
import org.opensearch.gradle.BuildPlugin
|
||||
|
||||
/*
|
||||
* This script plugin configures formatting for Java source using Spotless
|
||||
|
@ -60,16 +60,16 @@ def projectPathsToExclude = [
|
|||
':example-plugins:rescore',
|
||||
':example-plugins:rest-handler',
|
||||
':example-plugins:script-expert-scoring',
|
||||
':libs:elasticsearch-cli',
|
||||
':libs:elasticsearch-core',
|
||||
':libs:elasticsearch-dissect',
|
||||
':libs:elasticsearch-geo',
|
||||
':libs:elasticsearch-grok',
|
||||
':libs:elasticsearch-nio',
|
||||
':libs:elasticsearch-plugin-classloader',
|
||||
':libs:elasticsearch-secure-sm',
|
||||
':libs:elasticsearch-ssl-config',
|
||||
':libs:elasticsearch-x-content',
|
||||
':libs:opensearch-cli',
|
||||
':libs:opensearch-core',
|
||||
':libs:opensearch-dissect',
|
||||
':libs:opensearch-geo',
|
||||
':libs:opensearch-grok',
|
||||
':libs:opensearch-nio',
|
||||
':libs:opensearch-plugin-classloader',
|
||||
':libs:opensearch-secure-sm',
|
||||
':libs:opensearch-ssl-config',
|
||||
':libs:opensearch-x-content',
|
||||
':modules:aggs-matrix-stats',
|
||||
':modules:analysis-common',
|
||||
':modules:ingest-common',
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
import org.elasticsearch.gradle.info.BuildParams
|
||||
import org.opensearch.gradle.info.BuildParams
|
||||
import org.jetbrains.gradle.ext.Remote
|
||||
import org.jetbrains.gradle.ext.JUnit
|
||||
|
||||
|
@ -78,12 +78,12 @@ if (System.getProperty('idea.active') == 'true') {
|
|||
scopes = ['x-pack': 'Elastic']
|
||||
profiles {
|
||||
Apache {
|
||||
keyword = 'Licensed to Elasticsearch under one or more contributor'
|
||||
keyword = 'Licensed to OpenSearch under one or more contributor'
|
||||
notice = '''\
|
||||
Licensed to Elasticsearch under one or more contributor
|
||||
Licensed to OpenSearch under one or more contributor
|
||||
license agreements. See the NOTICE file distributed with
|
||||
this work for additional information regarding copyright
|
||||
ownership. Elasticsearch licenses this file to you under
|
||||
ownership. OpenSearch licenses this file to you under
|
||||
the Apache License, Version 2.0 (the "License"); you may
|
||||
not use this file except in compliance with the License.
|
||||
You may obtain a copy of the License at
|
||||
|
|
|
@ -23,11 +23,11 @@
|
|||
* The local distribution will be installed to
|
||||
* build/distributions/local
|
||||
* */
|
||||
import org.elasticsearch.gradle.Architecture
|
||||
import org.opensearch.gradle.Architecture
|
||||
|
||||
apply plugin:'elasticsearch.internal-distribution-download'
|
||||
apply plugin:'opensearch.internal-distribution-download'
|
||||
|
||||
elasticsearch_distributions {
|
||||
opensearch_distributions {
|
||||
local {
|
||||
type = 'archive'
|
||||
architecture = Architecture.current()
|
||||
|
@ -35,9 +35,9 @@ elasticsearch_distributions {
|
|||
}
|
||||
|
||||
tasks.register('localDistro', Sync) {
|
||||
from(elasticsearch_distributions.local.extracted)
|
||||
from(opensearch_distributions.local.extracted)
|
||||
into("build/distribution/local")
|
||||
doLast {
|
||||
logger.lifecycle("Elasticsearch distribution installed to ${destinationDir}.")
|
||||
logger.lifecycle("OpenSearch distribution installed to ${destinationDir}.")
|
||||
}
|
||||
}
|
||||
|
|
|
@ -16,9 +16,9 @@
|
|||
* specific language governing permissions and limitations
|
||||
* under the License.
|
||||
*/
|
||||
import org.elasticsearch.gradle.testclusters.RunTask
|
||||
import org.opensearch.gradle.testclusters.RunTask
|
||||
|
||||
apply plugin: 'elasticsearch.testclusters'
|
||||
apply plugin: 'opensearch.testclusters'
|
||||
|
||||
testClusters {
|
||||
runTask {
|
||||
|
@ -28,7 +28,7 @@ testClusters {
|
|||
|
||||
tasks.register("run", RunTask) {
|
||||
useCluster testClusters.runTask;
|
||||
description = 'Runs elasticsearch in the foreground'
|
||||
description = 'Runs opensearch in the foreground'
|
||||
group = 'Verification'
|
||||
|
||||
impliesSubProjects = true
|
||||
|
|
|
@ -1,9 +1,9 @@
|
|||
import org.elasticsearch.gradle.Architecture
|
||||
import org.elasticsearch.gradle.OS
|
||||
import org.elasticsearch.gradle.VersionProperties
|
||||
import org.elasticsearch.gradle.info.BuildParams
|
||||
import org.opensearch.gradle.Architecture
|
||||
import org.opensearch.gradle.OS
|
||||
import org.opensearch.gradle.VersionProperties
|
||||
import org.opensearch.gradle.info.BuildParams
|
||||
|
||||
apply plugin: 'elasticsearch.jdk-download'
|
||||
apply plugin: 'opensearch.jdk-download'
|
||||
|
||||
if (BuildParams.getIsRuntimeJavaHomeSet()) {
|
||||
configure(allprojects - project(':build-tools')) {
|
||||
|
|
Loading…
Reference in New Issue