[Rename] Fix gradle build as part of the renaming process. (#397)
This commit fixes the currently broken gradle build resulted from the renaming work. It reverts a few dependencies and comments out the `opensearch_distibutions` task which is currently failing for some builds. We will address these separately in the future once we have a working build. Signed-off-by: Rabi Panda <adnapibar@gmail.com>
This commit is contained in:
parent
236de25ffb
commit
df11cc9de4
32
build.gradle
32
build.gradle
|
@ -21,21 +21,21 @@ import com.avast.gradle.dockercompose.tasks.ComposePull
|
|||
import com.github.jengelman.gradle.plugins.shadow.ShadowPlugin
|
||||
import de.thetaphi.forbiddenapis.gradle.ForbiddenApisPlugin
|
||||
import org.apache.tools.ant.taskdefs.condition.Os
|
||||
import org.elasticsearch.gradle.BuildPlugin
|
||||
import org.elasticsearch.gradle.Version
|
||||
import org.elasticsearch.gradle.VersionProperties
|
||||
import org.elasticsearch.gradle.info.BuildParams
|
||||
import org.elasticsearch.gradle.plugin.PluginBuildPlugin
|
||||
import org.opensearch.gradle.BuildPlugin
|
||||
import org.opensearch.gradle.Version
|
||||
import org.opensearch.gradle.VersionProperties
|
||||
import org.opensearch.gradle.info.BuildParams
|
||||
import org.opensearch.gradle.plugin.PluginBuildPlugin
|
||||
import org.gradle.plugins.ide.eclipse.model.AccessRule
|
||||
import org.gradle.plugins.ide.eclipse.model.SourceFolder
|
||||
import org.gradle.util.DistributionLocator
|
||||
import org.gradle.util.GradleVersion
|
||||
import static org.elasticsearch.gradle.util.GradleUtils.maybeConfigure
|
||||
import static org.opensearch.gradle.util.GradleUtils.maybeConfigure
|
||||
|
||||
plugins {
|
||||
id 'lifecycle-base'
|
||||
id 'elasticsearch.docker-support'
|
||||
id 'elasticsearch.global-build-info'
|
||||
id 'opensearch.docker-support'
|
||||
id 'opensearch.global-build-info'
|
||||
id "com.diffplug.spotless" version "5.6.1" apply false
|
||||
}
|
||||
|
||||
|
@ -50,14 +50,14 @@ apply from: 'gradle/run.gradle'
|
|||
|
||||
// common maven publishing configuration
|
||||
allprojects {
|
||||
group = 'org.elasticsearch'
|
||||
version = VersionProperties.elasticsearch
|
||||
description = "Elasticsearch subproject ${project.path}"
|
||||
group = 'org.opensearch'
|
||||
version = VersionProperties.getOpenSearch()
|
||||
description = "OpenSearch subproject ${project.path}"
|
||||
}
|
||||
|
||||
configure(allprojects - project(':distribution:archives:integ-test-zip')) {
|
||||
project.pluginManager.withPlugin('nebula.maven-base-publish') {
|
||||
if (project.pluginManager.hasPlugin('elasticsearch.build') == false) {
|
||||
if (project.pluginManager.hasPlugin('opensearch.build') == false) {
|
||||
throw new GradleException("Project ${path} publishes a pom but doesn't apply the build plugin.")
|
||||
}
|
||||
}
|
||||
|
@ -219,11 +219,11 @@ allprojects {
|
|||
|
||||
project.afterEvaluate {
|
||||
// Handle javadoc dependencies across projects. Order matters: the linksOffline for
|
||||
// org.elasticsearch:elasticsearch must be the last one or all the links for the
|
||||
// other packages (e.g org.elasticsearch.client) will point to server rather than
|
||||
// org.opensearch:opensearch must be the last one or all the links for the
|
||||
// other packages (e.g org.opensearch.client) will point to server rather than
|
||||
// their own artifacts.
|
||||
if (project.plugins.hasPlugin(BuildPlugin) || project.plugins.hasPlugin(PluginBuildPlugin)) {
|
||||
String artifactsHost = VersionProperties.elasticsearch.endsWith("-SNAPSHOT") ? "https://snapshots.elastic.co" : "https://artifacts.elastic.co"
|
||||
String artifactsHost = VersionProperties.getOpenSearch().endsWith("-SNAPSHOT") ? "https://snapshots.elastic.co" : "https://artifacts.elastic.co"
|
||||
Closure sortClosure = { a, b -> b.group <=> a.group }
|
||||
Closure depJavadocClosure = { shadowed, dep ->
|
||||
if ((dep instanceof ProjectDependency) == false) {
|
||||
|
@ -416,7 +416,7 @@ gradle.projectsEvaluated {
|
|||
}
|
||||
|
||||
allprojects {
|
||||
tasks.register('resolveAllDependencies', org.elasticsearch.gradle.ResolveAllDependencies) {
|
||||
tasks.register('resolveAllDependencies', org.opensearch.gradle.ResolveAllDependencies) {
|
||||
configs = project.configurations
|
||||
if (project.path.contains("fixture")) {
|
||||
dependsOn tasks.withType(ComposePull)
|
||||
|
|
|
@ -47,8 +47,8 @@ class DocsTestPlugin implements Plugin<Project> {
|
|||
* the values may differ. In particular {version} needs to resolve
|
||||
* to the version being built for testing but needs to resolve to
|
||||
* the last released version for docs. */
|
||||
'\\{version\\}': Version.fromString(VersionProperties.opensearch).toString(),
|
||||
'\\{version_qualified\\}': VersionProperties.opensearch,
|
||||
'\\{version\\}': Version.fromString(VersionProperties.getOpenSearch()).toString(),
|
||||
'\\{version_qualified\\}': VersionProperties.getOpenSearch(),
|
||||
'\\{lucene_version\\}' : VersionProperties.lucene.replaceAll('-snapshot-\\w+$', ''),
|
||||
'\\{build_type\\}' : OS.conditionalString().onWindows({"zip"}).onUnix({"tar"}).supply(),
|
||||
]
|
||||
|
|
|
@ -48,7 +48,7 @@ import org.gradle.jvm.tasks.Jar
|
|||
*/
|
||||
class PluginBuildPlugin implements Plugin<Project> {
|
||||
|
||||
public static final String PLUGIN_EXTENSION_NAME = 'esplugin'
|
||||
public static final String PLUGIN_EXTENSION_NAME = 'opensearchplugin'
|
||||
|
||||
@Override
|
||||
void apply(Project project) {
|
||||
|
@ -79,20 +79,20 @@ class PluginBuildPlugin implements Plugin<Project> {
|
|||
project.description = extension1.description
|
||||
|
||||
if (extension1.name == null) {
|
||||
throw new InvalidUserDataException('name is a required setting for esplugin')
|
||||
throw new InvalidUserDataException('name is a required setting for opensearchplugin')
|
||||
}
|
||||
if (extension1.description == null) {
|
||||
throw new InvalidUserDataException('description is a required setting for esplugin')
|
||||
throw new InvalidUserDataException('description is a required setting for opensearchplugin')
|
||||
}
|
||||
if (extension1.classname == null) {
|
||||
throw new InvalidUserDataException('classname is a required setting for esplugin')
|
||||
throw new InvalidUserDataException('classname is a required setting for opensearchplugin')
|
||||
}
|
||||
|
||||
Map<String, String> properties = [
|
||||
'name' : extension1.name,
|
||||
'description' : extension1.description,
|
||||
'version' : extension1.version,
|
||||
'opensearchVersion': Version.fromString(VersionProperties.opensearch).toString(),
|
||||
'opensearchVersion': Version.fromString(VersionProperties.getOpenSearch()).toString(),
|
||||
'javaVersion' : project.targetCompatibility as String,
|
||||
'classname' : extension1.classname,
|
||||
'extendedPlugins' : extension1.extendedPlugins.join(','),
|
||||
|
@ -164,7 +164,7 @@ class PluginBuildPlugin implements Plugin<Project> {
|
|||
compileOnly "org.locationtech.jts:jts-core:${project.versions.jts}"
|
||||
compileOnly "org.apache.logging.log4j:log4j-api:${project.versions.log4j}"
|
||||
compileOnly "org.apache.logging.log4j:log4j-core:${project.versions.log4j}"
|
||||
compileOnly "org.opensearch:jna:${project.versions.jna}"
|
||||
compileOnly "org.elasticsearch:jna:${project.versions.jna}"
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -236,7 +236,7 @@ class ClusterConfiguration {
|
|||
plugins.put(name, mavenCoords)
|
||||
}
|
||||
|
||||
/** Add a module to the cluster. The project must be an esplugin and have a single zip default artifact. */
|
||||
/** Add a module to the cluster. The project must be an opensearchplugin and have a single zip default artifact. */
|
||||
@Input
|
||||
void module(Project moduleProject) {
|
||||
modules.add(moduleProject)
|
||||
|
|
|
@ -93,7 +93,7 @@ class ClusterFormationTasks {
|
|||
if (System.getProperty('tests.distribution', 'oss') == 'integ-test-zip') {
|
||||
throw new Exception("tests.distribution=integ-test-zip is not supported")
|
||||
}
|
||||
configureDistributionDependency(project, config.distribution, currentDistro, VersionProperties.opensearch)
|
||||
configureDistributionDependency(project, config.distribution, currentDistro, VersionProperties.getOpenSearch())
|
||||
boolean hasBwcNodes = config.numBwcNodes > 0
|
||||
if (hasBwcNodes) {
|
||||
if (config.bwcVersion == null) {
|
||||
|
@ -123,7 +123,7 @@ class ClusterFormationTasks {
|
|||
}
|
||||
distro = bwcDistro
|
||||
} else {
|
||||
opensearchVersion = VersionProperties.opensearch
|
||||
opensearchVersion = VersionProperties.getOpenSearch()
|
||||
distro = currentDistro
|
||||
}
|
||||
NodeInfo node = new NodeInfo(config, i, project, prefix, opensearchVersion, sharedDir)
|
||||
|
@ -218,7 +218,7 @@ class ClusterFormationTasks {
|
|||
dependency = project.dependencies.project(
|
||||
path: unreleasedInfo.gradleProjectPath, configuration: snapshotProject
|
||||
)
|
||||
} else if (internalBuild && opensearchVersion.equals(VersionProperties.opensearch)) {
|
||||
} else if (internalBuild && opensearchVersion.equals(VersionProperties.getOpenSearch())) {
|
||||
dependency = project.dependencies.project(path: ":distribution:archives:${snapshotProject}")
|
||||
} else {
|
||||
if (version.before('7.0.0')) {
|
||||
|
@ -282,7 +282,7 @@ class ClusterFormationTasks {
|
|||
setup = configureAddKeystoreFileTasks(prefix, project, setup, node)
|
||||
|
||||
if (node.config.plugins.isEmpty() == false) {
|
||||
if (node.nodeVersion == Version.fromString(VersionProperties.opensearch)) {
|
||||
if (node.nodeVersion == Version.fromString(VersionProperties.getOpenSearch())) {
|
||||
setup = configureCopyPluginsTask(taskName(prefix, node, 'copyPlugins'), project, setup, node, prefix)
|
||||
} else {
|
||||
setup = configureCopyBwcPluginsTask(taskName(prefix, node, 'copyBwcPlugins'), project, setup, node, prefix)
|
||||
|
@ -629,7 +629,7 @@ class ClusterFormationTasks {
|
|||
return setup
|
||||
}
|
||||
if (module.plugins.hasPlugin(PluginBuildPlugin) == false) {
|
||||
throw new GradleException("Task ${name} cannot include module ${module.path} which is not an esplugin")
|
||||
throw new GradleException("Task ${name} cannot include module ${module.path} which is not an opensearchplugin")
|
||||
}
|
||||
Copy installModule = project.tasks.create(name, Copy.class)
|
||||
installModule.dependsOn(setup)
|
||||
|
@ -641,7 +641,7 @@ class ClusterFormationTasks {
|
|||
|
||||
static Task configureInstallPluginTask(String name, Project project, Task setup, NodeInfo node, String pluginName, String prefix) {
|
||||
FileCollection pluginZip;
|
||||
if (node.nodeVersion != Version.fromString(VersionProperties.opensearch)) {
|
||||
if (node.nodeVersion != Version.fromString(VersionProperties.getOpenSearch())) {
|
||||
pluginZip = project.configurations.getByName(pluginBwcConfigurationName(prefix, pluginName))
|
||||
} else {
|
||||
pluginZip = project.configurations.getByName(pluginConfigurationName(prefix, pluginName))
|
||||
|
@ -986,13 +986,13 @@ class ClusterFormationTasks {
|
|||
static void verifyProjectHasBuildPlugin(String name, Version version, Project project, Project pluginProject) {
|
||||
if (pluginProject.plugins.hasPlugin(PluginBuildPlugin) == false) {
|
||||
throw new GradleException("Task [${name}] cannot add plugin [${pluginProject.path}] with version [${version}] to project's " +
|
||||
"[${project.path}] dependencies: the plugin is not an esplugin")
|
||||
"[${project.path}] dependencies: the plugin is not an opensearchplugin")
|
||||
}
|
||||
}
|
||||
|
||||
/** Find the plugin name in the given project. */
|
||||
static String findPluginName(Project pluginProject) {
|
||||
PluginPropertiesExtension extension = pluginProject.extensions.findByName('esplugin')
|
||||
PluginPropertiesExtension extension = pluginProject.extensions.findByName('opensearchplugin')
|
||||
return extension.name
|
||||
}
|
||||
|
||||
|
|
|
@ -126,7 +126,7 @@ class NodeInfo {
|
|||
baseDir = new File(project.buildDir, "cluster/${prefix} node${nodeNum}")
|
||||
pidFile = new File(baseDir, 'opensearch.pid')
|
||||
this.nodeVersion = Version.fromString(nodeVersion)
|
||||
this.isBwcNode = this.nodeVersion.before(VersionProperties.opensearch)
|
||||
this.isBwcNode = this.nodeVersion.before(VersionProperties.getOpenSearch())
|
||||
homeDir = new File(baseDir, "opensearch-${nodeVersion}")
|
||||
pathConf = new File(homeDir, 'config')
|
||||
if (config.dataDir != null) {
|
||||
|
|
|
@ -59,7 +59,7 @@ public class RestTestUtil {
|
|||
testTask.setTestClassesDirs(sourceSet.getOutput().getClassesDirs());
|
||||
testTask.setClasspath(sourceSet.getRuntimeClasspath());
|
||||
// if this a module or plugin, it may have an associated zip file with it's contents, add that to the test cluster
|
||||
project.getPluginManager().withPlugin("opensearch.esplugin", plugin -> {
|
||||
project.getPluginManager().withPlugin("opensearch.opensearchplugin", plugin -> {
|
||||
Zip bundle = (Zip) project.getTasks().getByName("bundlePlugin");
|
||||
testTask.dependsOn(bundle);
|
||||
if (project.getPath().contains("modules:")) {
|
||||
|
|
|
@ -39,8 +39,8 @@ dependencies {
|
|||
testImplementation "com.carrotsearch.randomizedtesting:randomizedtesting-runner:${versions.randomizedrunner}"
|
||||
testImplementation "junit:junit:${versions.junit}"
|
||||
testImplementation "org.hamcrest:hamcrest:${versions.hamcrest}"
|
||||
testImplementation "org.opensearch:securemock:${versions.securemock}"
|
||||
testImplementation "org.opensearch:mocksocket:${versions.mocksocket}"
|
||||
testImplementation "org.elasticsearch:securemock:${versions.securemock}"
|
||||
testImplementation "org.elasticsearch:mocksocket:${versions.mocksocket}"
|
||||
}
|
||||
|
||||
tasks.withType(CheckForbiddenApis).configureEach {
|
||||
|
|
|
@ -36,8 +36,8 @@ dependencies {
|
|||
testImplementation project(":client:test")
|
||||
testImplementation "com.carrotsearch.randomizedtesting:randomizedtesting-runner:${versions.randomizedrunner}"
|
||||
testImplementation "junit:junit:${versions.junit}"
|
||||
testImplementation "org.opensearch:securemock:${versions.securemock}"
|
||||
testImplementation "org.opensearch:mocksocket:${versions.mocksocket}"
|
||||
testImplementation "org.elasticsearch:securemock:${versions.securemock}"
|
||||
testImplementation "org.elasticsearch:mocksocket:${versions.mocksocket}"
|
||||
}
|
||||
|
||||
tasks.named('forbiddenApisMain').configure {
|
||||
|
|
|
@ -39,7 +39,7 @@ ext.expansions = { Architecture architecture, DockerBase base, boolean local ->
|
|||
classifier = "linux-\$(arch)"
|
||||
}
|
||||
|
||||
final String opensearch = "opensearch-oss-${VersionProperties.opensearch}-${classifier}.tar.gz"
|
||||
final String opensearch = "opensearch-oss-${VersionProperties.getOpenSearch()}-${classifier}.tar.gz"
|
||||
|
||||
/* Both the following Dockerfile commands put the resulting artifact at
|
||||
* the same location, regardless of classifier, so that the commands that
|
||||
|
@ -52,7 +52,7 @@ ext.expansions = { Architecture architecture, DockerBase base, boolean local ->
|
|||
//TODO - replace the URL for OpenSearch when available
|
||||
sourceOpenSearch = """
|
||||
RUN curl --retry 8 -S -L \\
|
||||
--output /opt/elasticsearch.tar.gz \\
|
||||
--output /opt/opensearch.tar.gz \\
|
||||
https://artifacts-no-kpi.elastic.co/downloads/elasticsearch/$elasticsearch
|
||||
"""
|
||||
}
|
||||
|
@ -65,7 +65,7 @@ RUN curl --retry 8 -S -L \\
|
|||
'package_manager' : 'yum',
|
||||
'source_opensearch' : sourceOpenSearch,
|
||||
'docker_base' : base.name().toLowerCase(),
|
||||
'version' : VersionProperties.opensearch
|
||||
'version' : VersionProperties.getOpenSearch()
|
||||
]
|
||||
}
|
||||
|
||||
|
@ -130,6 +130,7 @@ def createAndSetWritable(Object... locations) {
|
|||
}
|
||||
}
|
||||
|
||||
|
||||
opensearch_distributions {
|
||||
Architecture.values().each { eachArchitecture ->
|
||||
"docker${ eachArchitecture == Architecture.AARCH64 ? '_aarch64' : '' }" {
|
||||
|
@ -179,7 +180,7 @@ void addBuildDockerImage(Architecture architecture, DockerBase base) {
|
|||
dockerContext.fileProvider(copyContextTask.map { it.destinationDir })
|
||||
baseImages = [ base.getImage() ]
|
||||
|
||||
String version = VersionProperties.opensearch
|
||||
String version = VersionProperties.getOpenSearch()
|
||||
tags = [
|
||||
//TODO remove the tag and replace with OpenSearch docker tag
|
||||
"docker.elastic.co/elasticsearch/elasticsearch-oss:${version}",
|
||||
|
@ -226,7 +227,7 @@ subprojects { Project subProject ->
|
|||
|
||||
final String exportTaskName = taskName("export", architecture, base, "DockerImage")
|
||||
final String buildTaskName = taskName("build", architecture, base, "DockerImage")
|
||||
final String tarFile = "${parent.projectDir}/build/${artifactName}_${VersionProperties.opensearch}.${extension}"
|
||||
final String tarFile = "${parent.projectDir}/build/${artifactName}_${VersionProperties.getOpenSearch()}.${extension}"
|
||||
|
||||
tasks.register(exportTaskName, LoggedExec) {
|
||||
inputs.file("${parent.projectDir}/build/markers/${buildTaskName}.marker")
|
||||
|
|
|
@ -18,7 +18,7 @@
|
|||
*/
|
||||
apply plugin: 'opensearch.yaml-rest-test'
|
||||
|
||||
esplugin {
|
||||
opensearchplugin {
|
||||
description 'Adds aggregations whose input are a list of numeric fields and output includes a matrix.'
|
||||
classname 'org.opensearch.search.aggregations.matrix.MatrixAggregationPlugin'
|
||||
hasClientJar = true
|
||||
|
|
|
@ -19,7 +19,7 @@
|
|||
apply plugin: 'opensearch.yaml-rest-test'
|
||||
apply plugin: 'opensearch.internal-cluster-test'
|
||||
|
||||
esplugin {
|
||||
opensearchplugin {
|
||||
description 'Adds "built in" analyzers to OpenSearch.'
|
||||
classname 'org.opensearch.analysis.common.CommonAnalysisPlugin'
|
||||
extendedPlugins = ['lang-painless']
|
||||
|
|
|
@ -18,7 +18,7 @@
|
|||
*/
|
||||
apply plugin: 'opensearch.yaml-rest-test'
|
||||
|
||||
esplugin {
|
||||
opensearchplugin {
|
||||
description 'Placeholder plugin for geospatial features in OpenSearch. only registers geo_shape field mapper for now'
|
||||
classname 'org.opensearch.geo.GeoPlugin'
|
||||
}
|
||||
|
|
|
@ -19,7 +19,7 @@
|
|||
apply plugin: 'opensearch.yaml-rest-test'
|
||||
apply plugin: 'opensearch.internal-cluster-test'
|
||||
|
||||
esplugin {
|
||||
opensearchplugin {
|
||||
description 'Module for ingest processors that do not require additional security permissions or have large dependencies and resources'
|
||||
classname 'org.opensearch.ingest.common.IngestCommonPlugin'
|
||||
extendedPlugins = ['lang-painless']
|
||||
|
|
|
@ -22,7 +22,7 @@ import org.apache.tools.ant.taskdefs.condition.Os
|
|||
apply plugin: 'opensearch.yaml-rest-test'
|
||||
apply plugin: 'opensearch.internal-cluster-test'
|
||||
|
||||
esplugin {
|
||||
opensearchplugin {
|
||||
description 'Ingest processor that uses looksup geo data based on ip adresses using the Maxmind geo database'
|
||||
classname 'org.opensearch.ingest.geoip.IngestGeoIpPlugin'
|
||||
}
|
||||
|
@ -34,7 +34,7 @@ dependencies {
|
|||
api("com.fasterxml.jackson.core:jackson-databind:${versions.jackson}")
|
||||
api('com.maxmind.db:maxmind-db:1.3.1')
|
||||
|
||||
testImplementation 'org.opensearch:geolite2-databases:20191119'
|
||||
testImplementation 'org.elasticsearch:geolite2-databases:20191119'
|
||||
}
|
||||
|
||||
restResources {
|
||||
|
|
|
@ -18,7 +18,7 @@
|
|||
*/
|
||||
apply plugin: 'opensearch.yaml-rest-test'
|
||||
|
||||
esplugin {
|
||||
opensearchplugin {
|
||||
description 'Ingest processor that extracts information from a user agent'
|
||||
classname 'org.opensearch.ingest.useragent.IngestUserAgentPlugin'
|
||||
}
|
||||
|
|
|
@ -19,7 +19,7 @@
|
|||
apply plugin: 'opensearch.yaml-rest-test'
|
||||
apply plugin: 'opensearch.internal-cluster-test'
|
||||
|
||||
esplugin {
|
||||
opensearchplugin {
|
||||
description 'Lucene expressions integration for OpenSearch'
|
||||
classname 'org.opensearch.script.expression.ExpressionPlugin'
|
||||
}
|
||||
|
|
|
@ -20,7 +20,7 @@ apply plugin: 'opensearch.yaml-rest-test'
|
|||
apply plugin: 'opensearch.java-rest-test'
|
||||
apply plugin: 'opensearch.internal-cluster-test'
|
||||
|
||||
esplugin {
|
||||
opensearchplugin {
|
||||
description 'Mustache scripting integration for OpenSearch'
|
||||
classname 'org.opensearch.script.mustache.MustachePlugin'
|
||||
hasClientJar = true // For the template apis and query
|
||||
|
|
|
@ -21,7 +21,7 @@ import org.opensearch.gradle.testclusters.DefaultTestClustersTask;
|
|||
apply plugin: 'opensearch.validate-rest-spec'
|
||||
apply plugin: 'opensearch.yaml-rest-test'
|
||||
|
||||
esplugin {
|
||||
opensearchplugin {
|
||||
description 'An easy, safe and fast scripting language for OpenSearch'
|
||||
classname 'org.opensearch.painless.PainlessPlugin'
|
||||
}
|
||||
|
|
|
@ -19,7 +19,7 @@
|
|||
apply plugin: 'opensearch.yaml-rest-test'
|
||||
apply plugin: 'opensearch.java-rest-test'
|
||||
|
||||
esplugin {
|
||||
opensearchplugin {
|
||||
description 'Adds advanced field mappers'
|
||||
classname 'org.opensearch.index.mapper.MapperExtrasPlugin'
|
||||
hasClientJar = true
|
||||
|
|
|
@ -18,7 +18,7 @@
|
|||
*/
|
||||
apply plugin: 'opensearch.java-rest-test'
|
||||
|
||||
esplugin {
|
||||
opensearchplugin {
|
||||
description 'Plugin exposing APIs for OpenSearch Dashboards system indices'
|
||||
classname 'org.opensearch.dashboards.OpenSearchDashboardsPlugin'
|
||||
}
|
||||
|
|
|
@ -19,7 +19,7 @@
|
|||
apply plugin: 'opensearch.yaml-rest-test'
|
||||
apply plugin: 'opensearch.internal-cluster-test'
|
||||
|
||||
esplugin {
|
||||
opensearchplugin {
|
||||
description 'This module adds the support parent-child queries and aggregations'
|
||||
classname 'org.opensearch.join.ParentJoinPlugin'
|
||||
hasClientJar = true
|
||||
|
|
|
@ -19,7 +19,7 @@
|
|||
apply plugin: 'opensearch.yaml-rest-test'
|
||||
apply plugin: 'opensearch.internal-cluster-test'
|
||||
|
||||
esplugin {
|
||||
opensearchplugin {
|
||||
description 'Percolator module adds capability to index queries and query these queries by specifying documents'
|
||||
classname 'org.opensearch.percolator.PercolatorPlugin'
|
||||
hasClientJar = true
|
||||
|
|
|
@ -19,7 +19,7 @@
|
|||
apply plugin: 'opensearch.yaml-rest-test'
|
||||
apply plugin: 'opensearch.internal-cluster-test'
|
||||
|
||||
esplugin {
|
||||
opensearchplugin {
|
||||
description 'The Rank Eval module adds APIs to evaluate ranking quality.'
|
||||
classname 'org.opensearch.index.rankeval.RankEvalPlugin'
|
||||
hasClientJar = true
|
||||
|
|
|
@ -28,7 +28,7 @@ apply plugin: 'opensearch.yaml-rest-test'
|
|||
apply plugin: 'opensearch.java-rest-test'
|
||||
apply plugin: 'opensearch.internal-cluster-test'
|
||||
|
||||
esplugin {
|
||||
opensearchplugin {
|
||||
description 'The Reindex module adds APIs to reindex from one index to another or update documents in place.'
|
||||
classname 'org.opensearch.index.reindex.ReindexPlugin'
|
||||
hasClientJar = true
|
||||
|
@ -90,7 +90,7 @@ configurations {
|
|||
}
|
||||
|
||||
dependencies {
|
||||
oldesFixture project(':test:fixtures:old-opensearch')
|
||||
oldesFixture project(':test:fixtures:old-elasticsearch')
|
||||
/* Right now we just test against the latest version of each major we expect
|
||||
* reindex-from-remote to work against. We could randomize the versions but
|
||||
* that doesn't seem worth it at this point. */
|
||||
|
|
|
@ -25,7 +25,7 @@ apply plugin: 'opensearch.yaml-rest-test'
|
|||
apply plugin: 'opensearch.internal-cluster-test'
|
||||
|
||||
|
||||
esplugin {
|
||||
opensearchplugin {
|
||||
description 'Module for URL repository'
|
||||
classname 'org.opensearch.plugin.repository.url.URLRepositoryPlugin'
|
||||
}
|
||||
|
|
|
@ -17,7 +17,7 @@
|
|||
* under the License.
|
||||
*/
|
||||
|
||||
esplugin {
|
||||
opensearchplugin {
|
||||
description 'Integrates OpenSearch with systemd'
|
||||
classname 'org.opensearch.systemd.SystemdPlugin'
|
||||
}
|
||||
|
|
|
@ -33,7 +33,7 @@ apply plugin: 'opensearch.internal-cluster-test'
|
|||
* fix the hack in the build framework that copies transport-netty4 into the integ test cluster
|
||||
* maybe figure out a way to run all tests from core with netty4/network?
|
||||
*/
|
||||
esplugin {
|
||||
opensearchplugin {
|
||||
description 'Netty 4 based transport implementation'
|
||||
classname 'org.opensearch.transport.Netty4Plugin'
|
||||
hasClientJar = true
|
||||
|
|
|
@ -19,7 +19,7 @@
|
|||
apply plugin: 'opensearch.yaml-rest-test'
|
||||
|
||||
opensearchplugin {
|
||||
description 'The Phonetic Analysis plugin integrates phonetic token filter analysis with elasticsearch.'
|
||||
description 'The Phonetic Analysis plugin integrates phonetic token filter analysis with opensearch.'
|
||||
classname 'org.opensearch.plugin.analysis.AnalysisPhoneticPlugin'
|
||||
}
|
||||
|
||||
|
|
|
@ -157,7 +157,7 @@ Set disabledIntegTestTaskNames = []
|
|||
|
||||
for (String integTestTaskName : ['integTestHa', 'integTestSecure', 'integTestSecureHa']) {
|
||||
task "${integTestTaskName}"(type: RestIntegTestTask) {
|
||||
description = "Runs rest tests against an elasticsearch cluster with HDFS."
|
||||
description = "Runs rest tests against an opensearch cluster with HDFS."
|
||||
dependsOn(project.bundlePlugin)
|
||||
|
||||
if (disabledIntegTestTaskNames.contains(integTestTaskName)) {
|
||||
|
|
|
@ -2,9 +2,9 @@ import org.opensearch.gradle.info.BuildParams
|
|||
import org.opensearch.gradle.util.GradleUtils
|
||||
|
||||
apply plugin: 'opensearch.java-rest-test'
|
||||
apply plugin: 'opensearch.esplugin'
|
||||
apply plugin: 'opensearch.opensearchplugin'
|
||||
|
||||
esplugin {
|
||||
opensearchplugin {
|
||||
description 'Die with dignity plugin'
|
||||
classname 'org.opensearch.DieWithDignityPlugin'
|
||||
}
|
||||
|
|
|
@ -18,7 +18,7 @@
|
|||
*/
|
||||
|
||||
plugins {
|
||||
id 'elasticsearch.distro-test'
|
||||
id 'opensearch.distro-test'
|
||||
}
|
||||
|
||||
dependencies {
|
||||
|
@ -35,7 +35,7 @@ dependencies {
|
|||
api "commons-codec:commons-codec:${versions.commonscodec}"
|
||||
api "commons-logging:commons-logging:${versions.commonslogging}"
|
||||
|
||||
api project(':libs:elasticsearch-core')
|
||||
api project(':libs:opensearch-core')
|
||||
|
||||
testImplementation "com.fasterxml.jackson.core:jackson-annotations:${versions.jackson}"
|
||||
testImplementation "com.fasterxml.jackson.core:jackson-core:${versions.jackson}"
|
||||
|
|
|
@ -31,7 +31,11 @@ dependencies {
|
|||
testImplementation project(':client:rest-high-level')
|
||||
}
|
||||
|
||||
elasticsearch_distributions {
|
||||
/**
|
||||
* TODO OpenSearch - this task is currently broken and temporarily commented out to
|
||||
* unblock the pre-commit.
|
||||
* Issue URL - https://github.com/opensearch-project/OpenSearch/issues/400
|
||||
opensearch_distributions {
|
||||
docker {
|
||||
type = 'docker'
|
||||
architecture = Architecture.current()
|
||||
|
@ -41,7 +45,7 @@ elasticsearch_distributions {
|
|||
}
|
||||
|
||||
preProcessFixture {
|
||||
dependsOn elasticsearch_distributions.docker
|
||||
dependsOn opensearch_distributions.docker
|
||||
doLast {
|
||||
// tests expect to have an empty repo
|
||||
project.delete(
|
||||
|
@ -58,7 +62,7 @@ preProcessFixture {
|
|||
)
|
||||
}
|
||||
}
|
||||
|
||||
*/
|
||||
dockerCompose {
|
||||
tcpPortsToIgnoreWhenWaiting = [9600, 9601]
|
||||
useComposeFiles = ['docker-compose-oss.yml']
|
||||
|
|
|
@ -53,7 +53,11 @@ war {
|
|||
archiveFileName = 'example-app.war'
|
||||
}
|
||||
|
||||
elasticsearch_distributions {
|
||||
/**
|
||||
* TODO OpenSearch - this task is currently broken and temporarily commented out to
|
||||
* unblock the pre-commit.
|
||||
* Issue URL - https://github.com/opensearch-project/OpenSearch/issues/400
|
||||
opensearch_distributions {
|
||||
docker {
|
||||
type = 'docker'
|
||||
architecture = Architecture.current()
|
||||
|
@ -63,9 +67,9 @@ elasticsearch_distributions {
|
|||
}
|
||||
|
||||
preProcessFixture {
|
||||
dependsOn war, elasticsearch_distributions.docker
|
||||
dependsOn war, opensearch_distributions.docker
|
||||
}
|
||||
|
||||
*/
|
||||
dockerCompose {
|
||||
useComposeFiles = ['docker-compose-oss.yml']
|
||||
}
|
||||
|
|
|
@ -1,8 +1,8 @@
|
|||
apply plugin: 'elasticsearch.build'
|
||||
apply plugin: 'elasticsearch.publish'
|
||||
apply plugin: 'elasticsearch.rest-resources'
|
||||
apply plugin: 'elasticsearch.validate-rest-spec'
|
||||
apply plugin: 'elasticsearch.yaml-rest-test'
|
||||
apply plugin: 'opensearch.build'
|
||||
apply plugin: 'opensearch.publish'
|
||||
apply plugin: 'opensearch.rest-resources'
|
||||
apply plugin: 'opensearch.validate-rest-spec'
|
||||
apply plugin: 'opensearch.yaml-rest-test'
|
||||
|
||||
restResources {
|
||||
restTests {
|
||||
|
|
|
@ -121,7 +121,7 @@ dependencies {
|
|||
api "org.apache.logging.log4j:log4j-core:${versions.log4j}", optional
|
||||
|
||||
// repackaged jna with native bits linked against all supported platforms
|
||||
api "org.opensearch:jna:${versions.jna}"
|
||||
api "org.elasticsearch:jna:${versions.jna}"
|
||||
|
||||
testImplementation(project(":test:framework")) {
|
||||
// tests use the locally compiled version of server
|
||||
|
|
|
@ -2,7 +2,7 @@ plugins {
|
|||
id "com.gradle.enterprise" version "3.5"
|
||||
}
|
||||
|
||||
rootProject.name = "elasticsearch"
|
||||
rootProject.name = "OpenSearch"
|
||||
|
||||
List projects = [
|
||||
'build-tools',
|
||||
|
@ -103,14 +103,14 @@ project(':build-tools').projectDir = new File(rootProject.projectDir, 'buildSrc'
|
|||
project(':build-tools:reaper').projectDir = new File(rootProject.projectDir, 'buildSrc/reaper')
|
||||
|
||||
project(":libs").children.each { libsProject ->
|
||||
libsProject.name = "elasticsearch-${libsProject.name}"
|
||||
libsProject.name = "opensearch-${libsProject.name}"
|
||||
}
|
||||
|
||||
project(":test:external-modules").children.each { testProject ->
|
||||
testProject.name = "test-${testProject.name}"
|
||||
}
|
||||
|
||||
// look for extra plugins for elasticsearch
|
||||
// look for extra plugins for opensearch
|
||||
File extraProjects = new File(rootProject.projectDir.parentFile, "${rootProject.projectDir.name}-extra")
|
||||
if (extraProjects.exists()) {
|
||||
for (File extraProjectDir : extraProjects.listFiles()) {
|
||||
|
|
|
@ -1,11 +1,11 @@
|
|||
|
||||
import org.elasticsearch.gradle.info.BuildParams;
|
||||
import org.opensearch.gradle.info.BuildParams;
|
||||
|
||||
subprojects {
|
||||
apply plugin: 'opensearch.esplugin'
|
||||
apply plugin: 'opensearch.opensearchplugin'
|
||||
apply plugin: 'opensearch.yaml-rest-test'
|
||||
|
||||
esplugin {
|
||||
opensearchplugin {
|
||||
name it.name
|
||||
licenseFile rootProject.file('licenses/APACHE-LICENSE-2.0.txt')
|
||||
noticeFile rootProject.file('NOTICE.txt')
|
||||
|
|
|
@ -17,7 +17,7 @@
|
|||
* under the License.
|
||||
*/
|
||||
|
||||
esplugin {
|
||||
opensearchplugin {
|
||||
description 'A test module that allows to delay aggregations on shards with a configurable time'
|
||||
classname 'org.opensearch.search.aggregations.DelayedShardAggregationPlugin'
|
||||
}
|
||||
|
|
|
@ -34,8 +34,8 @@ dependencies {
|
|||
api "org.apache.lucene:lucene-codecs:${versions.lucene}"
|
||||
api "commons-logging:commons-logging:${versions.commonslogging}"
|
||||
api "commons-codec:commons-codec:${versions.commonscodec}"
|
||||
api "org.opensearch:securemock:${versions.securemock}"
|
||||
api "org.opensearch:mocksocket:${versions.mocksocket}"
|
||||
api "org.elasticsearch:securemock:${versions.securemock}"
|
||||
api "org.elasticsearch:mocksocket:${versions.mocksocket}"
|
||||
}
|
||||
|
||||
compileJava.options.compilerArgs << '-Xlint:-cast,-rawtypes,-unchecked'
|
||||
|
|
Loading…
Reference in New Issue