Location via proxy:   [ UP ]  
[Report a bug]   [Manage cookies]                
Skip to content

Commit 8da5d8d

Browse files
committed
Merge commit '98f6ac3db3b4fcb1107a42966aa1748ca8b69064' into PGPRO10_pg_pageprep
2 parents 4a9a36e + 98f6ac3 commit 8da5d8d

File tree

3 files changed

+25
-14
lines changed

3 files changed

+25
-14
lines changed

contrib/pg_pageprep/conf.add

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
shared_preload_libraries='pg_pageprep'
2+
pg_pageprep.enable_workers=off
3+
pg_pageprep.role='test'
4+

contrib/pg_pageprep/expected/simple.out

Lines changed: 14 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,10 @@ SHOW pg_pageprep.enable_workers;
1010
/* minimal delays */
1111
SET pg_pageprep.per_relation_delay=0;
1212
SET pg_pageprep.per_page_delay=0;
13+
CREATE FUNCTION show_reloptions(rel regclass) RETURNS text[] AS
14+
$$
15+
SELECT reloptions FROM pg_class WHERE oid = rel;
16+
$$ LANGUAGE sql;
1317
CREATE EXTENSION pg_pageprep;
1418
CREATE VIEW todo_list AS
1519
SELECT regexp_replace(relname::text, '\d+'::text, '0') as rel1, status
@@ -28,12 +32,11 @@ SELECT * FROM todo_list;
2832
(2 rows)
2933

3034
INSERT INTO one SELECT i FROM generate_series(1, 1000) i;
31-
\d+ one
32-
Table "public.one"
33-
Column | Type | Modifiers | Storage | Stats target | Description
34-
--------+---------+-----------+---------+--------------+-------------
35-
a | integer | | plain | |
36-
Options: fillfactor=100
35+
SELECT show_reloptions('one');
36+
show_reloptions
37+
------------------
38+
{fillfactor=100}
39+
(1 row)
3740

3841
SELECT scan_pages('one'::regclass);
3942
NOTICE: fillfactor was updated for "public.one"
@@ -43,12 +46,11 @@ NOTICE: pg_pageprep (contrib_regression): finish page scan for public.one (page
4346

4447
(1 row)
4548

46-
\d+ one
47-
Table "public.one"
48-
Column | Type | Modifiers | Storage | Stats target | Description
49-
--------+---------+-----------+---------+--------------+-------------
50-
a | integer | | plain | |
51-
Options: fillfactor=90
49+
SELECT show_reloptions('one');
50+
show_reloptions
51+
-----------------
52+
{fillfactor=90}
53+
(1 row)
5254

5355
SELECT * FROM todo_list;
5456
rel1 | status

contrib/pg_pageprep/sql/simple.sql

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,11 @@ SHOW pg_pageprep.enable_workers;
99
SET pg_pageprep.per_relation_delay=0;
1010
SET pg_pageprep.per_page_delay=0;
1111

12+
CREATE FUNCTION show_reloptions(rel regclass) RETURNS text[] AS
13+
$$
14+
SELECT reloptions FROM pg_class WHERE oid = rel;
15+
$$ LANGUAGE sql;
16+
1217
CREATE EXTENSION pg_pageprep;
1318
CREATE VIEW todo_list AS
1419
SELECT regexp_replace(relname::text, '\d+'::text, '0') as rel1, status
@@ -22,9 +27,9 @@ CREATE VIEW jobs_list AS
2227
CREATE TABLE one(a INT4) WITH (fillfactor=100);
2328
SELECT * FROM todo_list;
2429
INSERT INTO one SELECT i FROM generate_series(1, 1000) i;
25-
\d+ one
30+
SELECT show_reloptions('one');
2631
SELECT scan_pages('one'::regclass);
27-
\d+ one
32+
SELECT show_reloptions('one');
2833
SELECT * FROM todo_list;
2934
SELECT * FROM jobs_list;
3035

0 commit comments

Comments
 (0)