Skip to content

Commit 5f2b00b

Browse files
committed
Update headings and code sample
1 parent 375e192 commit 5f2b00b

File tree

1 file changed

+51
-33
lines changed

1 file changed

+51
-33
lines changed

learn/indexing/optimize_indexing_performance.mdx

Lines changed: 51 additions & 33 deletions
Original file line numberDiff line numberDiff line change
@@ -28,56 +28,71 @@ Focus on the **longest-running steps** and investigate which index settings or d
2828

2929
## Key phases and how to optimize them
3030

31-
### Document processing
31+
### `computing document changes`and `extracting documents`
3232

33-
| Trace key | Description | Optimization |
34-
|------------|--------------|--------------|
35-
| `computing document changes`, `extracting documents` | Meilisearch compares incoming documents to existing ones. | No direct optimization possible. Process duration scales with the number and size of incoming documents.|
33+
| Description | Optimization |
34+
|--------------|--------------|
35+
| Meilisearch compares incoming documents to existing ones. | No direct optimization possible. Process duration scales with the number and size of incoming documents.|
3636

37-
### Filterable attributes
37+
### `extracting facets` and `merging facet caches`
3838

39-
| Trace key | Description | Optimization |
40-
|------------|--------------|--------------|
41-
| `extracting facets`, `merging facet caches` | Extracts and merges filterable attributes. | Keep the number of [**filterable attributes**](/reference/api/settings#filterable-attributes) to a minimum. |
39+
| Description | Optimization |
40+
|--------------|--------------|
41+
| Extracts and merges filterable attributes. | Keep the number of [**filterable attributes**](/reference/api/settings#filterable-attributes) to a minimum. |
4242

43-
### Searchable attributes
43+
### `extracting words` and `merging word caches`
4444

45-
| Trace key | Description | Optimization |
46-
|------------|--------------|--------------|
47-
| `extracting words`, `merging word caches` | Tokenizes text and builds the inverted index. | Ensure the [searchable attributes](/reference/api/settings#searchable-attributes) list only includes the fields you want to be checked for query word matches. |
45+
| Description | Optimization |
46+
|--------------|--------------|
47+
| Tokenizes text and builds the inverted index. | Ensure the [searchable attributes](/reference/api/settings#searchable-attributes) list only includes the fields you want to be checked for query word matches. |
4848

49-
### Proximity precision
49+
### `extracting word proximity`, `merging word proximity`
5050

51-
| Trace key | Description | Optimization |
52-
|------------|--------------|--------------|
53-
| `extracting word proximity`, `merging word proximity` | Builds data structures for phrase and attribute ranking. | Lower the precision of this operation by setting [proximity precision](/reference/api/settings#proximity-precision) to `byAttribute` |
51+
| Description | Optimization |
52+
|--------------|--------------|
53+
| Builds data structures for phrase and attribute ranking. | Lower the precision of this operation by setting [proximity precision](/reference/api/settings#proximity-precision) to `byAttribute` |
5454

55-
### Disk I/O and hardware bottlenecks
55+
### `waiting for database writes`
5656

57-
| Trace key | Description | Optimization |
58-
|------------|--------------|--------------|
59-
| `waiting for database writes` | Time spent writing data to disk. | No direct optimization possible. Either the disk is too slow or you are writing too much data in a single operation. Avoid HDDs (Hard Disk Drives) |
60-
| `waiting for extractors` | Time spent waiting for CPU-bound extraction. | No direct optimization possible. Indicates a CPU bottleneck. Use more cores or scale horizontally with [sharding](/learn/advanced/sharding). |
57+
| Description | Optimization |
58+
|--------------|--------------|
59+
| Time spent writing data to disk. | No direct optimization possible. Either the disk is too slow or you are writing too much data in a single operation. Avoid HDDs (Hard Disk Drives) |
6160

62-
### Facets and filterable attributes
61+
### `waiting for extractors`
6362

64-
| Trace key | Description | Optimization |
65-
|------------|--------------|--------------|
66-
| `post processing facets > strings bulk` / `numbers bulk` | Processes equality or comparison filters. | - Disable unused [**filter features**](/reference/api/settings#features), such as comparison operators on string values. <br /> - Reduce the number of [**sortable attributes**](reference/api/settings#sortable-attributes). |
67-
| `post processing facets > facet search` | Builds structures for the [facet search API](/reference/api/facet_search). | If you don’t use the facet search API, [disable it](/reference/api/settings#update-facet-search-settings).|
63+
| Description | Optimization |
64+
|--------------|--------------|
65+
| Time spent waiting for CPU-bound extraction. | No direct optimization possible. Indicates a CPU bottleneck. Use more cores or scale horizontally with [sharding](/learn/advanced/sharding). |
66+
67+
### `post processing facets > strings bulk` / `numbers bulk`
68+
69+
| Description | Optimization |
70+
|--------------|--------------|
71+
| Processes equality or comparison filters. | - Disable unused [**filter features**](/reference/api/settings#features), such as comparison operators on string values. <br /> - Reduce the number of [**sortable attributes**](reference/api/settings#sortable-attributes). |
72+
73+
### `post processing facets > facet search`
74+
75+
| Description | Optimization |
76+
|--------------|--------------|
77+
| Builds structures for the [facet search API](/reference/api/facet_search). | If you don’t use the facet search API, [disable it](/reference/api/settings#update-facet-search-settings).|
6878

6979
### Embeddings
7080

7181
| Trace key | Description | Optimization |
7282
|------------|--------------|--------------|
7383
| `writing embeddings to database` | Time spent saving vector embeddings. | Use embedding vectors with fewer dimensions. <br/>- [Disabling embedding regeneration on document update](/reference/api/documents#vectors). <br/>- Consider enabling [binary quantization](/reference/api/settings#binaryquantized). |
7484

75-
### Word prefixes and post-processing
85+
### `post processing words > word prefix *`
7686

77-
| Trace key | Description | Optimization |
78-
|------------|--------------|--------------|
79-
| `post processing words > word prefix *` | Builds prefix data for autocomplete. Allows matching documents that begin with a specific query term, instead of only exact matches.| Disable [**prefix search**](/reference/api/settings#prefix-search) (`prefixSearch: disabled`). *This can severely impact search result relevancy.* |
80-
| `post processing words > word fst` | Builds the word FST (finite state transducer). | No direct action possible, as FST size reflect the number of different words in the database. Using documents with fewer searchable words may improve operation speed. |
87+
| Description | Optimization |
88+
|--------------|--------------|
89+
| | Builds prefix data for autocomplete. Allows matching documents that begin with a specific query term, instead of only exact matches.| Disable [**prefix search**](/reference/api/settings#prefix-search) (`prefixSearch: disabled`). _This can severely impact search result relevancy._ |
90+
91+
### `post processing words > word fst`
92+
93+
| Description | Optimization |
94+
|--------------|--------------|
95+
| Builds the word FST (finite state transducer). | No direct action possible, as FST size reflect the number of different words in the database. Using documents with fewer searchable words may improve operation speed. |
8196

8297
## Example analysis
8398

@@ -89,8 +104,11 @@ If you see:
89104

90105
[Facet searching](/learn/filtering_and_sorting/search_with_facet_filters#searching-facet-values) is raking significant indexing time. If your application doesn’t use facets, disable the feature:
91106

92-
```
93-
client.index('INDEX_NAME').updateFacetSearch(false);
107+
```bash
108+
curl \
109+
-X PUT 'MEILISEARCH_URL/indexes/INDEX_UID/settings/facet-search' \
110+
-H 'Content-Type: application/json' \
111+
--data-binary 'false'
94112
```
95113

96114
## Learn more

0 commit comments

Comments
 (0)