parent
a43371d1e3
commit
8b65fed180
12 changed files with 190 additions and 606 deletions
daemons/qbittorrent
|
@ -42,7 +42,7 @@ func wrapClient(qb qbittorrent.Client) *cacheClient {
|
|||
propertiesCache: expirable.NewLRU[string, qbittorrent.TorrentProperties](cacheSize, nil, cacheTTL),
|
||||
|
||||
infoClient: sturdyc.New[*qbittorrent.TorrentInfo](cacheSize, 1, cacheTTL, 10,
|
||||
sturdyc.WithEarlyRefreshes(time.Minute, time.Minute*5, time.Second*10),
|
||||
sturdyc.WithEarlyRefreshes(time.Minute, time.Minute*5, time.Second*10, time.Second*10),
|
||||
sturdyc.WithRefreshCoalescing(100, time.Second/4),
|
||||
sturdyc.WithMetrics(newSturdycMetrics()),
|
||||
),
|
||||
|
@ -251,6 +251,16 @@ func (s *sturdycMetrics) EntriesEvicted(evictd int) {
|
|||
s.entryEviction.Add(s.ctx, int64(evictd))
|
||||
}
|
||||
|
||||
// AsynchronousRefresh implements sturdyc.MetricsRecorder.
|
||||
func (s *sturdycMetrics) AsynchronousRefresh() {
|
||||
return
|
||||
}
|
||||
|
||||
// SynchronousRefresh implements sturdyc.MetricsRecorder.
|
||||
func (s *sturdycMetrics) SynchronousRefresh() {
|
||||
return
|
||||
}
|
||||
|
||||
func (s *sturdycMetrics) ShardIndex(int) {
|
||||
return
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue