Skip to content

Commit 57ece57

Browse files
committed
Merge branch '6.x' into ccr-6.x
* 6.x: Refactor internal engine [Docs] Fix note in bucket_selector Added release notes for 6.0.0-rc2 [Docs] Fix indentation of examples (#27168) [Docs] Clarify `span_not` query behavior for non-overlapping matches (#27150) [Docs] Remove first person "I" from getting started (#27155)
2 parents 03225b4 + 39ef2c4 commit 57ece57

File tree

13 files changed

+575
-291
lines changed

13 files changed

+575
-291
lines changed

core/src/main/java/org/elasticsearch/index/engine/Engine.java

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -572,7 +572,11 @@ public CommitStats commitStats() {
572572
return new CommitStats(getLastCommittedSegmentInfos());
573573
}
574574

575-
/** get the sequence number service */
575+
/**
576+
* The sequence number service for this engine.
577+
*
578+
* @return the sequence number service
579+
*/
576580
public abstract SequenceNumbersService seqNoService();
577581

578582
/**

core/src/main/java/org/elasticsearch/index/engine/InternalEngine.java

Lines changed: 83 additions & 64 deletions
Large diffs are not rendered by default.

core/src/main/java/org/elasticsearch/index/seqno/SequenceNumbersService.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -66,7 +66,7 @@ public SequenceNumbersService(
6666
*
6767
* @return the next assigned sequence number
6868
*/
69-
public long generateSeqNo() {
69+
public final long generateSeqNo() {
7070
return localCheckpointTracker.generateSeqNo();
7171
}
7272

core/src/test/java/org/elasticsearch/index/engine/InternalEngineTests.java

Lines changed: 197 additions & 204 deletions
Large diffs are not rendered by default.

core/src/test/java/org/elasticsearch/index/replication/IndexLevelReplicationTests.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -316,7 +316,7 @@ public long addDocument(Iterable<? extends IndexableField> doc) throws IOExcepti
316316
assert documentFailureMessage != null;
317317
throw new IOException(documentFailureMessage);
318318
}
319-
}, null, config);
319+
}, null, null, config);
320320
}
321321
}
322322

core/src/test/java/org/elasticsearch/index/replication/RecoveryDuringReplicationTests.java

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -638,6 +638,7 @@ public long addDocument(final Iterable<? extends IndexableField> doc) throws IOE
638638
}
639639
},
640640
null,
641+
null,
641642
config);
642643
}
643644

docs/reference/aggregations/pipeline/bucket-selector-aggregation.asciidoc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ in the parent multi-bucket aggregation. The specified metric must be numeric and
66
If the script language is `expression` then a numeric return value is permitted. In this case 0.0 will be evaluated as `false`
77
and all other values will evaluate to true.
88

9-
Note: The bucket_selector aggregation, like all pipeline aggregations, executions after all other sibling aggregations. This means that
9+
NOTE: The bucket_selector aggregation, like all pipeline aggregations, executions after all other sibling aggregations. This means that
1010
using the bucket_selector aggregation to filter the returned buckets in the response does not save on execution time running the aggregations.
1111

1212
==== Syntax

docs/reference/getting-started.asciidoc

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ Here are a few sample use-cases that Elasticsearch could be used for:
1313
* You run a price alerting platform which allows price-savvy customers to specify a rule like "I am interested in buying a specific electronic gadget and I want to be notified if the price of gadget falls below $X from any vendor within the next month". In this case you can scrape vendor prices, push them into Elasticsearch and use its reverse-search (Percolator) capability to match price movements against customer queries and eventually push the alerts out to the customer once matches are found.
1414
* You have analytics/business-intelligence needs and want to quickly investigate, analyze, visualize, and ask ad-hoc questions on a lot of data (think millions or billions of records). In this case, you can use Elasticsearch to store your data and then use Kibana (part of the Elasticsearch/Logstash/Kibana stack) to build custom dashboards that can visualize aspects of your data that are important to you. Additionally, you can use the Elasticsearch aggregations functionality to perform complex business intelligence queries against your data.
1515

16-
For the rest of this tutorial, I will guide you through the process of getting Elasticsearch up and running, taking a peek inside it, and performing basic operations like indexing, searching, and modifying your data. At the end of this tutorial, you should have a good idea of what Elasticsearch is, how it works, and hopefully be inspired to see how you can use it to either build sophisticated search applications or to mine intelligence from your data.
16+
For the rest of this tutorial, you will be guided through the process of getting Elasticsearch up and running, taking a peek inside it, and performing basic operations like indexing, searching, and modifying your data. At the end of this tutorial, you should have a good idea of what Elasticsearch is, how it works, and hopefully be inspired to see how you can use it to either build sophisticated search applications or to mine intelligence from your data.
1717
--
1818

1919
== Basic Concepts
@@ -660,7 +660,7 @@ Now that we've gotten a glimpse of the basics, let's try to work on a more reali
660660
--------------------------------------------------
661661
// NOTCONSOLE
662662

663-
For the curious, I generated this data from http://www.json-generator.com/[`www.json-generator.com/`] so please ignore the actual values and semantics of the data as these are all randomly generated.
663+
For the curious, this data was generated using http://www.json-generator.com/[`www.json-generator.com/`], so please ignore the actual values and semantics of the data as these are all randomly generated.
664664

665665
[float]
666666
=== Loading the Sample Dataset
@@ -1284,4 +1284,4 @@ There are many other aggregations capabilities that we won't go into detail here
12841284

12851285
== Conclusion
12861286

1287-
Elasticsearch is both a simple and complex product. We've so far learned the basics of what it is, how to look inside of it, and how to work with it using some of the REST APIs. I hope that this tutorial has given you a better understanding of what Elasticsearch is and more importantly, inspired you to further experiment with the rest of its great features!
1287+
Elasticsearch is both a simple and complex product. We've so far learned the basics of what it is, how to look inside of it, and how to work with it using some of the REST APIs. Hopefully this tutorial has given you a better understanding of what Elasticsearch is and more importantly, inspired you to further experiment with the rest of its great features!

docs/reference/query-dsl/common-terms-query.asciidoc

Lines changed: 13 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -76,7 +76,7 @@ GET /_search
7676
"common": {
7777
"body": {
7878
"query": "this is bonsai cool",
79-
"cutoff_frequency": 0.001
79+
"cutoff_frequency": 0.001
8080
}
8181
}
8282
}
@@ -100,8 +100,8 @@ GET /_search
100100
"common": {
101101
"body": {
102102
"query": "nelly the elephant as a cartoon",
103-
"cutoff_frequency": 0.001,
104-
"low_freq_operator": "and"
103+
"cutoff_frequency": 0.001,
104+
"low_freq_operator": "and"
105105
}
106106
}
107107
}
@@ -200,11 +200,11 @@ GET /_search
200200
"common": {
201201
"body": {
202202
"query": "nelly the elephant not as a cartoon",
203-
"cutoff_frequency": 0.001,
204-
"minimum_should_match": {
205-
"low_freq" : 2,
206-
"high_freq" : 3
207-
}
203+
"cutoff_frequency": 0.001,
204+
"minimum_should_match": {
205+
"low_freq" : 2,
206+
"high_freq" : 3
207+
}
208208
}
209209
}
210210
}
@@ -261,11 +261,11 @@ GET /_search
261261
"common": {
262262
"body": {
263263
"query": "how not to be",
264-
"cutoff_frequency": 0.001,
265-
"minimum_should_match": {
266-
"low_freq" : 2,
267-
"high_freq" : 3
268-
}
264+
"cutoff_frequency": 0.001,
265+
"minimum_should_match": {
266+
"low_freq" : 2,
267+
"high_freq" : 3
268+
}
269269
}
270270
}
271271
}

docs/reference/query-dsl/span-not-query.asciidoc

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,9 @@
11
[[query-dsl-span-not-query]]
22
=== Span Not Query
33

4-
Removes matches which overlap with another span query. The span not
4+
Removes matches which overlap with another span query or which are
5+
within x tokens before (controlled by the parameter `pre`) or y tokens
6+
after (controled by the parameter `post`) another SpanQuery. The span not
57
query maps to Lucene `SpanNotQuery`. Here is an example:
68

79
[source,js]
@@ -39,7 +41,7 @@ In the above example all documents with the term hoya are filtered except the on
3941
Other top level options:
4042

4143
[horizontal]
42-
`pre`:: If set the amount of tokens before the include span can't have overlap with the exclude span.
43-
`post`:: If set the amount of tokens after the include span can't have overlap with the exclude span.
44+
`pre`:: If set the amount of tokens before the include span can't have overlap with the exclude span. Defaults to 0.
45+
`post`:: If set the amount of tokens after the include span can't have overlap with the exclude span. Defaults to 0.
4446
`dist`:: If set the amount of tokens from within the include span can't have overlap with the exclude span. Equivalent
4547
of setting both `pre` and `post`.

0 commit comments

Comments
 (0)