forked from TrueCloudLab/frostfs-node
[#222] Set write cache specific config on application level
Signed-off-by: Alex Vanin <alexey@nspcc.ru>
This commit is contained in:
parent
af2719689d
commit
3d77fdb347
3 changed files with 5 additions and 5 deletions
|
@ -531,6 +531,8 @@ func initShardOptions(c *cfg) {
|
|||
shard.WithWriteCache(useCache),
|
||||
shard.WithWriteCacheOptions(
|
||||
blobstor.WithRootPath(writeCachePath),
|
||||
blobstor.WithBlobovniczaShallowDepth(0),
|
||||
blobstor.WithBlobovniczaShallowWidth(1),
|
||||
),
|
||||
})
|
||||
|
||||
|
|
|
@ -53,11 +53,7 @@ func New(opts ...Option) *Shard {
|
|||
|
||||
if c.useWriteCache {
|
||||
writeCache = blobstor.New(
|
||||
append(c.blobOpts, append(
|
||||
c.writeCacheOpts,
|
||||
blobstor.WithBlobovniczaShallowDepth(0),
|
||||
blobstor.WithBlobovniczaShallowWidth(1))...,
|
||||
)...,
|
||||
append(c.blobOpts, c.writeCacheOpts...)...,
|
||||
)
|
||||
}
|
||||
|
||||
|
|
|
@ -42,6 +42,8 @@ func newShard(t testing.TB, enableWriteCache bool) *shard.Shard {
|
|||
shard.WithWriteCache(enableWriteCache),
|
||||
shard.WithWriteCacheOptions(
|
||||
blobstor.WithRootPath(path.Join(rootPath, "wcache")),
|
||||
blobstor.WithBlobovniczaShallowWidth(1),
|
||||
blobstor.WithBlobovniczaShallowDepth(0),
|
||||
),
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue