diff options
author | 2023-03-03 23:02:23 +0000 | |
---|---|---|
committer | 2023-03-03 23:02:23 +0000 | |
commit | a8e6bdfa33f3232ebc8f241b9c90e4da9191a627 (patch) | |
tree | 087eca372fb13093f39837683682ca9e11b96188 /internal/config/config.go | |
parent | [bugfix] Federate status delete using just the URI (#1584) (diff) | |
download | gotosocial-a8e6bdfa33f3232ebc8f241b9c90e4da9191a627.tar.xz |
[performance] cache media attachments (#1525)
* replace concurrency worker pools with base models in State.Workers, update code and tests accordingly
* add media attachment caching, slightly tweak default cache config
* further tweak default cache config values
* replace other media attachment db calls to go through cache
* update envparsing test
* fix delete media attachment sql
* fix media sql query
* invalidate cached media entries during status create / update
* fix envparsing test
* fix typo in panic log message...
* add 'updated_at' column during UpdateAttachment
* remove unused func
---------
Signed-off-by: kim <grufwub@gmail.com>
Diffstat (limited to 'internal/config/config.go')
-rw-r--r-- | internal/config/config.go | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/internal/config/config.go b/internal/config/config.go index 5673b76dd..fdfda8583 100644 --- a/internal/config/config.go +++ b/internal/config/config.go @@ -177,6 +177,10 @@ type GTSCacheConfiguration struct { EmojiCategoryTTL time.Duration `name:"emoji-category-ttl"` EmojiCategorySweepFreq time.Duration `name:"emoji-category-sweep-freq"` + MediaMaxSize int `name:"media-max-size"` + MediaTTL time.Duration `name:"media-ttl"` + MediaSweepFreq time.Duration `name:"media-sweep-freq"` + MentionMaxSize int `name:"mention-max-size"` MentionTTL time.Duration `name:"mention-ttl"` MentionSweepFreq time.Duration `name:"mention-sweep-freq"` |