Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit571e0ee

Browse files
Use DELETE instead of UPDATE to speed up vacuum test
01e2b7f introduced a test which generated dead tuples forvacuum with an UPDATE. The test only required enough dead TIDs for tworounds of index vacuuming. This can be accomplished with a DELETEinstead of an UPDATE -- which generates about 50% less WAL and makes thetest 20% faster in many cases. The test takes several seconds (more onslow buildfarm animals) because we need quite a few tuples to triggertwo rounds of index vacuuming; so it is worth a follow-on commit tospeed it up.Suggested-by: Masahiko SawadaDiscussion:https://postgr.es/m/CAAKRu_bWmMjmqL%2BOZ2duEQ80u7cRvpsExLNZNjzk-pXX5skwMQ%40mail.gmail.comBackpatch-through: 14, the first version containing this test.
1 parent6f6b0f1 commit571e0ee

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

‎src/test/recovery/t/043_vacuum_horizon_floor.pl

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -75,7 +75,7 @@
7575
CREATE TABLE${table1}(col1 int) with (autovacuum_enabled=false);
7676
INSERT INTO$table1 SELECT generate_series(1, 200000);
7777
CREATE INDEX on${table1}(col1);
78-
UPDATE$table1 SET col1 = 0 WHERE col1 > 1;
78+
DELETE FROM$table1 WHERE col1 > 1;
7979
INSERT INTO$table1 VALUES(1);
8080
]);
8181

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp