Compare commits

...

11 Commits

Author SHA1 Message Date
1387a211d2 Merge #3053
3053: Upgrade alpine 3.14 to 3.16 r=Kerollmops a=curquiza

Otherwise CI is failing https://github.com/meilisearch/meilisearch/actions/runs/3470576605/jobs/5799173168

Co-authored-by: curquiza <clementine@meilisearch.com>
2022-11-15 13:56:45 +00:00
661b345ad9 Upgrade alpine 3.14 to 3.16 2022-11-15 14:54:18 +01:00
0f0d1dccf0 Merge #3047
3047: Fix soft deleted bug settings r=curquiza a=Kerollmops

This PR fixes https://github.com/meilisearch/meilisearch/issues/3021 and fixes https://github.com/meilisearch/meilisearch/issues/2945 and is released as version 0.29.2.

Co-authored-by: Kerollmops <clement@meilisearch.com>
2022-11-15 11:08:47 +00:00
0331fc7c71 Make clippy happy 2022-11-15 12:07:00 +01:00
5cfcdbb55a Bump the version to v0.29.2 2022-11-14 17:39:10 +01:00
c77c3a90a0 Use milli v0.33.5 2022-11-14 17:39:09 +01:00
3ebd88c03b Revert "Comment cache steps in jobs"
This reverts commit f513ac1233.
2022-10-10 14:46:54 +02:00
c958097e99 Merge #2862
2862: Use Ubuntu 18.04 for all CI tasks that previously used Ubuntu 20.04 r=curquiza a=loiclec

This is to prevent linking with a version of glibc that is too recent.

With meilisearch v0.29.0 we inadvertently bumped the minimum supported glibc version to 2.29, which means it couldn't be run from Debian 10 (for example) anymore. By using Ubuntu 18.04, which uses glibc 2.27, we restore support for older Linux distros.

Fixes #2850

Co-authored-by: LoĂŻc Lecrenier <loic@meilisearch.com>
Co-authored-by: Clémentine Urquizar <clementine@meilisearch.com>
2022-10-10 14:42:18 +02:00
f513ac1233 Comment cache steps in jobs 2022-10-10 14:25:24 +02:00
97c202db51 Update version for next release (v0.29.1) 2022-10-10 14:25:24 +02:00
a5e23aa6e4 Use Ubuntu 18.04 for all CI tasks that previously used Ubuntu 20.04
This is to prevent linking with a version of glibc that is too recent.

With meilisearch v0.29.0 we inadvertently bumped the minimum supported
glibc version to 2.29, which means it couldn't be run from Debian 10
(for example) anymore. By using Ubuntu 18.04, which uses glibc 2.27, we
restore support for older Linux distros.
2022-10-10 14:25:18 +02:00
17 changed files with 50 additions and 50 deletions

View File

@ -6,7 +6,7 @@ name: Execute code coverage
jobs:
nightly-coverage:
runs-on: ubuntu-20.04
runs-on: ubuntu-18.04
steps:
- uses: actions/checkout@v3
- uses: actions-rs/toolchain@v1

View File

@ -5,7 +5,7 @@ on:
jobs:
flaky:
runs-on: ubuntu-20.04
runs-on: ubuntu-18.04
steps:
- uses: actions/checkout@v3

View File

@ -35,9 +35,9 @@ jobs:
strategy:
fail-fast: false
matrix:
os: [ubuntu-20.04, macos-latest, windows-latest]
os: [ubuntu-18.04, macos-latest, windows-latest]
include:
- os: ubuntu-20.04
- os: ubuntu-18.04
artifact_name: meilisearch
asset_name: meilisearch-linux-amd64
- os: macos-latest
@ -72,7 +72,7 @@ jobs:
matrix:
include:
- build: aarch64
os: ubuntu-20.04
os: ubuntu-18.04
target: aarch64-unknown-linux-gnu
linker: gcc-aarch64-linux-gnu
use-cross: true

View File

@ -15,7 +15,7 @@ jobs:
debian:
name: Publish debian packagge
runs-on: ubuntu-20.04
runs-on: ubuntu-18.04
needs: check-version
steps:
- uses: hecrj/setup-rust-action@master
@ -38,7 +38,7 @@ jobs:
homebrew:
name: Bump Homebrew formula
runs-on: ubuntu-20.04
runs-on: ubuntu-18.04
needs: check-version
steps:
- name: Create PR to Homebrew

View File

@ -21,7 +21,7 @@ jobs:
strategy:
fail-fast: false
matrix:
os: [ubuntu-20.04, macos-latest, windows-latest]
os: [ubuntu-18.04, macos-latest, windows-latest]
steps:
- uses: actions/checkout@v3
- name: Cache dependencies
@ -40,7 +40,7 @@ jobs:
# We run tests in debug also, to make sure that the debug_assertions are hit
test-debug:
name: Run tests in debug
runs-on: ubuntu-20.04
runs-on: ubuntu-18.04
steps:
- uses: actions/checkout@v3
- uses: actions-rs/toolchain@v1
@ -58,7 +58,7 @@ jobs:
clippy:
name: Run Clippy
runs-on: ubuntu-20.04
runs-on: ubuntu-18.04
steps:
- uses: actions/checkout@v3
- uses: actions-rs/toolchain@v1
@ -77,7 +77,7 @@ jobs:
fmt:
name: Run Rustfmt
runs-on: ubuntu-20.04
runs-on: ubuntu-18.04
steps:
- uses: actions/checkout@v3
- uses: actions-rs/toolchain@v1

18
Cargo.lock generated
View File

@ -1126,7 +1126,7 @@ dependencies = [
[[package]]
name = "filter-parser"
version = "0.33.4"
source = "git+https://github.com/meilisearch/milli.git?tag=v0.33.4#4fc6331cb6526c07f3137584564cfe3493fb25bd"
source = "git+https://github.com/meilisearch/milli.git?tag=v0.33.5#4fc6331cb6526c07f3137584564cfe3493fb25bd"
dependencies = [
"nom",
"nom_locate",
@ -1151,7 +1151,7 @@ dependencies = [
[[package]]
name = "flatten-serde-json"
version = "0.33.4"
source = "git+https://github.com/meilisearch/milli.git?tag=v0.33.4#4fc6331cb6526c07f3137584564cfe3493fb25bd"
source = "git+https://github.com/meilisearch/milli.git?tag=v0.33.5#4fc6331cb6526c07f3137584564cfe3493fb25bd"
dependencies = [
"serde_json",
]
@ -1668,7 +1668,7 @@ dependencies = [
[[package]]
name = "json-depth-checker"
version = "0.33.4"
source = "git+https://github.com/meilisearch/milli.git?tag=v0.33.4#4fc6331cb6526c07f3137584564cfe3493fb25bd"
source = "git+https://github.com/meilisearch/milli.git?tag=v0.33.5#4fc6331cb6526c07f3137584564cfe3493fb25bd"
dependencies = [
"serde_json",
]
@ -2009,7 +2009,7 @@ checksum = "3e2e65a1a2e43cfcb47a895c4c8b10d1f4a61097f9f254f183aee60cad9c651d"
[[package]]
name = "meilisearch-auth"
version = "0.29.0"
version = "0.29.2"
dependencies = [
"enum-iterator 0.7.0",
"hmac",
@ -2026,7 +2026,7 @@ dependencies = [
[[package]]
name = "meilisearch-http"
version = "0.29.0"
version = "0.29.2"
dependencies = [
"actix-cors",
"actix-rt",
@ -2101,7 +2101,7 @@ dependencies = [
[[package]]
name = "meilisearch-lib"
version = "0.29.0"
version = "0.29.2"
dependencies = [
"actix-rt",
"actix-web",
@ -2164,7 +2164,7 @@ dependencies = [
[[package]]
name = "meilisearch-types"
version = "0.29.0"
version = "0.29.2"
dependencies = [
"actix-web",
"proptest",
@ -2200,7 +2200,7 @@ dependencies = [
[[package]]
name = "milli"
version = "0.33.4"
source = "git+https://github.com/meilisearch/milli.git?tag=v0.33.4#4fc6331cb6526c07f3137584564cfe3493fb25bd"
source = "git+https://github.com/meilisearch/milli.git?tag=v0.33.5#4fc6331cb6526c07f3137584564cfe3493fb25bd"
dependencies = [
"bimap",
"bincode",
@ -2534,7 +2534,7 @@ checksum = "478c572c3d73181ff3c2539045f6eb99e5491218eae919370993b890cdbdd98e"
[[package]]
name = "permissive-json-pointer"
version = "0.29.0"
version = "0.29.2"
dependencies = [
"big_s",
"serde_json",

View File

@ -1,5 +1,5 @@
# Compile
FROM rust:alpine3.14 AS compiler
FROM rust:alpine3.16 AS compiler
RUN apk add -q --update-cache --no-cache build-base openssl-dev
@ -19,7 +19,7 @@ RUN set -eux; \
cargo build --release
# Run
FROM alpine:3.14
FROM alpine:3.16
ENV MEILI_HTTP_ADDR 0.0.0.0:7700
ENV MEILI_SERVER_PROVIDER docker

View File

@ -1,5 +1,5 @@
status = [
'Tests on ubuntu-20.04',
'Tests on ubuntu-18.04',
'Tests on macos-latest',
'Tests on windows-latest',
'Run Clippy',

View File

@ -1,13 +1,13 @@
[package]
name = "meilisearch-auth"
version = "0.29.0"
version = "0.29.2"
edition = "2021"
[dependencies]
enum-iterator = "0.7.0"
hmac = "0.12.1"
meilisearch-types = { path = "../meilisearch-types" }
milli = { git = "https://github.com/meilisearch/milli.git", tag = "v0.33.4" }
milli = { git = "https://github.com/meilisearch/milli.git", tag = "v0.33.5" }
rand = "0.8.4"
serde = { version = "1.0.136", features = ["derive"] }
serde_json = { version = "1.0.85", features = ["preserve_order"] }

View File

@ -4,7 +4,7 @@ description = "Meilisearch HTTP server"
edition = "2021"
license = "MIT"
name = "meilisearch-http"
version = "0.29.0"
version = "0.29.2"
[[bin]]
name = "meilisearch"

View File

@ -99,7 +99,7 @@ async fn error_access_expired_key() {
assert!(response["key"].is_string());
let key = response["key"].as_str().unwrap();
server.use_api_key(&key);
server.use_api_key(key);
// wait until the key is expired.
thread::sleep(time::Duration::new(1, 0));
@ -135,7 +135,7 @@ async fn error_access_unauthorized_index() {
assert!(response["key"].is_string());
let key = response["key"].as_str().unwrap();
server.use_api_key(&key);
server.use_api_key(key);
for (method, route) in AUTHORIZATIONS
.keys()
@ -175,7 +175,7 @@ async fn error_access_unauthorized_action() {
assert!(response["key"].is_string());
let key = response["key"].as_str().unwrap();
server.use_api_key(&key);
server.use_api_key(key);
let (response, code) = server.dummy_request(method, route).await;
assert_eq!(
@ -230,7 +230,7 @@ async fn access_authorized_restricted_index() {
assert!(response["key"].is_string());
let key = response["key"].as_str().unwrap();
server.use_api_key(&key);
server.use_api_key(key);
let (response, code) = server.dummy_request(method, route).await;
@ -268,7 +268,7 @@ async fn access_authorized_no_index_restriction() {
assert!(response["key"].is_string());
let key = response["key"].as_str().unwrap();
server.use_api_key(&key);
server.use_api_key(key);
let (response, code) = server.dummy_request(method, route).await;
@ -313,7 +313,7 @@ async fn access_authorized_stats_restricted_index() {
// use created key.
let key = response["key"].as_str().unwrap();
server.use_api_key(&key);
server.use_api_key(key);
let (response, code) = server.stats().await;
assert_eq!(200, code, "{:?}", &response);
@ -353,7 +353,7 @@ async fn access_authorized_stats_no_index_restriction() {
// use created key.
let key = response["key"].as_str().unwrap();
server.use_api_key(&key);
server.use_api_key(key);
let (response, code) = server.stats().await;
assert_eq!(200, code, "{:?}", &response);
@ -393,7 +393,7 @@ async fn list_authorized_indexes_restricted_index() {
// use created key.
let key = response["key"].as_str().unwrap();
server.use_api_key(&key);
server.use_api_key(key);
let (response, code) = server.list_indexes(None, None).await;
assert_eq!(200, code, "{:?}", &response);
@ -434,7 +434,7 @@ async fn list_authorized_indexes_no_index_restriction() {
// use created key.
let key = response["key"].as_str().unwrap();
server.use_api_key(&key);
server.use_api_key(key);
let (response, code) = server.list_indexes(None, None).await;
assert_eq!(200, code, "{:?}", &response);
@ -474,7 +474,7 @@ async fn list_authorized_tasks_restricted_index() {
// use created key.
let key = response["key"].as_str().unwrap();
server.use_api_key(&key);
server.use_api_key(key);
let (response, code) = server.service.get("/tasks").await;
assert_eq!(200, code, "{:?}", &response);
@ -514,7 +514,7 @@ async fn list_authorized_tasks_no_index_restriction() {
// use created key.
let key = response["key"].as_str().unwrap();
server.use_api_key(&key);
server.use_api_key(key);
let (response, code) = server.service.get("/tasks").await;
assert_eq!(200, code, "{:?}", &response);
@ -545,7 +545,7 @@ async fn error_creating_index_without_action() {
// use created key.
let key = response["key"].as_str().unwrap();
server.use_api_key(&key);
server.use_api_key(key);
let expected_error = json!({
"message": "Index `test` not found.",
@ -625,7 +625,7 @@ async fn lazy_create_index() {
// use created key.
let key = response["key"].as_str().unwrap();
server.use_api_key(&key);
server.use_api_key(key);
// try to create a index via add documents route
let index = server.index("test");
@ -692,7 +692,7 @@ async fn error_creating_index_without_index() {
// use created key.
let key = response["key"].as_str().unwrap();
server.use_api_key(&key);
server.use_api_key(key);
// try to create a index via add documents route
let index = server.index("test");

View File

@ -473,7 +473,7 @@ async fn error_access_forbidden_routes() {
"searchRules" => json!(["*"]),
"exp" => json!((OffsetDateTime::now_utc() + Duration::hours(1)).unix_timestamp())
};
let web_token = generate_tenant_token(&uid, &key, tenant_token);
let web_token = generate_tenant_token(uid, key, tenant_token);
server.use_api_key(&web_token);
for ((method, route), actions) in AUTHORIZATIONS.iter() {
@ -509,7 +509,7 @@ async fn error_access_expired_parent_key() {
"searchRules" => json!(["*"]),
"exp" => json!((OffsetDateTime::now_utc() + Duration::hours(1)).unix_timestamp())
};
let web_token = generate_tenant_token(&uid, &key, tenant_token);
let web_token = generate_tenant_token(uid, key, tenant_token);
server.use_api_key(&web_token);
// test search request while parent_key is not expired
@ -552,7 +552,7 @@ async fn error_access_modified_token() {
"searchRules" => json!(["products"]),
"exp" => json!((OffsetDateTime::now_utc() + Duration::hours(1)).unix_timestamp())
};
let web_token = generate_tenant_token(&uid, &key, tenant_token);
let web_token = generate_tenant_token(uid, key, tenant_token);
server.use_api_key(&web_token);
// test search request while web_token is valid
@ -567,7 +567,7 @@ async fn error_access_modified_token() {
"exp" => json!((OffsetDateTime::now_utc() + Duration::hours(1)).unix_timestamp())
};
let alt = generate_tenant_token(&uid, &key, tenant_token);
let alt = generate_tenant_token(uid, key, tenant_token);
let altered_token = [
web_token.split('.').next().unwrap(),
alt.split('.').nth(1).unwrap(),

View File

@ -1,6 +1,6 @@
[package]
name = "meilisearch-lib"
version = "0.29.0"
version = "0.29.2"
edition = "2021"
[dependencies]
@ -28,7 +28,7 @@ lazy_static = "1.4.0"
log = "0.4.14"
meilisearch-auth = { path = "../meilisearch-auth" }
meilisearch-types = { path = "../meilisearch-types" }
milli = { git = "https://github.com/meilisearch/milli.git", tag = "v0.33.4" }
milli = { git = "https://github.com/meilisearch/milli.git", tag = "v0.33.5" }
mime = "0.3.16"
num_cpus = "1.13.1"
obkv = "0.2.0"

View File

@ -213,7 +213,7 @@ impl TaskQueue {
let head = self.queue.pop()?;
let result = {
let mut ref_head = head.borrow_mut();
f(&mut *ref_head)
f(&mut ref_head)
};
if !head.borrow().tasks.is_empty() {
// After being mutated, the head is reinserted to the correct position.

View File

@ -117,7 +117,7 @@ impl TaskStore {
match filter {
Some(filter) => filter
.pass(&task)
.then(|| task)
.then_some(task)
.ok_or(TaskError::UnexistingTask(id)),
None => Ok(task),
}

View File

@ -1,6 +1,6 @@
[package]
name = "meilisearch-types"
version = "0.29.0"
version = "0.29.2"
authors = ["marin <postma.marin@protonmail.com>"]
edition = "2021"

View File

@ -1,6 +1,6 @@
[package]
name = "permissive-json-pointer"
version = "0.29.0"
version = "0.29.2"
edition = "2021"
description = "A permissive json pointer"
readme = "README.md"