diff --git a/githooks/commit-msg b/githooks/commit-msg index 146aed08dfb9..dfb1b02da454 100755 --- a/githooks/commit-msg +++ b/githooks/commit-msg @@ -52,7 +52,7 @@ IFS=' notes=($($grep -iE '^release note' "$1")) # Set this to 1 to require a release justification note. -require_justification=0 +require_justification=1 justification=($($grep -iE '^release justification: \S+' "$1")) IFS=$saveIFS diff --git a/githooks/prepare-commit-msg b/githooks/prepare-commit-msg index 1a24e426bd2a..cb69ded5ce23 100755 --- a/githooks/prepare-commit-msg +++ b/githooks/prepare-commit-msg @@ -2,7 +2,7 @@ # # Prepare the commit message by adding a release note. -require_justification=0 +require_justification=1 set -euo pipefail if [[ "${2-}" = "message" ]]; then diff --git a/pkg/cmd/dev/bench.go b/pkg/cmd/dev/bench.go index 32a86a581e41..f158f02ae8e9 100644 --- a/pkg/cmd/dev/bench.go +++ b/pkg/cmd/dev/bench.go @@ -146,6 +146,7 @@ func (d *dev) bench(cmd *cobra.Command, commandLine []string) error { if benchMem { args = append(args, "--test_arg", "-test.benchmem") } + args = append(args, "--crdb_test_off") if testArgs != "" { goTestArgs, err := d.getGoTestArgs(ctx, testArgs) if err != nil { diff --git a/pkg/cmd/dev/testdata/datadriven/bench b/pkg/cmd/dev/testdata/datadriven/bench index 418ab21d9770..4e553b11d028 100644 --- a/pkg/cmd/dev/testdata/datadriven/bench +++ b/pkg/cmd/dev/testdata/datadriven/bench @@ -1,30 +1,30 @@ exec dev bench pkg/spanconfig/... ---- -bazel test pkg/spanconfig/...:all --test_arg -test.run=- --test_arg -test.bench=. --test_output errors +bazel test pkg/spanconfig/...:all --test_arg -test.run=- --test_arg -test.bench=. --crdb_test_off --test_output errors exec dev bench pkg/sql/parser --filter=BenchmarkParse ---- -bazel test pkg/sql/parser:all --test_arg -test.run=- --test_arg -test.bench=BenchmarkParse --test_sharding_strategy=disabled --test_output errors +bazel test pkg/sql/parser:all --test_arg -test.run=- --test_arg -test.bench=BenchmarkParse --test_sharding_strategy=disabled --crdb_test_off --test_output errors exec dev bench pkg/sql/parser --filter=BenchmarkParse --stream-output ---- -bazel test pkg/sql/parser:all --test_arg -test.run=- --test_arg -test.bench=BenchmarkParse --test_sharding_strategy=disabled --test_output streamed +bazel test pkg/sql/parser:all --test_arg -test.run=- --test_arg -test.bench=BenchmarkParse --test_sharding_strategy=disabled --crdb_test_off --test_output streamed exec dev bench pkg/bench -f=BenchmarkTracing/1node/scan/trace=off --count=2 --bench-time=10x --bench-mem ---- -bazel test pkg/bench:all --test_arg -test.run=- --test_arg -test.bench=BenchmarkTracing/1node/scan/trace=off --test_sharding_strategy=disabled --test_arg -test.count=2 --test_arg -test.benchtime=10x --test_arg -test.benchmem --test_output errors +bazel test pkg/bench:all --test_arg -test.run=- --test_arg -test.bench=BenchmarkTracing/1node/scan/trace=off --test_sharding_strategy=disabled --test_arg -test.count=2 --test_arg -test.benchtime=10x --test_arg -test.benchmem --crdb_test_off --test_output errors exec dev bench pkg/spanconfig/spanconfigkvsubscriber -f=BenchmarkSpanConfigDecoder --cpus=10 --ignore-cache -v --timeout=50s ---- -bazel test --local_cpu_resources=10 --test_timeout=55 --test_arg -test.timeout=50s pkg/spanconfig/spanconfigkvsubscriber:all --nocache_test_results --test_arg -test.run=- --test_arg -test.bench=BenchmarkSpanConfigDecoder --test_sharding_strategy=disabled --test_arg -test.v --test_output all +bazel test --local_cpu_resources=10 --test_timeout=55 --test_arg -test.timeout=50s pkg/spanconfig/spanconfigkvsubscriber:all --nocache_test_results --test_arg -test.run=- --test_arg -test.bench=BenchmarkSpanConfigDecoder --test_sharding_strategy=disabled --test_arg -test.v --crdb_test_off --test_output all exec dev bench pkg/bench -f='BenchmarkTracing/1node/scan/trace=off' --test-args '-test.memprofile=mem.out -test.cpuprofile=cpu.out' ---- bazel info workspace --color=no -bazel test pkg/bench:all --test_arg -test.run=- --test_arg -test.bench=BenchmarkTracing/1node/scan/trace=off --test_sharding_strategy=disabled --test_arg -test.outputdir=crdb-checkout --sandbox_writable_path=crdb-checkout --test_arg -test.memprofile=mem.out --test_arg -test.cpuprofile=cpu.out --test_output errors +bazel test pkg/bench:all --test_arg -test.run=- --test_arg -test.bench=BenchmarkTracing/1node/scan/trace=off --test_sharding_strategy=disabled --crdb_test_off --test_arg -test.outputdir=crdb-checkout --sandbox_writable_path=crdb-checkout --test_arg -test.memprofile=mem.out --test_arg -test.cpuprofile=cpu.out --test_output errors diff --git a/pkg/server/testserver.go b/pkg/server/testserver.go index 504d86af6669..0e2953efe622 100644 --- a/pkg/server/testserver.go +++ b/pkg/server/testserver.go @@ -519,6 +519,10 @@ func (ts *TestServer) maybeStartDefaultTestTenant(ctx context.Context) error { } tempStorageConfig := base.DefaultTestTempStorageConfig(cluster.MakeTestingClusterSettings()) + var useTransactionalDescIDGenerator bool + if knobs, ok := ts.params.Knobs.SQLExecutor.(*sql.ExecutorTestingKnobs); ok { + useTransactionalDescIDGenerator = knobs.UseTransactionalDescIDGenerator + } params := base.TestTenantArgs{ // Currently, all the servers leverage the same tenant ID. We may // want to change this down the road, for more elaborate testing. @@ -537,7 +541,8 @@ func (ts *TestServer) maybeStartDefaultTestTenant(ctx context.Context) error { // successfully. TestingKnobs: base.TestingKnobs{ SQLExecutor: &sql.ExecutorTestingKnobs{ - DeterministicExplain: true, + DeterministicExplain: true, + UseTransactionalDescIDGenerator: useTransactionalDescIDGenerator, }, SQLStatsKnobs: &sqlstats.TestingKnobs{ AOSTClause: "AS OF SYSTEM TIME '-1us'",