Skip to content

Commit b9ba8b3

Browse files
v1.15 (#3248)
* version bump * Bump Docker version (#3262) * v1.15: String comparison filter (#3256) * Update code samples [skip ci] * v1.15: Cancel dumpless update (#3257) * add task `type`s * add rollback instructions * first draft ready * v1.15: Disable typo tolerance on numbers (#3258) * add `batchStrategy` to batch object (#3260) * Update postman collection (#3261) * v1.13: Experimental: Limit batch payload size (#3265) * v1.13.1: Update `/stats` with `rawDocumentDbSize` and `avgDocumentDbSize` (#3266) * v1.15: Uncompressed snapshots (#3267) * Update code samples [skip ci]
1 parent 23c2bd5 commit b9ba8b3

34 files changed

+136
-90
lines changed

.code-samples.meilisearch.yaml

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -831,6 +831,13 @@ typo_tolerance_guide_4: |-
831831
"twoTypos": 10
832832
}
833833
}'
834+
typo_tolerance_guide_5: |-
835+
curl \
836+
-X PATCH 'MEILISEARCH_URL/indexes/movies/settings/typo-tolerance' \
837+
-H 'Content-Type: application/json' \
838+
--data-binary '{
839+
"disableOnNumbers": true
840+
}'
834841
updating_guide_check_version_new_authorization_header: |-
835842
curl \
836843
-X GET 'http://<your-domain-name>/version' \

assets/misc/meilisearch-collection-postman.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
{
22
"info": {
33
"_postman_id": "b321d331-d809-4909-8e49-e29c8d749d32",
4-
"name": "Meilisearch v1.14",
4+
"name": "Meilisearch v1.15",
55
"schema": "https://schema.getpostman.com/json/collection/v2.1.0/collection.json",
66
"_exporter_id": "25294324"
77
},
@@ -1898,7 +1898,7 @@
18981898
],
18991899
"body": {
19001900
"mode": "raw",
1901-
"raw": "{\n \"minWordSizeForTypos\": {\n \"oneTypo\": 2,\n \"twoTypos\": 11\n },\n \"disableOnWords\": [\"Prince\"],\n \"disableOnAttributes\": [\"genre\"]\n}"
1901+
"raw": "{\n \"minWordSizeForTypos\": {\n \"oneTypo\": 2,\n \"twoTypos\": 11\n },\n \"disableOnWords\": [\"Prince\"],\n \"disableOnAttributes\": [\"genre\"],\n \"disableOnNumbers\": true\n}"
19021902
},
19031903
"url": {
19041904
"raw": "{{url}}/indexes/{{indexUID}}/settings/typo-tolerance",

docs.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -143,7 +143,7 @@
143143
"navigation": {
144144
"versions": [
145145
{
146-
"version": "v1.14",
146+
"version": "v1.15",
147147
"anchors": [
148148
{
149149
"anchor": "Learn",

guides/docker.mdx

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ Docker is a tool that bundles applications into containers. Docker containers en
1212
Docker containers are distributed in images. To use Meilisearch, use the `docker pull` command to download a Meilisearch image:
1313

1414
```sh
15-
docker pull getmeili/meilisearch:v1.14
15+
docker pull getmeili/meilisearch:v1.15
1616
```
1717

1818
Meilisearch deploys a new Docker image with every release of the engine. Each image is tagged with the corresponding Meilisearch version, indicated in the above example by the text following the `:` symbol. You can see [the full list of available Meilisearch Docker images](https://hub.docker.com/r/getmeili/meilisearch/tags#!) on Docker Hub.
@@ -29,7 +29,7 @@ After completing the previous step, use `docker run` to launch the Meilisearch i
2929
docker run -it --rm \
3030
-p 7700:7700 \
3131
-v $(pwd)/meili_data:/meili_data \
32-
getmeili/meilisearch:v1.14
32+
getmeili/meilisearch:v1.15
3333
```
3434

3535
### Configure Meilisearch
@@ -45,7 +45,7 @@ docker run -it --rm \
4545
-p 7700:7700 \
4646
-e MEILI_MASTER_KEY='MASTER_KEY'\
4747
-v $(pwd)/meili_data:/meili_data \
48-
getmeili/meilisearch:v1.14
48+
getmeili/meilisearch:v1.15
4949
```
5050

5151
#### Passing instance options with CLI arguments
@@ -56,7 +56,7 @@ If you want to pass command-line arguments to Meilisearch with Docker, you must
5656
docker run -it --rm \
5757
-p 7700:7700 \
5858
-v $(pwd)/meili_data:/meili_data \
59-
getmeili/meilisearch:v1.14 \
59+
getmeili/meilisearch:v1.15 \
6060
meilisearch --master-key="MASTER_KEY"
6161
```
6262

@@ -74,7 +74,7 @@ To keep your data intact between reboots, specify a dedicated volume by running
7474
docker run -it --rm \
7575
-p 7700:7700 \
7676
-v $(pwd)/meili_data:/meili_data \
77-
getmeili/meilisearch:v1.14
77+
getmeili/meilisearch:v1.15
7878
```
7979

8080
The example above uses `$(pwd)/meili_data`, which is a directory in the host machine. Depending on your OS, mounting volumes from the host to the container might result in performance loss and is only recommended when developing your application.
@@ -89,7 +89,7 @@ To import a dump, use Meilisearch's `--import-dump` command-line option and spec
8989
docker run -it --rm \
9090
-p 7700:7700 \
9191
-v $(pwd)/meili_data:/meili_data \
92-
getmeili/meilisearch:v1.14 \
92+
getmeili/meilisearch:v1.15 \
9393
meilisearch --import-dump /meili_data/dumps/20200813-042312213.dump
9494
```
9595

@@ -109,7 +109,7 @@ To generate a Meilisearch snapshot with Docker, launch Meilisearch with `--sched
109109
docker run -it --rm \
110110
-p 7700:7700 \
111111
-v $(pwd)/meili_data:/meili_data \
112-
getmeili/meilisearch:v1.14 \
112+
getmeili/meilisearch:v1.15 \
113113
meilisearch --schedule-snapshot --snapshot-dir /meili_data/snapshots
114114
```
115115

@@ -121,7 +121,7 @@ To import a snapshot, launch Meilisearch with the `--import-snapshot` option:
121121
docker run -it --rm \
122122
-p 7700:7700 \
123123
-v $(pwd)/meili_data:/meili_data \
124-
getmeili/meilisearch:v1.14 \
124+
getmeili/meilisearch:v1.15 \
125125
meilisearch --import-snapshot /meili_data/snapshots/data.ms.snapshot
126126
```
127127

learn/filtering_and_sorting/filter_expression_reference.mdx

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -69,14 +69,20 @@ genres != action
6969

7070
### Comparison (`>`, `<`, `>=`, `<=`)
7171

72-
The comparison operators (`>`, `<`, `>=`, `<=`) select documents satisfying a comparison. Comparison operators only apply only to numerical values.
72+
The comparison operators (`>`, `<`, `>=`, `<=`) select documents satisfying a comparison. Comparison operators apply to both numerical and string values.
7373

7474
The expression below returns all documents with a user rating above 85:
7575

7676
```
7777
rating.users > 85
7878
```
7979

80+
String comparisons resolve in lexicographic order: symbols followed by numbers followed by letters in alphabetic order. The expression below returns all documents released after the first day of 2004:
81+
82+
```
83+
release_date > 2004-01-01
84+
```
85+
8086
### `TO`
8187

8288
`TO` is equivalent to `>= AND <=`. The following expression returns all documents with a rating of 80 or above but below 90:

learn/filtering_and_sorting/working_with_dates.mdx

Lines changed: 4 additions & 32 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ In this guide, you will learn about Meilisearch's approach to date and time valu
1414

1515
## Preparing your documents
1616

17-
To filter and sort search results chronologically, your documents must have at least one numeric field containing a [UNIX timestamp](https://kb.narrative.io/what-is-unix-time).
17+
To filter and sort search results chronologically, your documents must have at least one field containing a [UNIX timestamp](https://kb.narrative.io/what-is-unix-time). You may also use a string with a date in a format that can be sorted lexicographically, such as `"2025-01-13"`.
1818

1919
As an example, consider a database of video games. In this dataset, the release year is formatted as a timestamp:
2020

@@ -41,39 +41,11 @@ As an example, consider a database of video games. In this dataset, the release
4141
]
4242
```
4343

44-
If your date field is expressed in a format other than a numeric timestamp, like [ISO 8601](https://www.iso.org/iso-8601-date-and-time-format.html), you must convert it before indexing it with Meilisearch.
45-
46-
Most programming languages have built-in tools to help you with this process. The JavaScript example below converts a game's release date, `"2018-10-18"`, to a numeric timestamp:
47-
48-
```js
49-
let game = {
50-
"id": 0,
51-
"title": "Return of the Obra Dinn",
52-
"genre": "adventure",
53-
"release_date": "2018-10-18T00:00Z"
54-
};
55-
56-
const timestampInMilliseconds = Date.parse(game.release_date); // Date.parse returns the timestamp in milliseconds
57-
const timestamp = timestampInMilliseconds / 1000; // UNIX timestamps must be in seconds
58-
59-
game = {
60-
"id": 0,
61-
"title": "Return of the Obra Dinn",
62-
"genre": "adventure",
63-
"release_date": "2018-10-18T00:00Z",
64-
"release_timestamp": timestamp
65-
};
66-
```
67-
68-
<Tip>
69-
When preparing your dataset, it can be useful to leave the original date and time fields in your documents intact. In the example above, we keep the `release_date` field because it is more readable than the raw `release_timestamp`.
70-
</Tip>
71-
72-
After adding a numeric timestamp to all documents, [index your data](/reference/api/documents#add-or-replace-documents) as usual. The example below adds a <a id="downloadVideogames" href="/assets/datasets/videogames.json" download="videogames.json">videogame dataset</a> to a `games` index:
44+
Once all documents in your dataset have a date field, [index your data](/reference/api/documents#add-or-replace-documents) as usual. The example below adds a <a id="downloadVideogames" href="/assets/datasets/videogames.json" download="videogames.json">videogame dataset</a> to a `games` index:
7345

7446
<CodeSamplesDateGuideIndex1 />
7547

76-
## Filtering by timestamp
48+
## Filtering by date
7749

7850
To filter search results based on their timestamp, add your document's timestamp field to the list of [`filterableAttributes`](/reference/api/settings#update-filterable-attributes):
7951

@@ -83,7 +55,7 @@ Once you have configured `filterableAttributes`, you can filter search results b
8355

8456
<CodeSamplesDateGuideFilter1 />
8557

86-
## Sorting by timestamp
58+
## Sorting by date
8759

8860
To sort search results chronologically, add your document's timestamp field to the list of [`sortableAttributes`](/reference/api/settings#update-sortable-attributes):
8961

learn/relevancy/typo_tolerance_settings.mdx

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -65,3 +65,13 @@ You can disable typo tolerance for a specific [document attribute](/learn/gettin
6565
<CodeSamplesTypoToleranceGuide2 />
6666

6767
With the above settings, matches in the `title` attribute will not tolerate any typos. For example, a search for `beautiful` (9 characters) will not match the movie "Biutiful" starring Javier Bardem. With the default settings, this would be a match.
68+
69+
## `disableOnNumbers`
70+
71+
You can disable typo tolerance for all numeric values across all indexes and search requests by setting `disableOnNumbers` to `true`:
72+
73+
<CodeSamplesTypoToleranceGuide5 />
74+
75+
By default, typo tolerance on numerical values is turned on. This may lead to false positives, such as a search for `2024` matching documents containing `2025` or `2004`.
76+
77+
When `disableOnNumbers` is set to `true`, queries with numbers only return exact matches. Besides reducing the number of false positives, disabling typo tolerance on numbers may also improve indexing performance.

learn/resources/experimental_features_overview.mdx

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -57,3 +57,5 @@ Activating or deactivating experimental features this way does not require you t
5757
| [Dumpless upgrade](/learn/self_hosted/configure_meilisearch_at_launch#dumpless-upgrade) | Upgrade Meilisearch without generating a dump | API route |
5858
| [Composite embedders](/reference/api/settings#composite-embedders) | Enable composite embedders | API route |
5959
| [Search query embedding cache](/learn/self_hosted/configure_meilisearch_at_launch#search-query-embedding-cache) | Enable a cache for search query embeddings | CLI flag or environment variable |
60+
| [Uncompressed snapshots](/learn/self_hosted/configure_meilisearch_at_launch#uncompressed-snapshots) | Disable snapshot compaction | CLI flag or environment variable |
61+
| [Maximum batch payload size](/learn/self_hosted/configure_meilisearch_at_launch#maximum-batch-payload-size) | Limit batch payload size | CLI flag or environment variable |

learn/self_hosted/configure_meilisearch_at_launch.mdx

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -435,6 +435,13 @@ When using the configuration file, it is also possible to explicitly pass a bool
435435

436436
Sets the directory where Meilisearch will store snapshots.
437437

438+
### Uncompressed snapshots <NoticeTag type="experimental" label="experimental" />
439+
440+
**Environment variable**: `MEILI_EXPERIMENTAL_NO_SNAPSHOT_COMPACTION`<br />
441+
**CLI option**: `--experimental-no-snapshot-compaction`<br />
442+
443+
Disables snapshot compression. This may significantly speed up snapshot creation at the cost of bigger snapshot files.
444+
438445
### Import snapshot
439446

440447
**Environment variable**: `MEILI_IMPORT_SNAPSHOT`<br />
@@ -506,6 +513,15 @@ Includes an authentication token in the authorization header when notifying the
506513

507514
Limit the number of tasks Meilisearch performs in a single batch. May improve stability in systems handling a large queue of resource-intensive tasks.
508515

516+
### Maximum batch payload size <NoticeTag type="experimental" label="experimental" />
517+
518+
**Environment variable**: `MEILI_EXPERIMENTAL_LIMIT_BATCHED_TASKS_TOTAL_SIZE`<br />
519+
**CLI option**: `--experimental-limit-batched-tasks-total-size`<br />
520+
**Default value**: `None`<br />
521+
**Expected value**: an integer
522+
523+
Sets a maximum payload size for batches in bytes. Smaller batches are less efficient, but consume less RAM and reduce immediate latency.
524+
509525
### Replication parameters <NoticeTag type="experimental" label="experimental" />
510526

511527
<Warning>

learn/self_hosted/install_meilisearch_locally.mdx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -53,14 +53,14 @@ These commands launch the **latest stable release** of Meilisearch.
5353

5454
```bash
5555
# Fetch the latest version of Meilisearch image from DockerHub
56-
docker pull getmeili/meilisearch:v1.14
56+
docker pull getmeili/meilisearch:v1.15
5757

5858
# Launch Meilisearch in development mode with a master key
5959
docker run -it --rm \
6060
-p 7700:7700 \
6161
-e MEILI_ENV='development' \
6262
-v $(pwd)/meili_data:/meili_data \
63-
getmeili/meilisearch:v1.14
63+
getmeili/meilisearch:v1.15
6464
# Use ${pwd} instead of $(pwd) in PowerShell
6565
```
6666

learn/update_and_migration/updating.mdx

Lines changed: 16 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -47,9 +47,9 @@ Once the project has been successfully updated, you will receive an email confir
4747

4848
## Updating a self-hosted Meilisearch instance
4949

50-
<Warning>
5150
You may update a self-hosted instance in one of two ways: with or without a dump.
5251

52+
<Warning>
5353
This guide only works for v0.15 and above. If you are using an older Meilisearch release, please [contact support](https://discord.meilisearch.com) for more information.
5454
</Warning>
5555

@@ -156,9 +156,21 @@ Meilisearch should launch normally and immediately create a new `UpgradeDatabase
156156

157157
While the task is processing, you may continue making search queries. You may also enqueue new tasks. Meilisearch will only process new tasks once `UpgradeDatabase` is completed.
158158

159-
<Warning>
160-
If after the upgrade is completed the task status is set to `failed` or Meilisearch returns internal error messages to your queries, [restart your instance from the snapshot](/learn/data_backup/snapshots#starting-from-a-snapshot) you generated during step 1. You may then retry the upgrade, or upgrade using a dump. You are also welcome to open an issue on the [Meilisearch repository](https://github.com/meilisearch/meilisearch).
161-
</Warning>
159+
#### Rolling back an update
160+
161+
If the upgrade is taking too long, or if after the upgrade is completed its task status is set to `failed`, you can cancel the upgrade task.
162+
163+
Cancelling the update task automatically rolls back your database to its state before the upgrade began.
164+
165+
After launching Meilisearch with `--experimental-dumpless-upgrade` flag:
166+
167+
1. Cancel the `databaseUpgrade` task
168+
2. If you cancelled the update before it failed, skip to the next step. If the update failed, relaunch Meilisearch using the binary of the version you were upgrading to
169+
3. Wait for Meilisearch to process your cancellation request
170+
4. Replace the new binary with the binary of the previous version
171+
5. Relaunch Meilisearch
172+
173+
If you are upgrading Meilisearch to \<= v1.14, you must instead [restart your instance from the snapshot](/learn/data_backup/snapshots#starting-from-a-snapshot) you generated during step 1. You may then retry the upgrade, or upgrade using a dump. You are also welcome to open an issue on the [Meilisearch repository](https://github.com/meilisearch/meilisearch).
162174

163175
### Using a dump
164176

package-lock.json

Lines changed: 2 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
{
2-
"version": "1.14.0",
2+
"version": "1.15.0",
33
"homepage": "https://meilisearch.com/docs",
44
"license": "MIT",
55
"repository": "meilisearch/documentation",

0 commit comments

Comments
 (0)