summaryrefslogtreecommitdiff
path: root/example
diff options
context:
space:
mode:
authorLibravatar kim <grufwub@gmail.com>2025-11-10 12:36:59 +0100
committerLibravatar tobi <tobi.smethurst@protonmail.com>2025-11-17 14:13:24 +0100
commitac877bde815827f7aa1eeb3a6f0513d4c7503ad0 (patch)
tree7a315d820a5be3232dd5bfc96857017c38e906fd /example
parent[chore] update dependencies (#4542) (diff)
downloadgotosocial-ac877bde815827f7aa1eeb3a6f0513d4c7503ad0.tar.xz
[performance] add optional S3 object info caching (#4546)
This adds an optional S3 object info cache to the S3 storage driver backend (see [here](https://codeberg.org/gruf/go-storage/releases/tag/v0.4.0)) to reduce S3 calls largely during media cleanup operations, but it should also help in other situations cutting back on S3 calls when for example a key is already known to not exist. Reviewed-on: https://codeberg.org/superseriousbusiness/gotosocial/pulls/4546 Co-authored-by: kim <grufwub@gmail.com> Co-committed-by: kim <grufwub@gmail.com>
Diffstat (limited to 'example')
-rw-r--r--example/config.yaml11
1 files changed, 11 insertions, 0 deletions
diff --git a/example/config.yaml b/example/config.yaml
index bf6be2573..a7c679f38 100644
--- a/example/config.yaml
+++ b/example/config.yaml
@@ -288,6 +288,17 @@ cache:
# Default: "100MiB"
memory-target: "100MiB"
+ # cache.s3-object-info (if set) enables caching
+ # of S3 object information in the storage driver.
+ # This can help reduce S3 calls on metered buckets
+ # by caching simple information like whether an
+ # object exists, and if so, its size. Left unset,
+ # the cache will be disabled, which is the default.
+ # The given value determines the cache capacity.
+ # Examples: [0, 8000, 16000, 2560000]
+ # Default: 0
+ s3-object-info: 0
+
######################
##### WEB CONFIG #####
######################