From 7445cfe84718476f76c7ea88095043aeb1f7f972 Mon Sep 17 00:00:00 2001 From: eyang Date: Thu, 16 Nov 2023 15:48:19 -0800 Subject: [PATCH] fixes: https://github.com/GreptimeTeam/greptimedb/issues/2758 Chore: improve user experience on setting compression type --- config/datanode.example.toml | 2 +- src/common/datasource/src/compression.rs | 1 + tests-integration/tests/http.rs | 2 +- 3 files changed, 3 insertions(+), 2 deletions(-) diff --git a/config/datanode.example.toml b/config/datanode.example.toml index 7793e148ac4c..666430d48175 100644 --- a/config/datanode.example.toml +++ b/config/datanode.example.toml @@ -92,7 +92,7 @@ worker_request_batch_size = 64 # Number of meta action updated to trigger a new checkpoint for the manifest manifest_checkpoint_distance = 10 # Manifest compression type -manifest_compress_type = "Uncompressed" +manifest_compress_type = "uncompressed" # Max number of running background jobs max_background_jobs = 4 # Interval to auto flush a region if it has not flushed yet. diff --git a/src/common/datasource/src/compression.rs b/src/common/datasource/src/compression.rs index 21c566172cbc..bfbc8d5cdd82 100644 --- a/src/common/datasource/src/compression.rs +++ b/src/common/datasource/src/compression.rs @@ -27,6 +27,7 @@ use tokio_util::io::{ReaderStream, StreamReader}; use crate::error::{self, Error, Result}; #[derive(Debug, Clone, Copy, PartialEq, Eq, Hash, EnumIter, Serialize, Deserialize)] +#[serde(rename_all = "lowercase")] pub enum CompressionType { /// Gzip-ed file Gzip, diff --git a/tests-integration/tests/http.rs b/tests-integration/tests/http.rs index 574334de00d7..f6c5fb7e737c 100644 --- a/tests-integration/tests/http.rs +++ b/tests-integration/tests/http.rs @@ -736,7 +736,7 @@ num_workers = {} worker_channel_size = 128 worker_request_batch_size = 64 manifest_checkpoint_distance = 10 -manifest_compress_type = "Uncompressed" +manifest_compress_type = "uncompressed" max_background_jobs = 4 auto_flush_interval = "30m" global_write_buffer_size = "1GiB"