From 0c7754da63f49e415285cdc44a3fca8e7dd5262c Mon Sep 17 00:00:00 2001 From: Matt Joiner Date: Mon, 10 Jan 2022 16:20:03 +1100 Subject: [PATCH] Add const noCacheBlobs in sqlite storage benchmarks --- storage/sqlite/sqlite-storage_test.go | 3 +++ 1 file changed, 3 insertions(+) diff --git a/storage/sqlite/sqlite-storage_test.go b/storage/sqlite/sqlite-storage_test.go index 2116c01b..e63f7bc8 100644 --- a/storage/sqlite/sqlite-storage_test.go +++ b/storage/sqlite/sqlite-storage_test.go @@ -18,6 +18,7 @@ import ( func BenchmarkMarkComplete(b *testing.B) { const pieceSize = test_storage.DefaultPieceSize const noTriggers = false + const noCacheBlobs = false var capacity int64 = test_storage.DefaultNumPieces * pieceSize / 2 if noTriggers { // Since we won't push out old pieces, we have to mark them incomplete manually. @@ -31,6 +32,7 @@ func BenchmarkMarkComplete(b *testing.B) { var opts squirrel.NewCacheOpts opts.Capacity = capacity opts.NoTriggers = noTriggers + opts.NoCacheBlobs = noCacheBlobs benchOpts := func(b *testing.B) { opts.Path = filepath.Join(b.TempDir(), "storage.db") ci, err := NewDirectStorage(opts) @@ -49,6 +51,7 @@ func BenchmarkMarkComplete(b *testing.B) { // opts.GcBlobs = true opts.BlobFlushInterval = time.Second opts.NoTriggers = noTriggers + opts.NoCacheBlobs = noCacheBlobs directBench := func(b *testing.B) { opts.Path = filepath.Join(b.TempDir(), "storage.db") ci, err := NewDirectStorage(opts) -- 2.48.1