mirror of
https://github.com/kopia/kopia.git
synced 2026-06-10 23:26:42 -04:00
fix(repository): fixed accidental cache directory location change during refactoring (#1866)
This commit is contained in:
3
internal/cache/content_cache.go
vendored
3
internal/cache/content_cache.go
vendored
@@ -2,7 +2,6 @@
|
||||
|
||||
import (
|
||||
"context"
|
||||
"path/filepath"
|
||||
|
||||
"github.com/pkg/errors"
|
||||
|
||||
@@ -185,7 +184,7 @@ func NewContentCache(ctx context.Context, st blob.Storage, opt Options) (Content
|
||||
|
||||
var err error
|
||||
|
||||
cacheStorage, err = NewStorageOrNil(ctx, filepath.Join(opt.BaseCacheDirectory, opt.CacheSubDir), opt.Sweep.MaxSizeBytes, opt.CacheSubDir)
|
||||
cacheStorage, err = NewStorageOrNil(ctx, opt.BaseCacheDirectory, opt.Sweep.MaxSizeBytes, opt.CacheSubDir)
|
||||
if err != nil {
|
||||
return nil, errors.Wrap(err, "error initializing cache storage")
|
||||
}
|
||||
|
||||
@@ -394,6 +394,7 @@ func (sm *SharedManager) setupReadManagerCaches(ctx context.Context, caching *Ca
|
||||
BaseCacheDirectory: caching.CacheDirectory,
|
||||
CacheSubDir: "metadata",
|
||||
HMACSecret: caching.HMACSecret,
|
||||
FetchFullBlobs: true,
|
||||
Sweep: cache.SweepSettings{
|
||||
MaxSizeBytes: metadataCacheSize,
|
||||
MinSweepAge: caching.MinMetadataSweepAge.DurationOrDefault(DefaultMetadataCacheSweepAge),
|
||||
|
||||
Reference in New Issue
Block a user