allegro / allegro/bigcache

Reset() don't work

Aperta
#322 2 commenti 0 reazioni 0 assegnatari Vedi su GitHub
bug
Lingua principale
Go
Stelle
8.2k
Fork
614
Merge medio
5g 12h
PR unite (30g)
1

Descrizione

**What is the issue you are having?**
Reset shards no longer works

**What is BigCache doing that it shouldn't?**
Empty the shards.

Using stats method i can see the how many items are in cache
```
cache, initErr := bigcache.NewBigCache(config)
cache.Stats()

Output: {"hits":1222,"misses":2,"delete_hits":0,"delete_misses":0,"collisions":0}
```
but when i run the method Reset to flush the shards, they are not flushed / empty, , in previously versions this method works correctly.

```
cache, initErr := bigcache.NewBigCache(config)
cache.Reset()
```
After i run the Reset() the stats are se same
`Output: {"hits":1222,"misses":2,"delete_hits":0,"delete_misses":0,"collisions":0}`

**Environment:**
- Version (git sha or release): v3@v3.0.2
- OS (e.g. from `/etc/os-release` or winver.exe): Debian GNU/Linux 10 (buster)
- go version: 1.18.3

Guida per i contributori

Nessuna guida per i contributori indicizzata per questo repository

Valutazione

Questa issue non è ancora stata valutata.

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.