Skip to content

Commit 2e27e0b

Browse files
committed
Merge branch 'ccr' into newSnapshotBetweenMinAndMaxSeqNo
* ccr: (110 commits) Use LF line endings in Painless generated files (elastic#26822) [DOCS] Added info about snapshotting your data before an upgrade. Add documentation about disabling `_field_names`. (elastic#26813) Remove UnsortedNumericDoubleValues (elastic#26817) Fix IndexOutOfBoundsException in histograms for NaN doubles (elastic#26787) (elastic#26856) [TEST] Added skipping the `headers` feature to the Bulk REST YAML test Update type-field.asciidoc Fix search_after with geo distance sorting (elastic#26891) Use proper logging placeholder for Netty logging Add Netty channel information on write and flush failure Remove deploying in JBoss documentation Document JVM option MaxFDLimit for macOS () Add additional low-level logging handler () Unwrap causes when maybe dying Change log level on write and flush failure to warn [TEST] add test to ensure legacy list syntax in yml works fine Bump BWC version for settings serialization to 6.1.0 Removed void token filter entries and added two tests Added Bengali Analyzer to Elasticsearch with respect to the lucene update(PR#238) Fix toString() in SnapshotStatus (elastic#26852) ...
2 parents 36e7702 + 3898919 commit 2e27e0b

File tree

430 files changed

+6027
-3531
lines changed

Some content is hidden

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

430 files changed

+6027
-3531
lines changed

CONTRIBUTING.md

Lines changed: 10 additions & 3 deletions

TESTING.asciidoc

Lines changed: 1 addition & 0 deletions

Vagrantfile

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -64,6 +64,10 @@ Vagrant.configure(2) do |config|
6464
config.vm.box = "elastic/fedora-25-x86_64"
6565
dnf_common config
6666
end
67+
config.vm.define "fedora-26" do |config|
68+
config.vm.box = "elastic/fedora-26-x86_64"
69+
dnf_common config
70+
end
6771
config.vm.define "opensuse-42" do |config|
6872
config.vm.box = "elastic/opensuse-42-x86_64"
6973
opensuse_common config

buildSrc/build.gradle

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -92,7 +92,7 @@ dependencies {
9292
compile 'com.netflix.nebula:gradle-info-plugin:3.0.3'
9393
compile 'org.eclipse.jgit:org.eclipse.jgit:3.2.0.201312181205-r'
9494
compile 'com.perforce:p4java:2012.3.551082' // THIS IS SUPPOSED TO BE OPTIONAL IN THE FUTURE....
95-
compile 'de.thetaphi:forbiddenapis:2.3'
95+
compile 'de.thetaphi:forbiddenapis:2.4.1'
9696
compile 'org.apache.rat:apache-rat:0.11'
9797
compile "org.elasticsearch:jna:4.4.0-1"
9898
}

buildSrc/src/main/groovy/org/elasticsearch/gradle/vagrant/VagrantTestPlugin.groovy

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,7 @@ class VagrantTestPlugin implements Plugin<Project> {
2020
'debian-8',
2121
'debian-9',
2222
'fedora-25',
23+
'fedora-26',
2324
'oel-6',
2425
'oel-7',
2526
'opensuse-42',

buildSrc/version.properties

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,14 @@
11
# When updating elasticsearch, please update 'rest' version in core/src/main/resources/org/elasticsearch/bootstrap/test-framework.policy
22
elasticsearch = 7.0.0-alpha1
3-
lucene = 7.0.0-snapshot-d94a5f0
3+
lucene = 7.1.0-snapshot-f33ed4ba12a
44

55
# optional dependencies
66
spatial4j = 0.6
77
jts = 1.13
88
jackson = 2.8.6
99
snakeyaml = 1.15
1010
# when updating log4j, please update also docs/java-api/index.asciidoc
11-
# when updating this version, please check if https://github.com/apache/logging-log4j2/pull/109 is released into the version that you are
12-
# bumping to; if it is, remove the assumeTrues in EvilLoggerTests
13-
log4j = 2.9.0
11+
log4j = 2.9.1
1412
slf4j = 1.6.2
1513

1614
# when updating the JNA version, also update the version in buildSrc/build.gradle

client/rest/src/test/java/org/elasticsearch/client/documentation/RestClientDocumentation.java

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -33,6 +33,8 @@
3333
import org.apache.http.impl.nio.reactor.IOReactorConfig;
3434
import org.apache.http.message.BasicHeader;
3535
import org.apache.http.nio.entity.NStringEntity;
36+
import org.apache.http.ssl.SSLContextBuilder;
37+
import org.apache.http.ssl.SSLContexts;
3638
import org.apache.http.util.EntityUtils;
3739
import org.elasticsearch.client.HttpAsyncResponseConsumerFactory;
3840
import org.elasticsearch.client.Response;
@@ -47,9 +49,6 @@
4749
import java.nio.file.Path;
4850
import java.nio.file.Paths;
4951
import java.security.KeyStore;
50-
import java.security.KeyStoreException;
51-
import java.security.NoSuchAlgorithmException;
52-
import java.security.cert.CertificateException;
5352
import java.util.Collections;
5453
import java.util.Map;
5554
import java.util.concurrent.CountDownLatch;
@@ -258,7 +257,7 @@ public void onFailure(Exception exception) {
258257
}
259258

260259
@SuppressWarnings("unused")
261-
public void testCommonConfiguration() throws IOException, KeyStoreException, CertificateException, NoSuchAlgorithmException {
260+
public void testCommonConfiguration() throws Exception {
262261
{
263262
//tag::rest-client-config-timeouts
264263
RestClientBuilder builder = RestClient.builder(new HttpHost("localhost", 9200))
@@ -318,13 +317,14 @@ public HttpAsyncClientBuilder customizeHttpClient(HttpAsyncClientBuilder httpCli
318317
{
319318
Path keyStorePath = Paths.get("");
320319
String keyStorePass = "";
321-
final SSLContext sslContext = null;
322320
//tag::rest-client-config-encrypted-communication
323-
KeyStore keystore = KeyStore.getInstance("jks");
321+
KeyStore truststore = KeyStore.getInstance("jks");
324322
try (InputStream is = Files.newInputStream(keyStorePath)) {
325-
keystore.load(is, keyStorePass.toCharArray());
323+
truststore.load(is, keyStorePass.toCharArray());
326324
}
327-
RestClientBuilder builder = RestClient.builder(new HttpHost("localhost", 9200))
325+
SSLContextBuilder sslBuilder = SSLContexts.custom().loadTrustMaterial(truststore, null);
326+
final SSLContext sslContext = sslBuilder.build();
327+
RestClientBuilder builder = RestClient.builder(new HttpHost("localhost", 9200, "https"))
328328
.setHttpClientConfigCallback(new RestClientBuilder.HttpClientConfigCallback() {
329329
@Override
330330
public HttpAsyncClientBuilder customizeHttpClient(HttpAsyncClientBuilder httpClientBuilder) {

core/licenses/log4j-1.2-api-2.9.0.jar.sha1

Lines changed: 0 additions & 1 deletion
This file was deleted.
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
894f96d677880d4ab834a1356f62b875e579caaa

core/licenses/log4j-api-2.9.0.jar.sha1

Lines changed: 0 additions & 1 deletion
This file was deleted.
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
7a2999229464e7a324aa503c0a52ec0f05efe7bd

core/licenses/log4j-core-2.9.0.jar.sha1

Lines changed: 0 additions & 1 deletion
This file was deleted.
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
c041978c686866ee8534f538c6220238db3bb6be

core/licenses/lucene-NOTICE.txt

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -54,13 +54,14 @@ The KStem stemmer in
5454
was developed by Bob Krovetz and Sergio Guzman-Lara (CIIR-UMass Amherst)
5555
under the BSD-license.
5656

57-
The Arabic,Persian,Romanian,Bulgarian, and Hindi analyzers (common) come with a default
57+
The Arabic,Persian,Romanian,Bulgarian, Hindi and Bengali analyzers (common) come with a default
5858
stopword list that is BSD-licensed created by Jacques Savoy. These files reside in:
5959
analysis/common/src/resources/org/apache/lucene/analysis/ar/stopwords.txt,
6060
analysis/common/src/resources/org/apache/lucene/analysis/fa/stopwords.txt,
6161
analysis/common/src/resources/org/apache/lucene/analysis/ro/stopwords.txt,
6262
analysis/common/src/resources/org/apache/lucene/analysis/bg/stopwords.txt,
63-
analysis/common/src/resources/org/apache/lucene/analysis/hi/stopwords.txt
63+
analysis/common/src/resources/org/apache/lucene/analysis/hi/stopwords.txt,
64+
analysis/common/src/resources/org/apache/lucene/analysis/bn/stopwords.txt
6465
See http://members.unine.ch/jacques.savoy/clef/index.html.
6566

6667
The German,Spanish,Finnish,French,Hungarian,Italian,Portuguese,Russian and Swedish light stemmers

core/licenses/lucene-analyzers-common-7.0.0-snapshot-d94a5f0.jar.sha1

Lines changed: 0 additions & 1 deletion
This file was deleted.
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
a59ac3bdd17becc848f319fb77994060661c2c71

core/licenses/lucene-backward-codecs-7.0.0-snapshot-d94a5f0.jar.sha1

Lines changed: 0 additions & 1 deletion
This file was deleted.
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
47f560086db8683b5be26911fae3721d8b0da465

core/licenses/lucene-core-7.0.0-snapshot-d94a5f0.jar.sha1

Lines changed: 0 additions & 1 deletion
This file was deleted.
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
17bd8e886ac2e763c27a507e697f78e43103afd3

core/licenses/lucene-grouping-7.0.0-snapshot-d94a5f0.jar.sha1

Lines changed: 0 additions & 1 deletion
This file was deleted.
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
bb7d5f5f6dd0bada3991828b8687a35c90de76ca

core/licenses/lucene-highlighter-7.0.0-snapshot-d94a5f0.jar.sha1

Lines changed: 0 additions & 1 deletion
This file was deleted.
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
f024368b33bfb7c1589aaf424992e474c4e3be38

core/licenses/lucene-join-7.0.0-snapshot-d94a5f0.jar.sha1

Lines changed: 0 additions & 1 deletion
This file was deleted.
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
7b525cb2e2c8403543fefc09b972c78b86d2f0da

core/licenses/lucene-memory-7.0.0-snapshot-d94a5f0.jar.sha1

Lines changed: 0 additions & 1 deletion
This file was deleted.
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
61cc3ced15fa80d8f97affe0c8df9818eeb8af49

core/licenses/lucene-misc-7.0.0-snapshot-d94a5f0.jar.sha1

Lines changed: 0 additions & 1 deletion
This file was deleted.
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
03a71b5875d25576c9f8992822db65fb181f4328

core/licenses/lucene-queries-7.0.0-snapshot-d94a5f0.jar.sha1

Lines changed: 0 additions & 1 deletion
This file was deleted.
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
9c07c15b2c6f8bd3d75e0f53fff5631f012bff98

core/licenses/lucene-queryparser-7.0.0-snapshot-d94a5f0.jar.sha1

Lines changed: 0 additions & 1 deletion
This file was deleted.
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
e0a7815981d096d96e7dc41b1c063cd78c91132d

core/licenses/lucene-sandbox-7.0.0-snapshot-d94a5f0.jar.sha1

Lines changed: 0 additions & 1 deletion
This file was deleted.
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
1ea14867a6bc545fb2e09dd1f31b48523cdbc040

core/licenses/lucene-spatial-7.0.0-snapshot-d94a5f0.jar.sha1

Lines changed: 0 additions & 1 deletion
This file was deleted.
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
58ce824ebc6126e37ff232c96a561a659377a873

core/licenses/lucene-spatial-extras-7.0.0-snapshot-d94a5f0.jar.sha1

Lines changed: 0 additions & 1 deletion
This file was deleted.
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
3fcd89a8cda5ee2049c189b06b5e30258b1aa198

core/licenses/lucene-spatial3d-7.0.0-snapshot-d94a5f0.jar.sha1

Lines changed: 0 additions & 1 deletion
This file was deleted.
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
1d1ada8fbb1b2bbbc88e9f29e28802a7b44a6665

core/licenses/lucene-suggest-7.0.0-snapshot-d94a5f0.jar.sha1

Lines changed: 0 additions & 1 deletion
This file was deleted.
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
fb7f18e6a81899e3ac95760b56bea21ebf143cf9

core/src/main/java/org/elasticsearch/Version.java

Lines changed: 13 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -93,11 +93,11 @@ public class Version implements Comparable<Version> {
9393
public static final int V_5_6_0_ID = 5060099;
9494
public static final Version V_5_6_0 = new Version(V_5_6_0_ID, org.apache.lucene.util.Version.LUCENE_6_6_0);
9595
public static final int V_5_6_1_ID = 5060199;
96-
// TODO use proper Lucene constant once we are on a Lucene snapshot that knows about 6.6.1
97-
public static final Version V_5_6_1 = new Version(V_5_6_1_ID, org.apache.lucene.util.Version.fromBits(6, 6, 1));
96+
public static final Version V_5_6_1 = new Version(V_5_6_1_ID, org.apache.lucene.util.Version.LUCENE_6_6_1);
9897
public static final int V_5_6_2_ID = 5060299;
99-
// TODO use proper Lucene constant once we are on a Lucene snapshot that knows about 6.6.1
100-
public static final Version V_5_6_2 = new Version(V_5_6_2_ID, org.apache.lucene.util.Version.fromBits(6, 6, 1));
98+
public static final Version V_5_6_2 = new Version(V_5_6_2_ID, org.apache.lucene.util.Version.LUCENE_6_6_1);
99+
public static final int V_5_6_3_ID = 5060399;
100+
public static final Version V_5_6_3 = new Version(V_5_6_3_ID, org.apache.lucene.util.Version.LUCENE_6_6_1);
101101
public static final int V_6_0_0_alpha1_ID = 6000001;
102102
public static final Version V_6_0_0_alpha1 =
103103
new Version(V_6_0_0_alpha1_ID, org.apache.lucene.util.Version.LUCENE_7_0_0);
@@ -113,12 +113,15 @@ public class Version implements Comparable<Version> {
113113
public static final int V_6_0_0_rc1_ID = 6000051;
114114
public static final Version V_6_0_0_rc1 =
115115
new Version(V_6_0_0_rc1_ID, org.apache.lucene.util.Version.LUCENE_7_0_0);
116+
public static final int V_6_0_0_rc2_ID = 6000052;
117+
public static final Version V_6_0_0_rc2 =
118+
new Version(V_6_0_0_rc2_ID, org.apache.lucene.util.Version.LUCENE_7_0_0);
116119
public static final int V_6_1_0_ID = 6010099;
117120
public static final Version V_6_1_0 =
118-
new Version(V_6_1_0_ID, org.apache.lucene.util.Version.LUCENE_7_0_0);
121+
new Version(V_6_1_0_ID, org.apache.lucene.util.Version.LUCENE_7_1_0);
119122
public static final int V_7_0_0_alpha1_ID = 7000001;
120123
public static final Version V_7_0_0_alpha1 =
121-
new Version(V_7_0_0_alpha1_ID, org.apache.lucene.util.Version.LUCENE_7_0_0);
124+
new Version(V_7_0_0_alpha1_ID, org.apache.lucene.util.Version.LUCENE_7_1_0);
122125
public static final Version CURRENT = V_7_0_0_alpha1;
123126

124127
// unreleased versions must be added to the above list with the suffix _UNRELEASED (with the exception of CURRENT)
@@ -138,6 +141,8 @@ public static Version fromId(int id) {
138141
return V_7_0_0_alpha1;
139142
case V_6_1_0_ID:
140143
return V_6_1_0;
144+
case V_6_0_0_rc2_ID:
145+
return V_6_0_0_rc2;
141146
case V_6_0_0_beta2_ID:
142147
return V_6_0_0_beta2;
143148
case V_6_0_0_rc1_ID:
@@ -148,6 +153,8 @@ public static Version fromId(int id) {
148153
return V_6_0_0_alpha2;
149154
case V_6_0_0_alpha1_ID:
150155
return V_6_0_0_alpha1;
156+
case V_5_6_3_ID:
157+
return V_5_6_3;
151158
case V_5_6_2_ID:
152159
return V_5_6_2;
153160
case V_5_6_1_ID:

core/src/main/java/org/elasticsearch/action/admin/cluster/snapshots/status/SnapshotStatus.java

Lines changed: 2 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -20,13 +20,12 @@
2020
package org.elasticsearch.action.admin.cluster.snapshots.status;
2121

2222
import org.elasticsearch.cluster.SnapshotsInProgress.State;
23+
import org.elasticsearch.common.Strings;
2324
import org.elasticsearch.common.io.stream.StreamInput;
2425
import org.elasticsearch.common.io.stream.StreamOutput;
2526
import org.elasticsearch.common.io.stream.Streamable;
26-
import org.elasticsearch.common.xcontent.ToXContent.Params;
2727
import org.elasticsearch.common.xcontent.ToXContentObject;
2828
import org.elasticsearch.common.xcontent.XContentBuilder;
29-
import org.elasticsearch.common.xcontent.XContentFactory;
3029
import org.elasticsearch.snapshots.Snapshot;
3130

3231
import java.io.IOException;
@@ -160,15 +159,7 @@ public static SnapshotStatus readSnapshotStatus(StreamInput in) throws IOExcepti
160159

161160
@Override
162161
public String toString() {
163-
try {
164-
XContentBuilder builder = XContentFactory.jsonBuilder().prettyPrint();
165-
builder.startObject();
166-
toXContent(builder, EMPTY_PARAMS);
167-
builder.endObject();
168-
return builder.string();
169-
} catch (IOException e) {
170-
return "{ \"error\" : \"" + e.getMessage() + "\"}";
171-
}
162+
return Strings.toString(this, true, false);
172163
}
173164

174165
/**

0 commit comments

Comments
 (0)