Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
140409: metric: remove mutex around windowed histogram update r=dhartunian a=dhartunian

Previously, we used an `RWMutex` to serialize access to the windowed histogram. This was done because there's a rotation that needs to happen that moves the currently active histogram into the `prev` variable and creates a fresh one to update in `cur`. This is done to maintain the window.

This change limits the mutex usage to rotation and window snapshotting, removing the need to take a read lock during updates since we can atomically grab the `cur` histogram.

There's a bit of nuance to manage around the fact that `prev` can be nil on the first iteration, since `cur` is the first histogram. After a single rotation, `prev` will not be nil again.

The prometheus histogram itself (what's stored in the `atomic.Value`) is thread-safe.

```
old:  dhartunian@507c68f Merge #140092
new:  dhartunian@ff9dd52 metric: remove mutex around windowed histogram upd
args: benchdiff "./pkg/util/metric" "-b" "-r" "BenchmarkHistogramRecordValue" "-c" "10" "--preview"

name                                     old time/op    new time/op    delta
HistogramRecordValue/insert_zero-10        30.7ns ± 8%    24.3ns ± 2%  -20.94%  (p=0.000 n=9+8)
HistogramRecordValue/insert_integers-10    37.4ns ± 6%    33.8ns ± 1%   -9.83%  (p=0.000 n=8+8)
HistogramRecordValue/random_integers-10    44.9ns ± 9%    41.7ns ± 1%   -7.25%  (p=0.000 n=8+8)

name                                     old alloc/op   new alloc/op   delta
HistogramRecordValue/insert_integers-10     0.00B          0.00B          ~     (all equal)
HistogramRecordValue/insert_zero-10         0.00B          0.00B          ~     (all equal)
HistogramRecordValue/random_integers-10     0.00B          0.00B          ~     (all equal)

name                                     old allocs/op  new allocs/op  delta
HistogramRecordValue/insert_integers-10      0.00           0.00          ~     (all equal)
HistogramRecordValue/insert_zero-10          0.00           0.00          ~     (all equal)
HistogramRecordValue/random_integers-10      0.00           0.00          ~     (all equal)
```

Part of #133306

Release note: None

140676: backup: disable autocommit_before_ddl for backup tests r=rafiss a=rafiss

The autocommit behavior causes some flakiness in the remote CI environment. When the cluster is overloaded, transactions that perform schema changes are more likely to be aborted since they don't heartbeat frequently enough. This means they get aborted when they are pushed by background transactions such as the spanconfig reconciler and the job registry "reclaim jobs" task.

Also, keeping schema changes in transactions makes some test setup faster.

fixes #140354
fixes #140346
fixes #140334
fixes #140333
fixes #140550

Release note: None

Co-authored-by: David Hartunian <[email protected]>
Co-authored-by: Rafi Shamim <[email protected]>
  • Loading branch information
3 people committed Feb 7, 2025
3 parents cf3cf8f + 539487b + 1f751cf commit 0effe73
Show file tree
Hide file tree
Showing 60 changed files with 34 additions and 217 deletions.
2 changes: 0 additions & 2 deletions pkg/backup/backup_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -2700,8 +2700,6 @@ func TestBackupRestoreDuringUserDefinedTypeChange(t *testing.T) {
defer cleanupFn()

// Create a database with a type.
sqlDB.Exec(t, "SET CLUSTER SETTING sql.defaults.autocommit_before_ddl.enabled = false")
sqlDB.Exec(t, "SET autocommit_before_ddl = false")
sqlDB.Exec(t, `
CREATE DATABASE d;
CREATE TYPE d.greeting AS ENUM ('hello', 'howdy', 'hi');
Expand Down
5 changes: 5 additions & 0 deletions pkg/backup/backuptestutils/testutils.go
Original file line number Diff line number Diff line change
Expand Up @@ -150,6 +150,11 @@ func StartBackupRestoreTestCluster(
sqlDB.Exec(t, `SET CLUSTER SETTING kv.bulk_ingest.pk_buffer_size = '16MiB'`)
sqlDB.Exec(t, `SET CLUSTER SETTING kv.bulk_ingest.index_buffer_size = '16MiB'`)

// Disable autocommit before DDLs in order to make schema changes during
// test setup faster.
sqlDB.Exec(t, `SET CLUSTER SETTING sql.defaults.autocommit_before_ddl.enabled = 'false'`)
sqlDB.Exec(t, "SET autocommit_before_ddl = false")

// Set the max buffer size to something low to prevent
// backup/restore tests from hitting OOM errors. If any test
// cares about this setting in particular, they will override
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -103,7 +103,6 @@ exec-sql
create user testuser;
grant admin to testuser;
----
NOTICE: auto-committing transaction before processing DDL due to autocommit_before_ddl setting

# Cluster backup as a non-admin user should fail.
exec-sql user=testuser
Expand Down
4 changes: 0 additions & 4 deletions pkg/backup/testdata/backup-restore/backup-dropped-descriptors
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,6 @@ exec-sql
CREATE DATABASE d;
CREATE TABLE d.foo (id INT);
----
NOTICE: auto-committing transaction before processing DDL due to autocommit_before_ddl setting

let $d_id
SELECT id FROM system.namespace WHERE name = 'd' AND "parentID" = 0;
Expand Down Expand Up @@ -60,7 +59,6 @@ exec-sql
CREATE DATABASE d;
CREATE TABLE d.bar (id INT);
----
NOTICE: auto-committing transaction before processing DDL due to autocommit_before_ddl setting

# A database backup should succeed since we have a public database descriptor that matches the
# target.
Expand Down Expand Up @@ -127,8 +125,6 @@ CREATE TYPE d2.typ AS ENUM ('hello');
CREATE SCHEMA d2.s;
CREATE TABLE d2.s.t (id INT);
----
NOTICE: auto-committing transaction before processing DDL due to autocommit_before_ddl setting
NOTICE: auto-committing transaction before processing DDL due to autocommit_before_ddl setting

let $d2_id
SELECT id FROM system.namespace WHERE name = 'd2' AND "parentID" = 0;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,8 +18,6 @@ CREATE DATABASE dd;
CREATE TABLE dd.foo (id INT);
CREATE SCHEMA dd.s;
----
NOTICE: auto-committing transaction before processing DDL due to autocommit_before_ddl setting
NOTICE: auto-committing transaction before processing DDL due to autocommit_before_ddl setting

let $dd_id
SELECT id FROM system.namespace WHERE name = 'dd' AND "parentID" = 0;
Expand Down Expand Up @@ -80,8 +78,6 @@ CREATE TYPE d2.typ AS ENUM ('hello');
CREATE SCHEMA d2.s;
CREATE TABLE d2.s.t (id INT);
----
NOTICE: auto-committing transaction before processing DDL due to autocommit_before_ddl setting
NOTICE: auto-committing transaction before processing DDL due to autocommit_before_ddl setting

let $d2_id
SELECT id FROM system.namespace WHERE name = 'd2' AND "parentID" = 0;
Expand Down
7 changes: 0 additions & 7 deletions pkg/backup/testdata/backup-restore/backup-permissions
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,6 @@ CREATE DATABASE d;
CREATE TABLE d.t (x INT);
INSERT INTO d.t VALUES (1), (2), (3);
----
NOTICE: auto-committing transaction before processing DDL due to autocommit_before_ddl setting

# BACKUP is not allowed in a batch-statement.
exec-sql
Expand All @@ -26,7 +25,6 @@ exec-sql
CREATE USER testuser;
GRANT ADMIN TO testuser;
----
NOTICE: auto-committing transaction before processing DDL due to autocommit_before_ddl setting

exec-sql user=testuser
BACKUP INTO 'userfile:///test-nonroot-cluster';
Expand Down Expand Up @@ -101,7 +99,6 @@ exec-sql
CREATE SCHEMA d.foo;
CREATE TYPE d.foo.type1 AS ENUM()
----
NOTICE: auto-committing transaction before processing DDL due to autocommit_before_ddl setting

# Backup should succeed!
exec-sql user=testuser
Expand All @@ -121,7 +118,6 @@ exec-sql
USE d;
ALTER DEFAULT PRIVILEGES IN SCHEMA public GRANT BACKUP ON TABLES TO testuser;
----
NOTICE: auto-committing transaction before processing DDL due to autocommit_before_ddl setting

exec-sql
CREATE TABLE d.t2 (id INT)
Expand All @@ -147,8 +143,6 @@ REVOKE BACKUP ON DATABASE d FROM testuser;
REVOKE BACKUP ON TABLE d.t2 FROM testuser;
REVOKE BACKUP ON TABLE d.t3 FROM testuser;
----
NOTICE: auto-committing transaction before processing DDL due to autocommit_before_ddl setting
NOTICE: auto-committing transaction before processing DDL due to autocommit_before_ddl setting

subtest end

Expand Down Expand Up @@ -264,7 +258,6 @@ USE d_test_fn;
CREATE FUNCTION f() RETURNS INT LANGUAGE SQL AS $$ SELECT 1 $$;
USE d;
----
NOTICE: auto-committing transaction before processing DDL due to autocommit_before_ddl setting

# Cluster backup should succeed as a root user.
exec-sql
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,6 @@ REVOKE CONNECT ON DATABASE d FROM public;
CREATE TABLE d.t (x INT);
INSERT INTO d.t VALUES (1), (2), (3);
----
NOTICE: auto-committing transaction before processing DDL due to autocommit_before_ddl setting
NOTICE: auto-committing transaction before processing DDL due to autocommit_before_ddl setting

# BACKUP is not allowed in a batch-statement.
exec-sql
Expand All @@ -28,7 +26,6 @@ exec-sql
CREATE USER testuser;
GRANT ADMIN TO testuser;
----
NOTICE: auto-committing transaction before processing DDL due to autocommit_before_ddl setting

exec-sql user=testuser
BACKUP INTO 'nodelocal://1/test-nonroot-cluster';
Expand All @@ -55,8 +52,6 @@ REVOKE CONNECT ON DATABASE d2 FROM public;
CREATE TABLE d2.t (x INT);
INSERT INTO d2.t VALUES (1), (2), (3);
----
NOTICE: auto-committing transaction before processing DDL due to autocommit_before_ddl setting
NOTICE: auto-committing transaction before processing DDL due to autocommit_before_ddl setting

exec-sql
CREATE USER testuser
Expand Down Expand Up @@ -113,7 +108,6 @@ exec-sql
CREATE TYPE d2.greeting AS ENUM ('hello', 'hiya');
REVOKE USAGE ON TYPE d2.greeting FROM public;
----
NOTICE: auto-committing transaction before processing DDL due to autocommit_before_ddl setting

# Type backup as a non-admin user should have USAGE privileges.
exec-sql user=testuser
Expand Down
1 change: 0 additions & 1 deletion pkg/backup/testdata/backup-restore/column-families
Original file line number Diff line number Diff line change
Expand Up @@ -45,4 +45,3 @@ CREATE DATABASE r1;
exec-sql
RESTORE cfs FROM LATEST IN 'nodelocal://1/foo' WITH into_db='r1';
----

1 change: 0 additions & 1 deletion pkg/backup/testdata/backup-restore/descriptor-broadening
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,6 @@ exec-sql
CREATE DATABASE db1;
CREATE DATABASE db2;
----
NOTICE: auto-committing transaction before processing DDL due to autocommit_before_ddl setting

exec-sql
CREATE TABLE db1.t (a INT);
Expand Down
7 changes: 0 additions & 7 deletions pkg/backup/testdata/backup-restore/descriptor-conflicts
Original file line number Diff line number Diff line change
Expand Up @@ -21,13 +21,6 @@ COMMENT ON TABLE foo.bar.bat IS 'should survive';
CREATE ROLE hamburger;
ALTER ROLE hamburger IN DATABASE foo SET application_name='helper';
----
NOTICE: auto-committing transaction before processing DDL due to autocommit_before_ddl setting
NOTICE: auto-committing transaction before processing DDL due to autocommit_before_ddl setting
NOTICE: auto-committing transaction before processing DDL due to autocommit_before_ddl setting
NOTICE: auto-committing transaction before processing DDL due to autocommit_before_ddl setting
NOTICE: auto-committing transaction before processing DDL due to autocommit_before_ddl setting
NOTICE: auto-committing transaction before processing DDL due to autocommit_before_ddl setting
NOTICE: auto-committing transaction before processing DDL due to autocommit_before_ddl setting

exec-sql
BACKUP INTO 'nodelocal://1/conflicting-descriptors';
Expand Down
1 change: 0 additions & 1 deletion pkg/backup/testdata/backup-restore/drop-schedule-backup
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,6 @@ CREATE DATABASE foo;
CREATE TABLE foo.t (x INT);
INSERT INTO foo.t VALUES (1), (2), (3);
----
NOTICE: auto-committing transaction before processing DDL due to autocommit_before_ddl setting

exec-sql
CREATE SCHEDULE 'hello' FOR BACKUP DATABASE foo INTO 'userfile:///newbackup' WITH revision_history RECURRING '@daily';
Expand Down
2 changes: 0 additions & 2 deletions pkg/backup/testdata/backup-restore/encrypted-backups
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,6 @@ CREATE TABLE foo (i INT PRIMARY KEY, s STRING);
CREATE TABLE baz (i INT PRIMARY KEY, s STRING);
INSERT INTO baz VALUES (1, 'x'),(2,'y'),(3,'z');
----
NOTICE: auto-committing transaction before processing DDL due to autocommit_before_ddl setting
NOTICE: auto-committing transaction before processing DDL due to autocommit_before_ddl setting

exec-sql
BACKUP INTO 'nodelocal://1/full' WITH encryption_passphrase='123';
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,6 @@ CREATE SCHEMA d.schema;
CREATE TABLE d.schema.foo (id INT PRIMARY KEY);
INSERT INTO d.schema.foo VALUES (1), (2), (3);
----
NOTICE: auto-committing transaction before processing DDL due to autocommit_before_ddl setting
NOTICE: auto-committing transaction before processing DDL due to autocommit_before_ddl setting

# Cluster backup.
exec-sql
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,6 @@ exec-sql
CREATE DATABASE failsdb;
GRANT CREATE ON DATABASE failsdb TO testuser;
----
NOTICE: auto-committing transaction before processing DDL due to autocommit_before_ddl setting

exec-sql user=testuser
RESTORE TABLE foo FROM LATEST IN 'external://testuser-ec' WITH into_db=failsdb;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,6 @@ CREATE SCHEMA d.schema;
CREATE TABLE d.schema.foo (id INT PRIMARY KEY);
INSERT INTO d.schema.foo VALUES (1), (2), (3);
----
NOTICE: auto-committing transaction before processing DDL due to autocommit_before_ddl setting
NOTICE: auto-committing transaction before processing DDL due to autocommit_before_ddl setting

# Cluster backup.
exec-sql
Expand Down
1 change: 0 additions & 1 deletion pkg/backup/testdata/backup-restore/feature-flags
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,6 @@ CREATE DATABASE d;
CREATE TABLE d.t (x INT);
INSERT INTO d.t VALUES (1), (2), (3);
----
NOTICE: auto-committing transaction before processing DDL due to autocommit_before_ddl setting

# Test running backup when BACKUP feature flag is disabled.
exec-sql
Expand Down
2 changes: 0 additions & 2 deletions pkg/backup/testdata/backup-restore/import-epoch
Original file line number Diff line number Diff line change
Expand Up @@ -16,8 +16,6 @@ CREATE TABLE foo (i INT PRIMARY KEY, s STRING);
CREATE TABLE baz (i INT PRIMARY KEY, s STRING);
INSERT INTO baz VALUES (1, 'x'),(2,'y'),(3,'z');
----
NOTICE: auto-committing transaction before processing DDL due to autocommit_before_ddl setting
NOTICE: auto-committing transaction before processing DDL due to autocommit_before_ddl setting

let $d_id
SELECT id FROM system.namespace WHERE name = 'foo'
Expand Down
2 changes: 0 additions & 2 deletions pkg/backup/testdata/backup-restore/import-start-time
Original file line number Diff line number Diff line change
Expand Up @@ -15,8 +15,6 @@ CREATE TABLE foo (i INT PRIMARY KEY, s STRING);
CREATE TABLE baz (i INT PRIMARY KEY, s STRING);
INSERT INTO baz VALUES (1, 'x'),(2,'y'),(3,'z');
----
NOTICE: auto-committing transaction before processing DDL due to autocommit_before_ddl setting
NOTICE: auto-committing transaction before processing DDL due to autocommit_before_ddl setting


exec-sql
Expand Down
10 changes: 0 additions & 10 deletions pkg/backup/testdata/backup-restore/in-progress-import-rollback
Original file line number Diff line number Diff line change
Expand Up @@ -25,11 +25,6 @@ INSERT INTO foofoo VALUES (10, 'x0');
CREATE TABLE baz (i INT PRIMARY KEY, s STRING);
INSERT INTO baz VALUES (1, 'x'),(2,'y'),(3,'z');
----
NOTICE: auto-committing transaction before processing DDL due to autocommit_before_ddl setting
NOTICE: auto-committing transaction before processing DDL due to autocommit_before_ddl setting
NOTICE: auto-committing transaction before processing DDL due to autocommit_before_ddl setting
NOTICE: auto-committing transaction before processing DDL due to autocommit_before_ddl setting
NOTICE: auto-committing transaction before processing DDL due to autocommit_before_ddl setting

exec-sql
SET CLUSTER SETTING jobs.debug.pausepoints = 'import.after_ingest';
Expand Down Expand Up @@ -227,10 +222,6 @@ CREATE INDEX foo2_to_drop_idx ON foo2 (s);
CREATE TABLE foofoo2 (i INT PRIMARY KEY, s STRING);
INSERT INTO foofoo2 VALUES (10, 'x0');
----
NOTICE: auto-committing transaction before processing DDL due to autocommit_before_ddl setting
NOTICE: auto-committing transaction before processing DDL due to autocommit_before_ddl setting
NOTICE: auto-committing transaction before processing DDL due to autocommit_before_ddl setting
NOTICE: auto-committing transaction before processing DDL due to autocommit_before_ddl setting

exec-sql
SET CLUSTER SETTING jobs.debug.pausepoints = 'import.after_ingest';
Expand Down Expand Up @@ -400,7 +391,6 @@ USE re_restore_test;
CREATE TABLE tab1 (i INT PRIMARY KEY, s STRING);
INSERT INTO tab1 VALUES (42, 'pre-import');
----
NOTICE: auto-committing transaction before processing DDL due to autocommit_before_ddl setting

query-sql
SELECT * FROM re_restore_test.tab1;
Expand Down
3 changes: 0 additions & 3 deletions pkg/backup/testdata/backup-restore/in-progress-imports
Original file line number Diff line number Diff line change
Expand Up @@ -18,9 +18,6 @@ INSERT INTO foofoo VALUES (10, 'x0');
CREATE TABLE baz (i INT PRIMARY KEY, s STRING);
INSERT INTO baz VALUES (1, 'x'),(2,'y'),(3,'z');
----
NOTICE: auto-committing transaction before processing DDL due to autocommit_before_ddl setting
NOTICE: auto-committing transaction before processing DDL due to autocommit_before_ddl setting
NOTICE: auto-committing transaction before processing DDL due to autocommit_before_ddl setting


exec-sql
Expand Down
5 changes: 0 additions & 5 deletions pkg/backup/testdata/backup-restore/in-progress-restores
Original file line number Diff line number Diff line change
Expand Up @@ -30,11 +30,6 @@ INSERT INTO me.baz VALUES (1,'howdy'), (2,'hello'), (3,'heyyy');
CREATE DATABASE d;
USE d;
----
NOTICE: auto-committing transaction before processing DDL due to autocommit_before_ddl setting
NOTICE: auto-committing transaction before processing DDL due to autocommit_before_ddl setting
NOTICE: auto-committing transaction before processing DDL due to autocommit_before_ddl setting
NOTICE: auto-committing transaction before processing DDL due to autocommit_before_ddl setting
NOTICE: auto-committing transaction before processing DDL due to autocommit_before_ddl setting


# Run a backup to then restore from and test that future backups capture the
Expand Down
2 changes: 0 additions & 2 deletions pkg/backup/testdata/backup-restore/materialized_view
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,6 @@ CREATE TABLE testdb.t (a int primary key, b int);
CREATE MATERIALIZED VIEW testdb.mv AS SELECT a, b FROM testdb.t;
INSERT INTO testdb.t (a, b) VALUES (1, 2);
----
NOTICE: auto-committing transaction before processing DDL due to autocommit_before_ddl setting
NOTICE: auto-committing transaction before processing DDL due to autocommit_before_ddl setting

exec-sql
REFRESH MATERIALIZED VIEW mv;
Expand Down
1 change: 0 additions & 1 deletion pkg/backup/testdata/backup-restore/max-row-size
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,6 @@ USE orig;
CREATE TABLE maxrow (i INT PRIMARY KEY, s STRING);
INSERT INTO maxrow VALUES (1, repeat('x', 20000));
----
NOTICE: auto-committing transaction before processing DDL due to autocommit_before_ddl setting

query-sql
SELECT i, pg_column_size(s) FROM maxrow ORDER BY i;
Expand Down
7 changes: 0 additions & 7 deletions pkg/backup/testdata/backup-restore/metadata
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,6 @@ USE db1;
CREATE TABLE tab (a INT PRIMARY KEY, b INT);
INSERT INTO tab VALUES (1, 1), (2, 2), (100, 100);
----
NOTICE: auto-committing transaction before processing DDL due to autocommit_before_ddl setting

# We create 3 statistics manually which is the minimum needed to
# create a forecast and a partial statistic on column A so that a
Expand All @@ -34,12 +33,6 @@ CREATE STATISTICS __auto__ ON a FROM tab;
CREATE STATISTICS __auto__ ON b FROM tab;
CREATE STATISTICS partial ON a FROM tab USING EXTREMES;
----
NOTICE: auto-committing transaction before processing DDL due to autocommit_before_ddl setting
NOTICE: auto-committing transaction before processing DDL due to autocommit_before_ddl setting
NOTICE: auto-committing transaction before processing DDL due to autocommit_before_ddl setting
NOTICE: auto-committing transaction before processing DDL due to autocommit_before_ddl setting
NOTICE: auto-committing transaction before processing DDL due to autocommit_before_ddl setting
NOTICE: auto-committing transaction before processing DDL due to autocommit_before_ddl setting

query-sql
SELECT count(1) FROM [ SHOW STATISTICS FOR TABLE tab ]
Expand Down
2 changes: 0 additions & 2 deletions pkg/backup/testdata/backup-restore/multiregion
Original file line number Diff line number Diff line change
Expand Up @@ -15,8 +15,6 @@ CREATE DATABASE d PRIMARY REGION "us-east-1" REGIONS "us-west-1", "eu-central-1"
CREATE TABLE d.t (x INT);
INSERT INTO d.t VALUES (1), (2), (3);
----
NOTICE: auto-committing transaction before processing DDL due to autocommit_before_ddl setting
NOTICE: auto-committing transaction before processing DDL due to autocommit_before_ddl setting

query-sql
SELECT region FROM [SHOW REGIONS FROM DATABASE d] ORDER BY 1;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,6 @@ CREATE DATABASE d PRIMARY REGION "us-east-1";
CREATE TABLE d.t (x INT);
INSERT INTO d.t VALUES (1), (2), (3);
----
NOTICE: auto-committing transaction before processing DDL due to autocommit_before_ddl setting

query-sql
SELECT region FROM [SHOW REGIONS FROM DATABASE d] ORDER BY 1;
Expand Down
5 changes: 0 additions & 5 deletions pkg/backup/testdata/backup-restore/online-restore-auto-stats
Original file line number Diff line number Diff line change
Expand Up @@ -16,11 +16,6 @@ CREATE TABLE nostats (i INT PRIMARY KEY, s STRING);
ALTER TABLE stats SET (sql_stats_automatic_collection_enabled = true);
ALTER TABLE nostats SET (sql_stats_automatic_collection_enabled = false);
----
NOTICE: auto-committing transaction before processing DDL due to autocommit_before_ddl setting
NOTICE: auto-committing transaction before processing DDL due to autocommit_before_ddl setting
NOTICE: auto-committing transaction before processing DDL due to autocommit_before_ddl setting
NOTICE: auto-committing transaction before processing DDL due to autocommit_before_ddl setting
NOTICE: auto-committing transaction before processing DDL due to autocommit_before_ddl setting

exec-sql
BACKUP INTO 'nodelocal://1/cluster/';
Expand Down
3 changes: 0 additions & 3 deletions pkg/backup/testdata/backup-restore/online-restore-cluster
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,6 @@ INSERT INTO foofoo VALUES (10, 'x0');
CREATE TABLE baz (i INT PRIMARY KEY, s STRING);
INSERT INTO baz VALUES (1, 'x'),(2,'y'),(3,'z');
----
NOTICE: auto-committing transaction before processing DDL due to autocommit_before_ddl setting
NOTICE: auto-committing transaction before processing DDL due to autocommit_before_ddl setting

exec-sql
BACKUP INTO 'nodelocal://1/cluster/';
Expand All @@ -36,4 +34,3 @@ SELECT count(*) FROM [SHOW JOBS] WHERE description LIKE '%Background Data Downlo




Original file line number Diff line number Diff line change
Expand Up @@ -22,4 +22,4 @@ RESTORE DATABASE d FROM LATEST IN 'nodelocal://1/cluster/' with EXPERIMENTAL DEF
query-sql retry
SELECT count(*) FROM [SHOW JOBS] WHERE job_type='RESTORE' and status='succeeded';
----
2
2
Loading

0 comments on commit 0effe73

Please sign in to comment.