allegro / allegro/bigcache

Why do we need to configure both lifeWindow and cleanWindow?

Aberta
#376 2 comentários 0 reações 0 responsáveis Ver no GitHub
bug question
Linguagem predominante
Go
Estrelas
8.2k
Forks
614
Merge médio
5d 12h
PRs com merge (30d)
1

Descrição

I have a few questions:
1) If I only set cleanWindow (not lifeWindow) what happens to the cache? Can the cache be cleaned?
2) Is it possible to set lifeWindow specifically for a cache created with its key? Because lifeWindow and cleanWindow are both configured in config if applied to all keys, I find lifeWindow and cleanWindow not very meaningful, instead just need 1 parameter like TTL
3) The lifeWindow of a cache has its time reset when accessing that cache again while the lifeWindow is still valid. If not, what is the meaning of lifeWindow (similar to the question in question 2, it only needs 1 parameter)
4) As I see it, if lifeWindow and cleanWindow are set to 10 seconds, the clear time will be the 20th second. My wish is the 10th second. So, I have to set lifeWindow < cleanWindow. I still don't understand the meaning of lifeWindow existence when it could be as simple as just 1 parameter like TTL
5) If I use Delete("key"), will the cache be deleted?
I hope to have an answer soon. Thanks for your support.

Guia de contribuição

Nenhum guia de contribuição indexado para este repositório

Avaliação

Esta issue ainda não foi avaliada.

Receba novas issues na sua caixa de entrada

Um resumo curto de issues do GitHub para quem está começando.