Skip to content

Commit effbd58

Browse files
committed
TASK: Update Readme
- Add settings level - Use current Fusion prototype names
1 parent 0a0801a commit effbd58

1 file changed

Lines changed: 33 additions & 34 deletions

File tree

README.md

Lines changed: 33 additions & 34 deletions
Original file line numberDiff line numberDiff line change
@@ -143,9 +143,10 @@ Flowpack:
143143
indexes:
144144
default: # Configuration bundle name
145145
neoscontentrepository: # The index prefix name, must be the same as in the Neos.ContentRepository.Search.elasticSearch.indexName setting
146-
index:
147-
number_of_shards: 1
148-
number_of_replicas: 0
146+
settings:
147+
index:
148+
number_of_shards: 1
149+
number_of_replicas: 0
149150
```
150151

151152
### Configure per dimension
@@ -159,22 +160,23 @@ Flowpack:
159160
ElasticSearch:
160161
indexes:
161162
default:
162-
'neoscontentrepository-0359ed5c416567b8bc2e5ade0f277b36': # The hash specifies the dimension combination
163-
index:
164-
number_of_shards: 1
165-
number_of_replicas: 0
166-
analysis:
167-
filter:
168-
elision:
169-
type: 'elision'
170-
articles: [ 'l', 'm', 't', 'qu', 'n', 's', 'j', 'd' ]
171-
analyzer:
172-
custom_french_analyzer:
173-
tokenizer: 'letter'
174-
filter: [ 'asciifolding', 'lowercase', 'french_stem', 'elision', 'stop' ]
175-
tag_analyzer:
176-
tokenizer: 'keyword'
177-
filter: [ 'asciifolding', 'lowercase' ]
163+
'neoscontentrepository-0359ed5c416567b8bc2e5ade0f277b36': # The hash specifies the dimension combination
164+
settings:
165+
index:
166+
number_of_shards: 1
167+
number_of_replicas: 0
168+
analysis:
169+
filter:
170+
elision:
171+
type: 'elision'
172+
articles: [ 'l', 'm', 't', 'qu', 'n', 's', 'j', 'd' ]
173+
analyzer:
174+
custom_french_analyzer:
175+
tokenizer: 'letter'
176+
filter: [ 'asciifolding', 'lowercase', 'french_stem', 'elision', 'stop' ]
177+
tag_analyzer:
178+
tokenizer: 'keyword'
179+
filter: [ 'asciifolding', 'lowercase' ]
178180
```
179181

180182
Which dimension combinations are available in your system and which hashes they are identified with can be shown with the CLI command:
@@ -539,8 +541,8 @@ fieldBasedAggregation("anotherAggregation", "field", "avg", "colors.avgprice")
539541
To add a custom aggregation you can use the `aggregation()` method. All you have to do is to provide an array with your
540542
aggregation definition. This example would do the same as the fieldBasedAggregation would do for you:
541543
```
542-
aggregationDefinition = Neos.Fusion:RawArray {
543-
terms = Neos.Fusion:RawArray {
544+
aggregationDefinition = Neos.Fusion:DataStructure {
545+
terms = Neos.Fusion:DataStructure {
544546
field = "color"
545547
}
546548
}
@@ -558,7 +560,7 @@ prototype(Vendor.Name:FilteredProductList) < prototype(Neos.Neos:Content)
558560
prototype(Vendor.Name:FilteredProductList) {
559561

560562
// Create SearchFilter for products
561-
searchFilter = Neos.Fusion:RawArray {
563+
searchFilter = Neos.Fusion:DataStructure {
562564
sku = ${String.split(q(node).property("products"), ",")}
563565
}
564566

@@ -607,9 +609,6 @@ for all your filterable properties, or else filtering won't work on them properl
607609
type: keyword
608610
```
609611

610-
**Note:** When using Elasticsearch 5.x the mapping needs to be adjusted in a different way.
611-
More information on the [mapping in ElasticSearch 5.x](Documentation/ElasticMapping-5.x.md).
612-
613612
## Sorting
614613

615614
This package adapts Elasticsearchs sorting capabilities. You can add multiple sort operations to your query.
@@ -631,9 +630,9 @@ nodes = ${q(Search.query(site).....sortAsc("title").sortDesc("name").execute())}
631630
632631
# Custom sort operation
633632
634-
geoSorting = Neos.Fusion:RawArray {
635-
_geo_distance = Neos.Fusion:RawArray {
636-
latlng = Neos.Fusion:RawArray {
633+
geoSorting = Neos.Fusion:DataStructure {
634+
_geo_distance = Neos.Fusion:DataStructure {
635+
latlng = Neos.Fusion:DataStructure {
637636
lat = 51.512711
638637
lon = 7.453084
639638
}
@@ -666,9 +665,9 @@ First of all you have to define a property in your NodeTypes.yaml for your node
666665
667666
Query your nodes in your Fusion:
668667
```
669-
geoSorting = Neos.Fusion:RawArray {
670-
_geo_distance = Neos.Fusion:RawArray {
671-
latlng = Neos.Fusion:RawArray {
668+
geoSorting = Neos.Fusion:DataStructure {
669+
_geo_distance = Neos.Fusion:DataStructure {
670+
latlng = Neos.Fusion:DataStructure {
672671
lat = 51.512711
673672
lon = 7.453084
674673
}
@@ -757,10 +756,10 @@ You can access your suggestions inside your fluid template with
757756
Phrase query that returns query suggestions
758757

759758
```
760-
suggestionsQueryDefinition = Neos.Fusion:RawArray {
759+
suggestionsQueryDefinition = Neos.Fusion:DataStructure {
761760
text = 'some Text'
762-
simple_phrase = Neos.Fusion:RawArray {
763-
phrase = Neos.Fusion:RawArray {
761+
simple_phrase = Neos.Fusion:DataStructure {
762+
phrase = Neos.Fusion:DataStructure {
764763
analyzer = 'body'
765764
field = 'bigram'
766765
size = 1

0 commit comments

Comments
 (0)