forked from TrueCloudLab/frostfs-node
[#1437] node: Fix contextcheck linter
Signed-off-by: Dmitrii Stepanov <d.stepanov@yadro.com>
This commit is contained in:
parent
6921a89061
commit
7429553266
209 changed files with 1068 additions and 1036 deletions
|
@ -32,7 +32,7 @@ func newDBCache(parentCtx context.Context, size int,
|
|||
ch := cache.NewCache[string, *sharedDB]().
|
||||
WithTTL(ttl).WithLRU().WithMaxKeys(size).
|
||||
WithOnEvicted(func(_ string, db *sharedDB) {
|
||||
db.Close()
|
||||
db.Close(parentCtx)
|
||||
})
|
||||
ctx, cancel := context.WithCancel(parentCtx)
|
||||
res := &dbCache{
|
||||
|
@ -138,7 +138,7 @@ func (c *dbCache) create(ctx context.Context, path string) *sharedDB {
|
|||
return value
|
||||
}
|
||||
if added := c.put(path, value); !added {
|
||||
value.Close()
|
||||
value.Close(ctx)
|
||||
}
|
||||
return value
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue