From e5a40b90b640e8de65e4d9bde1d85a5a0863dfc9 Mon Sep 17 00:00:00 2001 From: Evgenii Stratonikov Date: Tue, 27 Dec 2022 10:08:01 +0300 Subject: [PATCH] [#2176] neofs-node: `Peek` during cache invalidation `Get` needs write mutex and makes our item move to top. Signed-off-by: Evgenii Stratonikov --- cmd/frostfs-node/cache.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/cmd/frostfs-node/cache.go b/cmd/frostfs-node/cache.go index 1cc28702..713eaf02 100644 --- a/cmd/frostfs-node/cache.go +++ b/cmd/frostfs-node/cache.go @@ -287,7 +287,7 @@ func (s ttlContainerLister) List(id *user.ID) ([]cid.ID, error) { func (s *ttlContainerLister) update(owner user.ID, cnr cid.ID, add bool) { strOwner := owner.EncodeToString() - val, ok := s.cache.Get(strOwner) + val, ok := s.cache.Peek(strOwner) if !ok { // we could cache the single cnr but in this case we will disperse // with the Sidechain a lot