forked from TrueCloudLab/frostfs-node
[#762] storage/shard: Try to read headers from write-cache
Shard should try to read object headers from write-cache if it is enabled. Extend `writecache.Cache` interface with `Head` method. Call the method in `Shard.Head` if `Shard.hasWriteCache` returns true. Signed-off-by: Leonard Lyubich <leonard@nspcc.ru>
This commit is contained in:
parent
aa2151fbeb
commit
3f293cb55e
2 changed files with 27 additions and 3 deletions
|
@ -13,6 +13,7 @@ import (
|
|||
// Cache represents write-cache for objects.
|
||||
type Cache interface {
|
||||
Get(*objectSDK.Address) (*object.Object, error)
|
||||
Head(*objectSDK.Address) (*object.Object, error)
|
||||
Delete(*objectSDK.Address) error
|
||||
Put(*object.Object) error
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue