From efc2cd52308b290d210758e682cb6d9975416d42 Mon Sep 17 00:00:00 2001 From: Rafi Shamim Date: Wed, 6 Mar 2024 12:56:36 -0500 Subject: [PATCH] logictest: update cache size for on-disk logictest configs The default cache size is 128MB. This can result in a lot of disk-related slowdowns for normal operations. Now we configure a larger cache so that we avoid disk access. Release note: None --- DEPS.bzl | 6 +++--- build/bazelutil/distdir_files.bzl | 2 +- go.mod | 2 +- go.sum | 4 ++-- pkg/sql/logictest/logic.go | 1 + 5 files changed, 8 insertions(+), 7 deletions(-) diff --git a/DEPS.bzl b/DEPS.bzl index 14d08385d3b8..a3652c1c73c6 100644 --- a/DEPS.bzl +++ b/DEPS.bzl @@ -1590,10 +1590,10 @@ def go_deps(): name = "com_github_cockroachdb_cockroach_go_v2", build_file_proto_mode = "disable_global", importpath = "github.com/cockroachdb/cockroach-go/v2", - sha256 = "70860a2615f3df73f7d00b4801b1fffe30a3306ae1cda1e9bf5245bb74e86d9a", - strip_prefix = "github.com/cockroachdb/cockroach-go/v2@v2.3.5", + sha256 = "028c29c79c2d373bca3ce9a475291285fdcb68a2f908190f738d5ce605edbd07", + strip_prefix = "github.com/cockroachdb/cockroach-go/v2@v2.3.7", urls = [ - "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/cockroachdb/cockroach-go/v2/com_github_cockroachdb_cockroach_go_v2-v2.3.5.zip", + "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/cockroachdb/cockroach-go/v2/com_github_cockroachdb_cockroach_go_v2-v2.3.7.zip", ], ) go_repository( diff --git a/build/bazelutil/distdir_files.bzl b/build/bazelutil/distdir_files.bzl index 16a36f6b0346..d0e3b9ad2e53 100644 --- a/build/bazelutil/distdir_files.bzl +++ b/build/bazelutil/distdir_files.bzl @@ -321,7 +321,7 @@ DISTDIR_FILES = { "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/cockroachdb/apd/v3/com_github_cockroachdb_apd_v3-v3.2.1.zip": "6ad54bb71a36fba8ca6725a00d916e51815a4c68de54096313ca6fffda6c87c2", "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/cockroachdb/bubbletea/com_github_cockroachdb_bubbletea-v0.23.1-bracketed-paste2.zip": "d7916a0e7d8d814566e8f8d162c3764aea947296396a0a669564ff3ee53414bc", "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/cockroachdb/cmux/com_github_cockroachdb_cmux-v0.0.0-20170110192607-30d10be49292.zip": "88f6f9cf33eb535658540b46f6222f029398e590a3ff9cc873d7d561ac6debf0", - "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/cockroachdb/cockroach-go/v2/com_github_cockroachdb_cockroach_go_v2-v2.3.5.zip": "70860a2615f3df73f7d00b4801b1fffe30a3306ae1cda1e9bf5245bb74e86d9a", + "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/cockroachdb/cockroach-go/v2/com_github_cockroachdb_cockroach_go_v2-v2.3.7.zip": "028c29c79c2d373bca3ce9a475291285fdcb68a2f908190f738d5ce605edbd07", "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/cockroachdb/crlfmt/com_github_cockroachdb_crlfmt-v0.0.0-20221214225007-b2fc5c302548.zip": "fedc01bdd6d964da0425d5eaac8efadc951e78e13f102292cc0774197f09ab63", "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/cockroachdb/datadriven/com_github_cockroachdb_datadriven-v1.0.3-0.20230801171734-e384cf455877.zip": "3f1ac51e496ac26ae297c9846bb78eb416fd50b7566b892fb7087af9273766fe", "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/cockroachdb/errors/com_github_cockroachdb_errors-v1.11.1.zip": "6c8101703839a0d69685485d3d0d6040f51b83382bbc53c362c47732246249bf", diff --git a/go.mod b/go.mod index d00d1f922dc2..73d759867ccc 100644 --- a/go.mod +++ b/go.mod @@ -117,7 +117,7 @@ require ( github.com/client9/misspell v0.3.4 github.com/cockroachdb/apd/v3 v3.2.1 github.com/cockroachdb/cmux v0.0.0-20170110192607-30d10be49292 - github.com/cockroachdb/cockroach-go/v2 v2.3.5 + github.com/cockroachdb/cockroach-go/v2 v2.3.7 github.com/cockroachdb/crlfmt v0.0.0-20221214225007-b2fc5c302548 github.com/cockroachdb/datadriven v1.0.3-0.20230801171734-e384cf455877 github.com/cockroachdb/errors v1.11.1 diff --git a/go.sum b/go.sum index c8d39a4bdf46..dda9008df15a 100644 --- a/go.sum +++ b/go.sum @@ -486,8 +486,8 @@ github.com/cockroachdb/bubbletea v0.23.1-bracketed-paste2 h1:OmQDBlTg1DU5OaKjIuE github.com/cockroachdb/bubbletea v0.23.1-bracketed-paste2/go.mod h1:JAfGK/3/pPKHTnAS8JIE2u9f61BjWTQY57RbT25aMXU= github.com/cockroachdb/cmux v0.0.0-20170110192607-30d10be49292 h1:dzj1/xcivGjNPwwifh/dWTczkwcuqsXXFHY1X/TZMtw= github.com/cockroachdb/cmux v0.0.0-20170110192607-30d10be49292/go.mod h1:qRiX68mZX1lGBkTWyp3CLcenw9I94W2dLeRvMzcn9N4= -github.com/cockroachdb/cockroach-go/v2 v2.3.5 h1:Khtm8K6fTTz/ZCWPzU9Ne3aOW9VyAnj4qIPCJgKtwK0= -github.com/cockroachdb/cockroach-go/v2 v2.3.5/go.mod h1:1wNJ45eSXW9AnOc3skntW9ZUZz6gxrQK3cOj3rK+BC8= +github.com/cockroachdb/cockroach-go/v2 v2.3.7 h1:nq5GYDuA2zIR/kdLkVLTg7oHTw0UbGU9RWpC+OZVYYU= +github.com/cockroachdb/cockroach-go/v2 v2.3.7/go.mod h1:1wNJ45eSXW9AnOc3skntW9ZUZz6gxrQK3cOj3rK+BC8= github.com/cockroachdb/crlfmt v0.0.0-20221214225007-b2fc5c302548 h1:i0bnjanlWAvM50wHMT7EFyxlt5HQusznWrkwl+HBIsU= github.com/cockroachdb/crlfmt v0.0.0-20221214225007-b2fc5c302548/go.mod h1:qtkxNlt5i3rrdirfJE/bQeW/IeLajKexErv7jEIV+Uc= github.com/cockroachdb/datadriven v0.0.0-20190809214429-80d97fb3cbaa/go.mod h1:zn76sxSg3SzpJ0PPJaLDCu+Bu0Lg3sKTORVIj19EIF8= diff --git a/pkg/sql/logictest/logic.go b/pkg/sql/logictest/logic.go index 1ebb08aad4ca..6327ae751d87 100644 --- a/pkg/sql/logictest/logic.go +++ b/pkg/sql/logictest/logic.go @@ -1321,6 +1321,7 @@ func (t *logicTest) newTestServerCluster(bootstrapBinaryPath, upgradeBinaryPath opts := []testserver.TestServerOpt{ testserver.ThreeNodeOpt(), testserver.StoreOnDiskOpt(), + testserver.CacheSizeOpt(0.1), testserver.CockroachBinaryPathOpt(bootstrapBinaryPath), testserver.UpgradeCockroachBinaryPathOpt(upgradeBinaryPath), testserver.PollListenURLTimeoutOpt(120),