diff --git a/pkg/local_object_storage/writecache/flush.go b/pkg/local_object_storage/writecache/flush.go index 8dfed50002..4beeb3d7fe 100644 --- a/pkg/local_object_storage/writecache/flush.go +++ b/pkg/local_object_storage/writecache/flush.go @@ -20,8 +20,8 @@ const ( // to the main storage. It is used to reduce contention between cache put // and cache persist. flushBatchSize = 512 - // flushWorkersCount is number of workers for putting objects in main storage. - flushWorkersCount = 20 + // defaultFlushWorkersCount is number of workers for putting objects in main storage. + defaultFlushWorkersCount = 20 // defaultFlushInterval is default time interval between successive flushes. defaultFlushInterval = time.Second ) diff --git a/pkg/local_object_storage/writecache/writecache.go b/pkg/local_object_storage/writecache/writecache.go index 59826370cd..b3335c1a4f 100644 --- a/pkg/local_object_storage/writecache/writecache.go +++ b/pkg/local_object_storage/writecache/writecache.go @@ -96,7 +96,7 @@ func New(opts ...Option) Cache { maxMemSize: maxInMemorySizeBytes, maxObjectSize: maxObjectSize, smallObjectSize: smallObjectSize, - workersCount: flushWorkersCount, + workersCount: defaultFlushWorkersCount, maxCacheSize: maxCacheSizeBytes, }, }