Skip to content

Commit 90ac928

Browse files
committed
Merge remote-tracking branch 'elastic/master' into pr/30708
* elastic/master: [DOCS] Removes out-dated x-pack/docs/en/index.asciidoc [DOCS] Removes redundant index.asciidoc files (elastic#30707) [TEST] Reduce forecast overflow to disk test memory limit (elastic#30727) Plugins: Remove meta plugins (elastic#30670) [DOCS] Moves X-Pack configurationg pages in table of contents (elastic#30702) TEST: Add engine log to testCorruptFileThenSnapshotAndRestore [ML][TEST] Fix bucket count assertion in ModelPlotsIT (elastic#30717) [ML][TEST] Make AutodetectMemoryLimitIT less fragile (elastic#30716) Default copy settings to true and deprecate on the REST layer (elastic#30598) [Build] Add test admin when starting gradle run with trial license and This implementation lazily (on 1st forecast request) checks for available diskspace and creates a subfolder for storing data outside of Lucene indexes, but as part of the ES data paths. Tests: Fail if test watches could not be triggered (elastic#30392) [ML] add version information in case of crash of native ML process (elastic#30674) Make TransportClusterStateAction abide to our style (elastic#30697) Change required version for Get Settings transport API changes to 6.4.0 (elastic#30706)
2 parents edbf548 + 8180e44 commit 90ac928

File tree

78 files changed

+775
-1828
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

78 files changed

+775
-1828
lines changed

TESTING.asciidoc

Lines changed: 40 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,46 @@ run it using Gradle:
2525
./gradlew run
2626
-------------------------------------
2727

28+
==== Launching and debugging from an IDE
29+
30+
If you want to run Elasticsearch from your IDE, the `./gradlew run` task
31+
supports a remote debugging option:
32+
33+
---------------------------------------------------------------------------
34+
./gradlew run --debug-jvm
35+
---------------------------------------------------------------------------
36+
37+
==== Distribution
38+
39+
By default a node is started with the zip distribution.
40+
In order to start with a different distribution use the `-Drun.distribution` argument.
41+
42+
To for example start the open source distribution:
43+
44+
-------------------------------------
45+
./gradlew run -Drun.distribution=oss-zip
46+
-------------------------------------
47+
48+
==== License type
49+
50+
By default a node is started with the `basic` license type.
51+
In order to start with a different license type use the `-Drun.license_type` argument.
52+
53+
In order to start a node with a trial license execute the following command:
54+
55+
-------------------------------------
56+
./gradlew run -Drun.license_type=trial
57+
-------------------------------------
58+
59+
This enables security and other paid features and adds a superuser with the username: `elastic-admin` and
60+
password: `elastic-password`.
61+
62+
==== Other useful arguments
63+
64+
In order to start a node with a different max heap space add: `-Dtests.heap.size=4G`
65+
In order to disable annotations add: `-Dtests.asserts=false`
66+
In order to set an Elasticsearch setting, provide a setting with the following prefix: `-Dtests.es.`
67+
2868
=== Test case filtering.
2969

3070
- `tests.class` is a class-filtering shell-like glob pattern,
@@ -572,15 +612,6 @@ as its build system. Since the switch to Gradle though, this is no longer possib
572612
the code currently used to build Elasticsearch does not allow JaCoCo to recognize its tests.
573613
For more information on this, see the discussion in https://github.com/elastic/elasticsearch/issues/28867[issue #28867].
574614

575-
== Launching and debugging from an IDE
576-
577-
If you want to run Elasticsearch from your IDE, the `./gradlew run` task
578-
supports a remote debugging option:
579-
580-
---------------------------------------------------------------------------
581-
./gradlew run --debug-jvm
582-
---------------------------------------------------------------------------
583-
584615
== Debugging remotely from an IDE
585616

586617
If you want to run Elasticsearch and be able to remotely attach the process

buildSrc/src/main/groovy/org/elasticsearch/gradle/plugin/MetaPluginBuildPlugin.groovy

Lines changed: 0 additions & 106 deletions
This file was deleted.

buildSrc/src/main/groovy/org/elasticsearch/gradle/plugin/MetaPluginPropertiesExtension.groovy

Lines changed: 0 additions & 46 deletions
This file was deleted.

buildSrc/src/main/groovy/org/elasticsearch/gradle/plugin/MetaPluginPropertiesTask.groovy

Lines changed: 0 additions & 68 deletions
This file was deleted.

buildSrc/src/main/groovy/org/elasticsearch/gradle/test/ClusterFormationTasks.groovy

Lines changed: 5 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ import org.elasticsearch.gradle.BuildPlugin
2424
import org.elasticsearch.gradle.LoggedExec
2525
import org.elasticsearch.gradle.Version
2626
import org.elasticsearch.gradle.VersionProperties
27-
import org.elasticsearch.gradle.plugin.MetaPluginBuildPlugin
27+
2828
import org.elasticsearch.gradle.plugin.PluginBuildPlugin
2929
import org.elasticsearch.gradle.plugin.PluginPropertiesExtension
3030
import org.gradle.api.AntBuilder
@@ -842,19 +842,15 @@ class ClusterFormationTasks {
842842
}
843843

844844
static void verifyProjectHasBuildPlugin(String name, Version version, Project project, Project pluginProject) {
845-
if (pluginProject.plugins.hasPlugin(PluginBuildPlugin) == false && pluginProject.plugins.hasPlugin(MetaPluginBuildPlugin) == false) {
845+
if (pluginProject.plugins.hasPlugin(PluginBuildPlugin) == false) {
846846
throw new GradleException("Task [${name}] cannot add plugin [${pluginProject.path}] with version [${version}] to project's " +
847-
"[${project.path}] dependencies: the plugin is not an esplugin or es_meta_plugin")
847+
"[${project.path}] dependencies: the plugin is not an esplugin")
848848
}
849849
}
850850

851-
/** Find the plugin name in the given project, whether a regular plugin or meta plugin. */
851+
/** Find the plugin name in the given project. */
852852
static String findPluginName(Project pluginProject) {
853853
PluginPropertiesExtension extension = pluginProject.extensions.findByName('esplugin')
854-
if (extension != null) {
855-
return extension.name
856-
} else {
857-
return pluginProject.extensions.findByName('es_meta_plugin').name
858-
}
854+
return extension.name
859855
}
860856
}

buildSrc/src/main/resources/META-INF/gradle-plugins/elasticsearch.es-meta-plugin.properties

Lines changed: 0 additions & 20 deletions
This file was deleted.

buildSrc/src/main/resources/meta-plugin-descriptor.properties

Lines changed: 0 additions & 20 deletions
This file was deleted.

client/rest-high-level/src/test/java/org/elasticsearch/client/IndicesClientIT.java

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -642,7 +642,12 @@ public void testShrink() throws IOException {
642642

643643
ResizeRequest resizeRequest = new ResizeRequest("target", "source");
644644
resizeRequest.setResizeType(ResizeType.SHRINK);
645-
Settings targetSettings = Settings.builder().put("index.number_of_shards", 2).put("index.number_of_replicas", 0).build();
645+
Settings targetSettings =
646+
Settings.builder()
647+
.put("index.number_of_shards", 2)
648+
.put("index.number_of_replicas", 0)
649+
.putNull("index.routing.allocation.require._name")
650+
.build();
646651
resizeRequest.setTargetIndex(new CreateIndexRequest("target").settings(targetSettings).alias(new Alias("alias")));
647652
ResizeResponse resizeResponse = highLevelClient().indices().shrink(resizeRequest);
648653
assertTrue(resizeResponse.isAcknowledged());

client/rest-high-level/src/test/java/org/elasticsearch/client/documentation/IndicesClientDocumentationIT.java

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1305,7 +1305,8 @@ public void testShrinkIndex() throws Exception {
13051305
// end::shrink-index-request-waitForActiveShards
13061306
// tag::shrink-index-request-settings
13071307
request.getTargetIndexRequest().settings(Settings.builder()
1308-
.put("index.number_of_shards", 2)); // <1>
1308+
.put("index.number_of_shards", 2) // <1>
1309+
.putNull("index.routing.allocation.require._name")); // <2>
13091310
// end::shrink-index-request-settings
13101311
// tag::shrink-index-request-aliases
13111312
request.getTargetIndexRequest().alias(new Alias("target_alias")); // <1>

0 commit comments

Comments
 (0)