Skip to content

Commit

Permalink
Merge remote-tracking branch 'elastic/master' into pr/30708
Browse files Browse the repository at this point in the history
* 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)
  • Loading branch information
jasontedor committed May 18, 2018
2 parents edbf548 + 8180e44 commit 90ac928
Show file tree
Hide file tree
Showing 78 changed files with 775 additions and 1,828 deletions.
49 changes: 40 additions & 9 deletions TESTING.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,46 @@ run it using Gradle:
./gradlew run
-------------------------------------

==== Launching and debugging from an IDE

If you want to run Elasticsearch from your IDE, the `./gradlew run` task
supports a remote debugging option:

---------------------------------------------------------------------------
./gradlew run --debug-jvm
---------------------------------------------------------------------------

==== Distribution

By default a node is started with the zip distribution.
In order to start with a different distribution use the `-Drun.distribution` argument.

To for example start the open source distribution:

-------------------------------------
./gradlew run -Drun.distribution=oss-zip
-------------------------------------

==== License type

By default a node is started with the `basic` license type.
In order to start with a different license type use the `-Drun.license_type` argument.

In order to start a node with a trial license execute the following command:

-------------------------------------
./gradlew run -Drun.license_type=trial
-------------------------------------

This enables security and other paid features and adds a superuser with the username: `elastic-admin` and
password: `elastic-password`.

==== Other useful arguments

In order to start a node with a different max heap space add: `-Dtests.heap.size=4G`
In order to disable annotations add: `-Dtests.asserts=false`
In order to set an Elasticsearch setting, provide a setting with the following prefix: `-Dtests.es.`

=== Test case filtering.

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

== Launching and debugging from an IDE

If you want to run Elasticsearch from your IDE, the `./gradlew run` task
supports a remote debugging option:

---------------------------------------------------------------------------
./gradlew run --debug-jvm
---------------------------------------------------------------------------

== Debugging remotely from an IDE

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

This file was deleted.

This file was deleted.

This file was deleted.

Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ import org.elasticsearch.gradle.BuildPlugin
import org.elasticsearch.gradle.LoggedExec
import org.elasticsearch.gradle.Version
import org.elasticsearch.gradle.VersionProperties
import org.elasticsearch.gradle.plugin.MetaPluginBuildPlugin

import org.elasticsearch.gradle.plugin.PluginBuildPlugin
import org.elasticsearch.gradle.plugin.PluginPropertiesExtension
import org.gradle.api.AntBuilder
Expand Down Expand Up @@ -842,19 +842,15 @@ class ClusterFormationTasks {
}

static void verifyProjectHasBuildPlugin(String name, Version version, Project project, Project pluginProject) {
if (pluginProject.plugins.hasPlugin(PluginBuildPlugin) == false && pluginProject.plugins.hasPlugin(MetaPluginBuildPlugin) == false) {
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 or es_meta_plugin")
"[${project.path}] dependencies: the plugin is not an esplugin")
}
}

/** Find the plugin name in the given project, whether a regular plugin or meta plugin. */
/** Find the plugin name in the given project. */
static String findPluginName(Project pluginProject) {
PluginPropertiesExtension extension = pluginProject.extensions.findByName('esplugin')
if (extension != null) {
return extension.name
} else {
return pluginProject.extensions.findByName('es_meta_plugin').name
}
return extension.name
}
}

This file was deleted.

20 changes: 0 additions & 20 deletions buildSrc/src/main/resources/meta-plugin-descriptor.properties

This file was deleted.

Original file line number Diff line number Diff line change
Expand Up @@ -642,7 +642,12 @@ public void testShrink() throws IOException {

ResizeRequest resizeRequest = new ResizeRequest("target", "source");
resizeRequest.setResizeType(ResizeType.SHRINK);
Settings targetSettings = Settings.builder().put("index.number_of_shards", 2).put("index.number_of_replicas", 0).build();
Settings targetSettings =
Settings.builder()
.put("index.number_of_shards", 2)
.put("index.number_of_replicas", 0)
.putNull("index.routing.allocation.require._name")
.build();
resizeRequest.setTargetIndex(new CreateIndexRequest("target").settings(targetSettings).alias(new Alias("alias")));
ResizeResponse resizeResponse = highLevelClient().indices().shrink(resizeRequest);
assertTrue(resizeResponse.isAcknowledged());
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -1305,7 +1305,8 @@ public void testShrinkIndex() throws Exception {
// end::shrink-index-request-waitForActiveShards
// tag::shrink-index-request-settings
request.getTargetIndexRequest().settings(Settings.builder()
.put("index.number_of_shards", 2)); // <1>
.put("index.number_of_shards", 2) // <1>
.putNull("index.routing.allocation.require._name")); // <2>
// end::shrink-index-request-settings
// tag::shrink-index-request-aliases
request.getTargetIndexRequest().alias(new Alias("target_alias")); // <1>
Expand Down
Loading

0 comments on commit 90ac928

Please sign in to comment.