Skip to content

Commit 440ab94

Browse files
authored
Fix passing of redis client cache size (#5734)
1 parent ddcae19 commit 440ab94

File tree

2 files changed

+4
-0
lines changed

2 files changed

+4
-0
lines changed

CHANGELOG.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,7 @@
1515
* [ENHANCEMENT] Query Frontend: Log number of split queries in `query stats` log. #5703
1616
* [BUGFIX] Distributor: Do not use label with empty values for sharding #5717
1717
* [BUGFIX] Query Frontend: queries with negative offset should check whether it is cacheable or not. #5719
18+
* [BUGFIX] Redis Cache: pass `cache_size` config correctly. #5734
1819

1920

2021
## 1.16.0 2023-11-20

pkg/storage/tsdb/redis_client_config.go

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,10 +2,12 @@ package tsdb
22

33
import (
44
"flag"
5+
56
"time"
67

78
"github.com/pkg/errors"
89
"github.com/thanos-io/thanos/pkg/cacheutil"
10+
"github.com/thanos-io/thanos/pkg/model"
911

1012
"github.com/cortexproject/cortex/pkg/util/tls"
1113
)
@@ -97,5 +99,6 @@ func (cfg *RedisClientConfig) ToRedisClientConfig() cacheutil.RedisClientConfig
9799
ServerName: cfg.TLS.ServerName,
98100
InsecureSkipVerify: cfg.TLS.InsecureSkipVerify,
99101
},
102+
CacheSize: model.Bytes(cfg.CacheSize),
100103
}
101104
}

0 commit comments

Comments
 (0)