Closed bogdanromanx closed 3 years ago
Benchmarks results:
The benchmarks were only run on the 1,000-indices scenario as the 10,000 indices one hits the default limit of shards per node and goes well against elasticsearch recommendations in terms of shard sizing.
The 1,000 scenario allowed to create 90M documents imitating documents and queries we would like to achieve.
NB: the term nested field
in this comment holds the elasticsearch meaning.
The queries (enclosed with this comment) were the following:
annotation
annotation
and role
annotation
and role
Each of these queries were run against:
Each of these 16 combinations were repeated 100 times where details are enclosed in the gatling report. global-search-benchmarks.zip
Conclusions on this benchmark:
Design the technical solution for global search capabilities (expected outcome is merely a technical design):
General approach:
Known issues that need to be addressed:
Initial mock-ups: https://xd.adobe.com/view/8ac356ae-0294-45d6-b2bc-c17441c9f780-df90/screen/c5d66708-878a-4be7-a097-34a9ab088c37/
Acceptance criteria:
ES Benchmark:
Data setup
Data types: 10-50 Shared properties across data types: 10 Custom properties per data type: 5 Additional properties (no facets): 10 Max distinct values per property: 100
Test setup
Cluster size: 8 Cores: 16 vcpu Memory (heap): 16 Memory (total): 32
Count of projects: 500 Number of replicas: 2 (3 shards) increasing to 4 (5 shards) after biggest test 1,000 / 1% - 6mil, 2% - 1mil, 5% - 20k, 92% - 10K docs 10,000 / 1% - 1mil docs, 5% - 100k, 94% - 10k
Example query (to be modified)
Max size per term: 100 Max size per shard: https://www.elastic.co/guide/en/elasticsearch/reference/current/search-aggregations-bucket-terms-aggregation.html Track total hits: 10k
https://www.elastic.co/guide/en/elasticsearch/reference/current/search-aggregations-bucket-terms-aggregation.html
Click to expand!
``` { "sort": [ { "_createdAt": { "order": "desc" } } ], "size": 20, "from": 0, "track_total_hits": 1000000, "query": { "bool": { "filter": { "bool": { "must": [ { "match_all": {} }, { "term": { "_deprecated": false } } ] } } } }, "aggs": { "brainLocationLabel": { "terms": { "field": "brainLocation.brainRegion.label.raw", "size": 1000000 } }, "objectOfStudyLabel": { "terms": { "field": "objectOfStudy.label.raw", "size": 1000000 } }, "type": { "terms": { "field": "@type", "size": 1000000 } }, "layer": { "terms": { "field": "brainLocation.layer.label.raw", "size": 1000000 } }, "annotation": { "terms": { "field": "annotation.hasBody.label.raw", "size": 1000000 } } } } ```