aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--Cargo.lock37
-rw-r--r--Cargo.nix64
-rw-r--r--script/helm/garage/Chart.yaml2
-rw-r--r--script/helm/garage/values.yaml36
-rw-r--r--src/garage/Cargo.toml2
5 files changed, 36 insertions, 105 deletions
diff --git a/Cargo.lock b/Cargo.lock
index 89d25740..684a9b72 100644
--- a/Cargo.lock
+++ b/Cargo.lock
@@ -1758,15 +1758,6 @@ dependencies = [
]
[[package]]
-name = "isolang"
-version = "2.2.0"
-source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "b64fd6448ee8a45ce6e4365c58e4fa7d8740cba2ed70db3e9ab4879ebd93eaaa"
-dependencies = [
- "phf",
-]
-
-[[package]]
name = "itertools"
version = "0.4.19"
source = "registry+https://github.com/rust-lang/crates.io-index"
@@ -2547,24 +2538,6 @@ dependencies = [
]
[[package]]
-name = "phf"
-version = "0.10.1"
-source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "fabbf1ead8a5bcbc20f5f8b939ee3f5b0f6f281b6ad3468b84656b658b455259"
-dependencies = [
- "phf_shared",
-]
-
-[[package]]
-name = "phf_shared"
-version = "0.10.0"
-source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "b6796ad771acdc0123d2a88dc428b5e38ef24456743ddb1744ed628f9815c096"
-dependencies = [
- "siphasher",
-]
-
-[[package]]
name = "pin-project"
version = "1.0.12"
source = "registry+https://github.com/rust-lang/crates.io-index"
@@ -3407,12 +3380,6 @@ dependencies = [
]
[[package]]
-name = "siphasher"
-version = "0.3.10"
-source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "7bd3e3206899af3f8b12af284fafc038cc1dc2b41d1b89dd17297221c5d225de"
-
-[[package]]
name = "slab"
version = "0.4.7"
source = "registry+https://github.com/rust-lang/crates.io-index"
@@ -3678,10 +3645,6 @@ name = "timeago"
version = "0.4.1"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "5082dc942361cdfb74eab98bf995762d6015e5bb3a20bf7c5c71213778b4fcb4"
-dependencies = [
- "chrono",
- "isolang",
-]
[[package]]
name = "tinyvec"
diff --git a/Cargo.nix b/Cargo.nix
index d9fb0a28..14877083 100644
--- a/Cargo.nix
+++ b/Cargo.nix
@@ -32,7 +32,7 @@ args@{
ignoreLockHash,
}:
let
- nixifiedLockHash = "e7f8df7901f8d217b438e374398eb3d4532e901770070ac5c8343624c0f45ca5";
+ nixifiedLockHash = "fdd68f4fc55534ea423284de294a3da29395e7474a31bc0a8bd0527a2288719f";
workspaceSrc = if args.workspaceSrc == null then ./. else args.workspaceSrc;
currentLockHash = builtins.hashFile "sha256" (workspaceSrc + /Cargo.lock);
lockHashIgnored = if ignoreLockHash
@@ -2450,20 +2450,6 @@ in
};
});
- "registry+https://github.com/rust-lang/crates.io-index".isolang."2.2.0" = overridableMkRustCrate (profileName: rec {
- name = "isolang";
- version = "2.2.0";
- registry = "registry+https://github.com/rust-lang/crates.io-index";
- src = fetchCratesIo { inherit name version; sha256 = "b64fd6448ee8a45ce6e4365c58e4fa7d8740cba2ed70db3e9ab4879ebd93eaaa"; };
- features = builtins.concatLists [
- [ "default" ]
- [ "english_names" ]
- ];
- dependencies = {
- phf = (rustPackages."registry+https://github.com/rust-lang/crates.io-index".phf."0.10.1" { inherit profileName; }).out;
- };
- });
-
"registry+https://github.com/rust-lang/crates.io-index".itertools."0.4.19" = overridableMkRustCrate (profileName: rec {
name = "itertools";
version = "0.4.19";
@@ -3579,33 +3565,6 @@ in
};
});
- "registry+https://github.com/rust-lang/crates.io-index".phf."0.10.1" = overridableMkRustCrate (profileName: rec {
- name = "phf";
- version = "0.10.1";
- registry = "registry+https://github.com/rust-lang/crates.io-index";
- src = fetchCratesIo { inherit name version; sha256 = "fabbf1ead8a5bcbc20f5f8b939ee3f5b0f6f281b6ad3468b84656b658b455259"; };
- features = builtins.concatLists [
- [ "default" ]
- [ "std" ]
- ];
- dependencies = {
- phf_shared = (rustPackages."registry+https://github.com/rust-lang/crates.io-index".phf_shared."0.10.0" { inherit profileName; }).out;
- };
- });
-
- "registry+https://github.com/rust-lang/crates.io-index".phf_shared."0.10.0" = overridableMkRustCrate (profileName: rec {
- name = "phf_shared";
- version = "0.10.0";
- registry = "registry+https://github.com/rust-lang/crates.io-index";
- src = fetchCratesIo { inherit name version; sha256 = "b6796ad771acdc0123d2a88dc428b5e38ef24456743ddb1744ed628f9815c096"; };
- features = builtins.concatLists [
- [ "std" ]
- ];
- dependencies = {
- siphasher = (rustPackages."registry+https://github.com/rust-lang/crates.io-index".siphasher."0.3.10" { inherit profileName; }).out;
- };
- });
-
"registry+https://github.com/rust-lang/crates.io-index".pin-project."1.0.12" = overridableMkRustCrate (profileName: rec {
name = "pin-project";
version = "1.0.12";
@@ -4749,17 +4708,6 @@ in
};
});
- "registry+https://github.com/rust-lang/crates.io-index".siphasher."0.3.10" = overridableMkRustCrate (profileName: rec {
- name = "siphasher";
- version = "0.3.10";
- registry = "registry+https://github.com/rust-lang/crates.io-index";
- src = fetchCratesIo { inherit name version; sha256 = "7bd3e3206899af3f8b12af284fafc038cc1dc2b41d1b89dd17297221c5d225de"; };
- features = builtins.concatLists [
- [ "default" ]
- [ "std" ]
- ];
- });
-
"registry+https://github.com/rust-lang/crates.io-index".slab."0.4.7" = overridableMkRustCrate (profileName: rec {
name = "slab";
version = "0.4.7";
@@ -5100,16 +5048,6 @@ in
version = "0.4.1";
registry = "registry+https://github.com/rust-lang/crates.io-index";
src = fetchCratesIo { inherit name version; sha256 = "5082dc942361cdfb74eab98bf995762d6015e5bb3a20bf7c5c71213778b4fcb4"; };
- features = builtins.concatLists [
- [ "chrono" ]
- [ "default" ]
- [ "isolang" ]
- [ "translations" ]
- ];
- dependencies = {
- chrono = (rustPackages."registry+https://github.com/rust-lang/crates.io-index".chrono."0.4.23" { inherit profileName; }).out;
- isolang = (rustPackages."registry+https://github.com/rust-lang/crates.io-index".isolang."2.2.0" { inherit profileName; }).out;
- };
});
"registry+https://github.com/rust-lang/crates.io-index".tinyvec."1.6.0" = overridableMkRustCrate (profileName: rec {
diff --git a/script/helm/garage/Chart.yaml b/script/helm/garage/Chart.yaml
index 82b2e106..86f1239f 100644
--- a/script/helm/garage/Chart.yaml
+++ b/script/helm/garage/Chart.yaml
@@ -15,7 +15,7 @@ type: application
# This is the chart version. This version number should be incremented each time you make changes
# to the chart and its templates, including the app version.
# Versions are expected to follow Semantic Versioning (https://semver.org/)
-version: 0.4.0
+version: 0.4.1
# This is the version number of the application being deployed. This version number should be
# incremented each time you make changes to the application. Versions are not expected to
diff --git a/script/helm/garage/values.yaml b/script/helm/garage/values.yaml
index 3a1e41b9..02a6651b 100644
--- a/script/helm/garage/values.yaml
+++ b/script/helm/garage/values.yaml
@@ -4,9 +4,28 @@
# Garage configuration. These values go to garage.toml
garage:
+ # Can be changed for better performance on certain systems
+ # https://garagehq.deuxfleurs.fr/documentation/reference-manual/configuration/#db-engine-since-v0-8-0
+ dbEngine: "sled"
+
+ # Defaults is 1MB
+ # An increase can result in better performance in certain scenarios
+ # https://garagehq.deuxfleurs.fr/documentation/reference-manual/configuration/#block-size
+ blockSize: "1048576"
+
+ # Tuning parameters for the sled DB engine
+ # https://garagehq.deuxfleurs.fr/documentation/reference-manual/configuration/#sled-cache-capacity
+ sledCacheCapacity: "134217728"
+ sledFlushEveryMs: "2000"
+
# Default to 3 replicas, see the replication_mode section at
- # https://garagehq.deuxfleurs.fr/documentation/reference-manual/configuration/
+ # https://garagehq.deuxfleurs.fr/documentation/reference-manual/configuration/#replication-mode
replicationMode: "3"
+
+ # zstd compression level of stored blocks
+ # https://garagehq.deuxfleurs.fr/documentation/reference-manual/configuration/#compression-level
+ compressionLevel: "1"
+
rpcBindAddr: "[::]:3901"
# If not given, a random secret will be generated and stored in a Secret object
rpcSecret: ""
@@ -27,8 +46,19 @@ garage:
metadata_dir = "/mnt/meta"
data_dir = "/mnt/data"
+ db_engine = "{{ .Values.garage.dbEngine }}"
+
+ block_size = {{ .Values.garage.blockSize }}
+
+ {{- if eq .Values.garage.dbEngine "sled"}}
+ sled_cache_capacity = {{ .Values.garage.sledCacheCapacity }}
+ sled_flush_every_ms = {{ .Values.garage.sledFlushEveryMs }}
+ {{- end }}
+
replication_mode = "{{ .Values.garage.replicationMode }}"
+ compression_level = {{ .Values.garage.compressionLevel }}
+
rpc_bind_addr = "{{ .Values.garage.rpcBindAddr }}"
# rpc_secret will be populated by the init container from a k8s secret object
rpc_secret = "__RPC_SECRET_REPLACE__"
@@ -49,7 +79,7 @@ garage:
bind_addr = "[::]:3902"
root_domain = "{{ .Values.garage.s3.web.rootDomain }}"
index = "{{ .Values.garage.s3.web.index }}"
-
+
[admin]
api_bind_addr = "[::]:3903"
{{- if .Values.monitoring.tracing.sink }}
@@ -211,4 +241,4 @@ monitoring:
scrapeTimeout: 10s
relabelings: []
tracing:
- sink: "" \ No newline at end of file
+ sink: ""
diff --git a/src/garage/Cargo.toml b/src/garage/Cargo.toml
index 0cbdf890..c8f87560 100644
--- a/src/garage/Cargo.toml
+++ b/src/garage/Cargo.toml
@@ -33,7 +33,7 @@ garage_web = { version = "0.8.2", path = "../web" }
backtrace = "0.3"
bytes = "1.0"
bytesize = "1.1"
-timeago = "0.4"
+timeago = { version = "0.4", default-features = false }
parse_duration = "2.1"
hex = "0.4"
tracing = { version = "0.1" }