diff --git a/src/main/antora/modules/ROOT/pages/elasticsearch/template.adoc b/src/main/antora/modules/ROOT/pages/elasticsearch/template.adoc index 5d52b68f9..b893bb1a1 100644 --- a/src/main/antora/modules/ROOT/pages/elasticsearch/template.adoc +++ b/src/main/antora/modules/ROOT/pages/elasticsearch/template.adoc @@ -125,7 +125,7 @@ Almost all of the methods defined in the `SearchOperations` and `ReactiveSearchO === CriteriaQuery `CriteriaQuery` based queries allow the creation of queries to search for data without knowing the syntax or basics of Elasticsearch queries. -They allow the user to build queries by simply chaining and combining `Criteria` objects that specifiy the criteria the searched documents must fulfill. +They allow the user to build queries by simply chaining and combining `Criteria` objects that specify the criteria the searched documents must fulfill. NOTE: when talking about AND or OR when combining criteria keep in mind, that in Elasticsearch AND are converted to a **must** condition and OR to a **should** @@ -213,14 +213,14 @@ Using `StringQuery` may be appropriate if you already have an Elasticsearch quer `NativeQuery` is the class to use when you have a complex query, or a query that cannot be expressed by using the `Criteria` API, for example when building queries and using aggregates. It allows to use all the different `co.elastic.clients.elasticsearch._types.query_dsl.Query` implementations from the Elasticsearch library therefore named "native". -The following code shows how to search for persons with a given firstname and for the found documents have a terms aggregation that counts the number of occurences of the lastnames for these persons: +The following code shows how to search for persons with a given `firstName` and for the found documents have a terms aggregation that counts the number of occurrences of the `lastName` for these persons: ==== [source,java] ---- Query query = NativeQuery.builder() .withAggregation("lastNames", Aggregation.of(a -> a - .terms(ta -> ta.field("last-name").size(10)))) + .terms(ta -> ta.field("lastName").size(10)))) .withQuery(q -> q .match(m -> m .field("firstName") @@ -234,7 +234,7 @@ SearchHits searchHits = operations.search(query, Person.class); ---- ==== -[[elasticsearch.operations.searchtemplateScOp§query]] +[[elasticsearch.operations.searchtemplatequery]] === SearchTemplateQuery This is a special implementation of the `Query` interface to be used in combination with a stored search template. diff --git a/src/main/antora/modules/ROOT/pages/migration-guides/migration-guide-5.0-5.1.adoc b/src/main/antora/modules/ROOT/pages/migration-guides/migration-guide-5.0-5.1.adoc index 1ec6fe291..5ad1b3696 100644 --- a/src/main/antora/modules/ROOT/pages/migration-guides/migration-guide-5.0-5.1.adoc +++ b/src/main/antora/modules/ROOT/pages/migration-guides/migration-guide-5.0-5.1.adoc @@ -24,4 +24,4 @@ Adaptions are necessary when this enum was used at other places than as a proper The functions in the `IndexOperations` and `ReactiverIndexOperations` to manage index templates that were introduced in Spring Data Elasticsearch 4.1 have been deprecated. They were using the old Elasticsearch API that was deprecated in Elasticsearch version 7.8. -Please use the new functions that are based on the compsable index template API instead. +Please use the new functions that are based on the composable index template API instead.