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

Commit8284d7f

Browse files
committed
Merge branch 'PGPROEE9_6' into PGPROEE9_6_MULTIMASTER
2 parents7c0cf2e +f7a2658 commit8284d7f

File tree

598 files changed

+281602
-1586
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

598 files changed

+281602
-1586
lines changed

‎.ci/run_install_check

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -25,11 +25,13 @@ LD_LIBRARY_PATH=$(pwd)/tmp_install/lib
2525
DYLD_LIBRARY_PATH=$(pwd)/tmp_install/lib
2626
PATH=$(pwd)/tmp_install/bin:${PATH}
2727
PGDATA=$(pwd)/tmp_base
28-
export DYLD_LIBRARY_PATH LD_LIBRARY_PATH PATHPG_DATA
28+
export DYLD_LIBRARY_PATH LD_LIBRARY_PATH PATHPGDATA
2929

3030
# create installation
3131
PGPORT=`./.ci/find_free_port 5432`
32-
export PGPORT
32+
LANG=C
33+
LC_ALL=C
34+
export PGPORT LANG LC_ALL
3335
./.ci/make_test_base$PGDATA
3436
#run checks
3537
set +e

‎configure

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2770,7 +2770,7 @@ else
27702770
fi
27712771

27722772

2773-
PGPRO_VERSION="$PACKAGE_VERSION.2"
2773+
PGPRO_VERSION="$PACKAGE_VERSION.3"
27742774
PGPRO_PACKAGE_NAME="PostgresPro"
27752775
PGPRO_EDITION="enterprise"
27762776

@@ -14869,7 +14869,7 @@ fi
1486914869
LIBS_including_readline="$LIBS"
1487014870
LIBS=`echo "$LIBS" | sed -e 's/-ledit//g' -e 's/-lreadline//g'`
1487114871

14872-
for ac_func in cbrt dlopen fdatasync getifaddrs getpeerucred getrlimit mbstowcs_l memmove poll pstat pthread_is_threaded_np readlink setproctitle setsid shm_open symlink sync_file_range towlower utime utimes wcstombs wcstombs_l
14872+
for ac_func in cbrt dlopen fdatasync getifaddrs getpeerucred getrlimit mbstowcs_l memmove pollposix_fallocatepstat pthread_is_threaded_np readlink setproctitle setsid shm_open symlink sync_file_range towlower utime utimes wcstombs wcstombs_l
1487314873
do :
1487414874
as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
1487514875
ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"

‎configure.in

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@ AC_DEFINE_UNQUOTED(PG_MAJORVERSION, "$PG_MAJORVERSION", [PostgreSQL major versio
3838
PGAC_ARG_REQ(with, extra-version, [STRING], [append STRING to version],
3939
[PG_VERSION="$PACKAGE_VERSION$withval"],
4040
[PG_VERSION="$PACKAGE_VERSION"])
41-
PGPRO_VERSION="$PACKAGE_VERSION.2"
41+
PGPRO_VERSION="$PACKAGE_VERSION.3"
4242
PGPRO_PACKAGE_NAME="PostgresPro"
4343
PGPRO_EDITION="enterprise"
4444
AC_SUBST(PGPRO_PACKAGE_NAME)
@@ -1583,7 +1583,7 @@ PGAC_FUNC_WCSTOMBS_L
15831583
LIBS_including_readline="$LIBS"
15841584
LIBS=`echo "$LIBS" | sed -e 's/-ledit//g' -e 's/-lreadline//g'`
15851585

1586-
AC_CHECK_FUNCS([cbrt dlopen fdatasync getifaddrs getpeerucred getrlimit mbstowcs_l memmove poll pstat pthread_is_threaded_np readlink setproctitle setsid shm_open symlink sync_file_range towlower utime utimes wcstombs wcstombs_l])
1586+
AC_CHECK_FUNCS([cbrt dlopen fdatasync getifaddrs getpeerucred getrlimit mbstowcs_l memmove pollposix_fallocatepstat pthread_is_threaded_np readlink setproctitle setsid shm_open symlink sync_file_range towlower utime utimes wcstombs wcstombs_l])
15871587

15881588
AC_REPLACE_FUNCS(fseeko)
15891589
case $host_os in
Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,28 @@
1+
<!--
2+
### IMPORTANT: make sure that you:
3+
4+
- are familiar with [known limitations](https://github.com/postgrespro/pg_pathman/wiki/Known-limitations).
5+
- checked the [faq](https://github.com/postgrespro/pg_pathman/wiki/What-the-FAQ) for common problems.
6+
-->
7+
8+
9+
###Problem description
10+
11+
Explain your problem here (it's always better to provide reproduction steps) ...
12+
13+
14+
15+
###Environment
16+
17+
<!-- Put the result of (SELECT * FROM pg_extension) below-->
18+
19+
<!-- Put the result of (SELECT version()) below-->
20+
21+
<!-- For Postgres Pro: put the result of (SELECT pgpro_version()) below-->
22+
23+
<!-- For Postgres Pro: put the result of (SELECT pgpro_edition()) below-->
24+
25+
<!-- For pg_pathman 1.4: put the result of (SELECT get_pathman_lib_version()) below-->
26+
27+
<!-- For pg_pathman 1.5: put the result of (SELECT pathman_version()) below-->
28+

‎contrib/pg_pathman/META.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
"name":"pg_pathman",
33
"abstract":"Partitioning tool",
44
"description":"The `pg_pathman` module provides optimized partitioning mechanism and functions to manage partitions.",
5-
"version":"1.4.7",
5+
"version":"1.4.8",
66
"maintainer": [
77
"Ildar Musin <i.musin@postgrespro.ru>",
88
"Dmitry Ivanov <d.ivanov@postgrespro.ru>",
@@ -24,7 +24,7 @@
2424
"pg_pathman": {
2525
"file":"pg_pathman--1.4.sql",
2626
"docfile":"README.md",
27-
"version":"1.4.7",
27+
"version":"1.4.8",
2828
"abstract":"Partitioning tool"
2929
}
3030
},

‎contrib/pg_pathman/README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -53,7 +53,7 @@ More interesting features are yet to come. Stay tuned!
5353
*`RuntimeAppend` &`RuntimeMergeAppend` custom plan nodes to pick partitions at runtime;
5454
*`PartitionFilter`: an efficient drop-in replacement for INSERT triggers;
5555
* Automatic partition creation for new INSERTed data (only for RANGE partitioning);
56-
* Improved`COPY FROM\TO` statement that is able to insert rows directly into partitions;
56+
* Improved`COPY FROM` statement that is able to insert rows directly into partitions;
5757
* UPDATE triggers generation out of the box (will be replaced with custom nodes too);
5858
* User-defined callbacks for partition creation event handling;
5959
* Non-blocking concurrent table partitioning;

‎contrib/pg_pathman/expected/pathman_bgw.out

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -187,6 +187,7 @@ DECLARE
187187
iint4 := 0; -- protect from endless loop
188188
BEGIN
189189
LOOP
190+
-- get total number of processed rows
190191
SELECT processed
191192
FROM pathman_concurrent_part_tasks
192193
WHERE relid = 'test_bgw.conc_part'::regclass
@@ -200,9 +201,12 @@ BEGIN
200201

201202
ASSERT rows IS NOT NULL;
202203

203-
-- rows should increase!
204-
IF rows_old <= rows THEN
204+
IF rows_old = rows THEN
205205
i = i + 1;
206+
ELSIF rows < rows_old THEN
207+
RAISE EXCEPTION 'rows is decreasing: new %, old %', rows, rows_old;
208+
ELSIF rows > 500 THEN
209+
RAISE EXCEPTION 'processed % rows', rows;
206210
END IF;
207211
ELSE
208212
EXIT; -- exit loop

‎contrib/pg_pathman/expected/pathman_calamity.out

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ SELECT debug_capture();
1212
SELECT get_pathman_lib_version();
1313
get_pathman_lib_version
1414
-------------------------
15-
10407
15+
10408
1616
(1 row)
1717

1818
set client_min_messages = NOTICE;

‎contrib/pg_pathman/expected/pathman_utility_stmt.out

Lines changed: 24 additions & 90 deletions
Original file line numberDiff line numberDiff line change
@@ -24,70 +24,6 @@ VACUUM FULL copy_stmt_hooking.test_1;
2424
VACUUM FULL copy_stmt_hooking.test_2;
2525
VACUUM FULL copy_stmt_hooking.test_3;
2626
VACUUM FULL copy_stmt_hooking.test_4;
27-
/* COPY TO */
28-
COPY copy_stmt_hooking.test TO stdout;
29-
1comment\N\N
30-
2comment\N\N
31-
3comment\N\N
32-
4comment\N\N
33-
5comment\N\N
34-
6comment\N\N
35-
7comment\N\N
36-
8comment\N\N
37-
9comment\N\N
38-
10comment\N\N
39-
11comment\N\N
40-
12comment\N\N
41-
13comment\N\N
42-
14comment\N\N
43-
15comment\N\N
44-
16comment\N\N
45-
17comment\N\N
46-
18comment\N\N
47-
19comment\N\N
48-
20comment\N\N
49-
\copy copy_stmt_hooking.test to stdout (format csv)
50-
1,comment,,
51-
2,comment,,
52-
3,comment,,
53-
4,comment,,
54-
5,comment,,
55-
6,comment,,
56-
7,comment,,
57-
8,comment,,
58-
9,comment,,
59-
10,comment,,
60-
11,comment,,
61-
12,comment,,
62-
13,comment,,
63-
14,comment,,
64-
15,comment,,
65-
16,comment,,
66-
17,comment,,
67-
18,comment,,
68-
19,comment,,
69-
20,comment,,
70-
\copy copy_stmt_hooking.test(comment) to stdout
71-
comment
72-
comment
73-
comment
74-
comment
75-
comment
76-
comment
77-
comment
78-
comment
79-
comment
80-
comment
81-
comment
82-
comment
83-
comment
84-
comment
85-
comment
86-
comment
87-
comment
88-
comment
89-
comment
90-
comment
9127
/* DELETE ROWS, COPY FROM */
9228
DELETE FROM copy_stmt_hooking.test;
9329
COPY copy_stmt_hooking.test FROM stdin;
@@ -113,32 +49,30 @@ VACUUM FULL copy_stmt_hooking.test_1;
11349
VACUUM FULL copy_stmt_hooking.test_2;
11450
VACUUM FULL copy_stmt_hooking.test_3;
11551
VACUUM FULL copy_stmt_hooking.test_4;
116-
/* COPY FROM (specified columns) */
117-
COPY copy_stmt_hooking.test (val) TO stdout;
118-
1
119-
6
120-
7
121-
11
122-
16
123-
COPY copy_stmt_hooking.test (val, comment) TO stdout;
124-
1test_1
125-
6test_2
126-
7test_2
127-
11test_3
128-
16test_4
129-
COPY copy_stmt_hooking.test (c3, val, comment) TO stdout;
130-
01test_1
131-
06test_2
132-
07test_2
133-
011test_3
134-
016test_4
135-
COPY copy_stmt_hooking.test (val, comment, c3, c4) TO stdout;
52+
/* COPY TO */
53+
COPY copy_stmt_hooking.test TO stdout;/* not ok */
54+
WARNING: COPY TO will only select rows from parent table "test"
55+
COPY copy_stmt_hooking.test (val) TO stdout;/* not ok */
56+
WARNING: COPY TO will only select rows from parent table "test"
57+
COPY (SELECT * FROM copy_stmt_hooking.test) TO stdout;
58+
1test_100
59+
6test_200
60+
7test_200
61+
11test_300
62+
16test_400
63+
COPY (SELECT * FROM copy_stmt_hooking.test) TO stdout (FORMAT CSV);
64+
1,test_1,0,0
65+
6,test_2,0,0
66+
7,test_2,0,0
67+
11,test_3,0,0
68+
16,test_4,0,0
69+
\copy (SELECT * FROM copy_stmt_hooking.test) TO stdout
13670
1test_100
13771
6test_200
13872
7test_200
13973
11test_300
14074
16test_400
141-
/* COPYTO (partition does not exist, NOT allowed to create partitions) */
75+
/* COPYFROM (partition does not exist, NOT allowed to create partitions) */
14276
SET pg_pathman.enable_auto_partition = OFF;
14377
COPY copy_stmt_hooking.test FROM stdin;
14478
ERROR: no suitable partition for key '21'
@@ -147,7 +81,7 @@ SELECT * FROM copy_stmt_hooking.test WHERE val > 20;
14781
-----+---------+----+----
14882
(0 rows)
14983

150-
/* COPYTO (partition does not exist, allowed to create partitions) */
84+
/* COPYFROM (partition does not exist, allowed to create partitions) */
15185
SET pg_pathman.enable_auto_partition = ON;
15286
COPY copy_stmt_hooking.test FROM stdin;
15387
SELECT * FROM copy_stmt_hooking.test WHERE val > 20;
@@ -194,18 +128,18 @@ WHERE attnum > 0 AND attrelid = 'copy_stmt_hooking.test_6'::REGCLASS;
194128
3
195129
(1 row)
196130

197-
/*COPY FROM (test transformed tuples) */
198-
COPYcopy_stmt_hooking.test (val, c3, c4) TO stdout;
131+
/* test transformed tuples */
132+
COPY(SELECT * FROM copy_stmt_hooking.test) TO stdout;
199133
100
200134
600
201135
700
202136
1100
203137
1600
204138
2100
205139
2612
206-
/* COPYTO (insert into table with dropped column) */
140+
/* COPYFROM (insert into table with dropped column) */
207141
COPY copy_stmt_hooking.test(val, c3, c4) FROM stdin;
208-
/* COPYTO (insert into table without dropped column) */
142+
/* COPYFROM (insert into table without dropped column) */
209143
COPY copy_stmt_hooking.test(val, c3, c4) FROM stdin;
210144
/* check tuples from last partition (without dropped column) */
211145
SELECT *, tableoid::REGCLASS FROM copy_stmt_hooking.test ORDER BY val;

‎contrib/pg_pathman/sql/pathman_bgw.sql

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -101,6 +101,7 @@ DECLARE
101101
iint4 :=0;-- protect from endless loop
102102
BEGIN
103103
LOOP
104+
-- get total number of processed rows
104105
SELECT processed
105106
FROM pathman_concurrent_part_tasks
106107
WHERE relid='test_bgw.conc_part'::regclass
@@ -114,9 +115,12 @@ BEGIN
114115

115116
ASSERT rowsIS NOT NULL;
116117

117-
-- rows should increase!
118-
IF rows_old<= rows THEN
118+
IF rows_old= rows THEN
119119
i= i+1;
120+
ELSIF rows< rows_old THEN
121+
RAISE EXCEPTION'rows is decreasing: new %, old %', rows, rows_old;
122+
ELSIF rows>500 THEN
123+
RAISE EXCEPTION'processed % rows', rows;
120124
END IF;
121125
ELSE
122126
EXIT;-- exit loop

‎contrib/pg_pathman/sql/pathman_utility_stmt.sql

Lines changed: 12 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -28,11 +28,6 @@ VACUUM FULL copy_stmt_hooking.test_2;
2828
VACUUM FULLcopy_stmt_hooking.test_3;
2929
VACUUM FULLcopy_stmt_hooking.test_4;
3030

31-
/* COPY TO*/
32-
COPYcopy_stmt_hooking.test TO stdout;
33-
\copycopy_stmt_hooking.test to stdout (format csv)
34-
\copycopy_stmt_hooking.test(comment) to stdout
35-
3631
/* DELETE ROWS, COPY FROM*/
3732
DELETEFROMcopy_stmt_hooking.test;
3833
COPYcopy_stmt_hooking.testFROM stdin;
@@ -52,20 +47,21 @@ VACUUM FULL copy_stmt_hooking.test_2;
5247
VACUUM FULLcopy_stmt_hooking.test_3;
5348
VACUUM FULLcopy_stmt_hooking.test_4;
5449

55-
/* COPY FROM (specified columns)*/
56-
COPYcopy_stmt_hooking.test (val) TO stdout;
57-
COPYcopy_stmt_hooking.test (val, comment) TO stdout;
58-
COPYcopy_stmt_hooking.test (c3, val, comment) TO stdout;
59-
COPYcopy_stmt_hooking.test (val, comment, c3, c4) TO stdout;
50+
/* COPY TO*/
51+
COPYcopy_stmt_hooking.test TO stdout;/* not ok*/
52+
COPYcopy_stmt_hooking.test (val) TO stdout;/* not ok*/
53+
COPY (SELECT*FROMcopy_stmt_hooking.test) TO stdout;
54+
COPY (SELECT*FROMcopy_stmt_hooking.test) TO stdout (FORMAT CSV);
55+
\copy (SELECT*FROMcopy_stmt_hooking.test) TO stdout
6056

61-
/* COPYTO (partition does not exist, NOT allowed to create partitions)*/
57+
/* COPYFROM (partition does not exist, NOT allowed to create partitions)*/
6258
SETpg_pathman.enable_auto_partition= OFF;
6359
COPYcopy_stmt_hooking.testFROM stdin;
6460
21test_no_part00
6561
\.
6662
SELECT*FROMcopy_stmt_hooking.testWHERE val>20;
6763

68-
/* COPYTO (partition does not exist, allowed to create partitions)*/
64+
/* COPYFROM (partition does not exist, allowed to create partitions)*/
6965
SETpg_pathman.enable_auto_partition=ON;
7066
COPYcopy_stmt_hooking.testFROM stdin;
7167
21test_no_part00
@@ -98,16 +94,16 @@ WHERE attnum > 0 AND attrelid = 'copy_stmt_hooking.test'::REGCLASS;
9894
SELECTcount(*)FROM pg_attribute
9995
WHERE attnum>0AND attrelid='copy_stmt_hooking.test_6'::REGCLASS;
10096

97+
/* test transformed tuples*/
98+
COPY (SELECT*FROMcopy_stmt_hooking.test) TO stdout;
10199

102-
/* COPY FROM (test transformed tuples)*/
103-
COPYcopy_stmt_hooking.test (val, c3, c4) TO stdout;
104100

105-
/* COPYTO (insert into table with dropped column)*/
101+
/* COPYFROM (insert into table with dropped column)*/
106102
COPYcopy_stmt_hooking.test(val, c3, c4)FROM stdin;
107103
212
108104
\.
109105

110-
/* COPYTO (insert into table without dropped column)*/
106+
/* COPYFROM (insert into table without dropped column)*/
111107
COPYcopy_stmt_hooking.test(val, c3, c4)FROM stdin;
112108
2712
113109
\.

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp