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

Commit c2ac42d

Browse files
author
Marina Polyakova
committed
Merge remote-tracking branch 'origin/PGPRO10_DEV' into PGPRO-626-ICU
2 parents 878bf6d + 1f14f09 commit c2ac42d

File tree

140 files changed

+12197
-7789
lines changed

Some content is hidden

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

140 files changed

+12197
-7789
lines changed

configure

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
#! /bin/sh
22
# Guess values for system-dependent variables and create Makefiles.
3-
# Generated by GNU Autoconf 2.69 for PostgreSQL 10.0.
3+
# Generated by GNU Autoconf 2.69 for PostgreSQL 10.1.
44
#
55
# Report bugs to <bugs@postgrespro.ru>.
66
#
@@ -583,8 +583,8 @@ MAKEFLAGS=
583583
# Identity of this package.
584584
PACKAGE_NAME='PostgreSQL'
585585
PACKAGE_TARNAME='postgrespro'
586-
PACKAGE_VERSION='10.0'
587-
PACKAGE_STRING='PostgreSQL 10.0'
586+
PACKAGE_VERSION='10.1'
587+
PACKAGE_STRING='PostgreSQL 10.1'
588588
PACKAGE_BUGREPORT='bugs@postgrespro.ru'
589589
PACKAGE_URL=''
590590

@@ -1424,7 +1424,7 @@ if test "$ac_init_help" = "long"; then
14241424
# Omit some internal or obsolete options to make the list less imposing.
14251425
# This message is too long to be a string in the A/UX 3.1 sh.
14261426
cat <<_ACEOF
1427-
\`configure' configures PostgreSQL 10.0 to adapt to many kinds of systems.
1427+
\`configure' configures PostgreSQL 10.1 to adapt to many kinds of systems.
14281428
14291429
Usage: $0 [OPTION]... [VAR=VALUE]...
14301430
@@ -1490,7 +1490,7 @@ fi
14901490

14911491
if test -n "$ac_init_help"; then
14921492
case $ac_init_help in
1493-
short | recursive ) echo "Configuration of PostgreSQL 10.0:";;
1493+
short | recursive ) echo "Configuration of PostgreSQL 10.1:";;
14941494
esac
14951495
cat <<\_ACEOF
14961496
@@ -1649,7 +1649,7 @@ fi
16491649
test -n "$ac_init_help" && exit $ac_status
16501650
if $ac_init_version; then
16511651
cat <<\_ACEOF
1652-
PostgreSQL configure 10.0
1652+
PostgreSQL configure 10.1
16531653
generated by GNU Autoconf 2.69
16541654
16551655
Copyright (C) 2012 Free Software Foundation, Inc.
@@ -2361,7 +2361,7 @@ cat >config.log <<_ACEOF
23612361
This file contains any messages produced by compilers while
23622362
running configure, to aid debugging if configure makes a mistake.
23632363
2364-
It was created by PostgreSQL $as_me 10.0, which was
2364+
It was created by PostgreSQL $as_me 10.1, which was
23652365
generated by GNU Autoconf 2.69. Invocation command line was
23662366
23672367
$ $0 $@
@@ -16865,7 +16865,7 @@ _ACEOF
1686516865
# awk -F is a regex on some platforms, and not on others, so make "." a tab
1686616866
PG_VERSION_NUM="`echo "$PACKAGE_VERSION" | sed 's/[A-Za-z].*$//' |
1686716867
tr '.' ' ' |
16868-
$AWK '{printf "%d%02d%02d", $1, $2, (NF >= 3) ? $3 : 0}'`"
16868+
$AWK '{printf "%d%04d", $1, $2}'`"
1686916869

1687016870
cat >>confdefs.h <<_ACEOF
1687116871
#define PG_VERSION_NUM $PG_VERSION_NUM
@@ -17433,7 +17433,7 @@ cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
1743317433
# report actual input values of CONFIG_FILES etc. instead of their
1743417434
# values after options handling.
1743517435
ac_log="
17436-
This file was extended by PostgreSQL $as_me 10.0, which was
17436+
This file was extended by PostgreSQL $as_me 10.1, which was
1743717437
generated by GNU Autoconf 2.69. Invocation command line was
1743817438
1743917439
CONFIG_FILES = $CONFIG_FILES
@@ -17503,7 +17503,7 @@ _ACEOF
1750317503
cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
1750417504
ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`"
1750517505
ac_cs_version="\\
17506-
PostgreSQL config.status 10.0
17506+
PostgreSQL config.status 10.1
1750717507
configured by $0, generated by GNU Autoconf 2.69,
1750817508
with options \\"\$ac_cs_config\\"
1750917509

configure.in

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ dnl Read the Autoconf manual for details.
1717
dnl
1818
m4_pattern_forbid(^PGAC_)dnl to catch undefined macros
1919

20-
AC_INIT([PostgreSQL], [10.0], [bugs@postgrespro.ru], [postgrespro])
20+
AC_INIT([PostgreSQL], [10.1], [bugs@postgrespro.ru], [postgrespro])
2121
PACKAGE_TARNAME=postgrespro
2222

2323
m4_if(m4_defn([m4_PACKAGE_VERSION]), [2.69], [], [m4_fatal([Autoconf version 2.69 is required.
@@ -2210,7 +2210,7 @@ AC_DEFINE_UNQUOTED(PGPRO_VERSION_STR,
22102210
# awk -F is a regex on some platforms, and not on others, so make "." a tab
22112211
[PG_VERSION_NUM="`echo "$PACKAGE_VERSION" | sed 's/[A-Za-z].*$//' |
22122212
tr '.' ' ' |
2213-
$AWK '{printf "%d%02d%02d", $1, $2, (NF >= 3) ? $3 : 0}'`"]
2213+
$AWK '{printf "%d%04d", $1, $2}'`"]
22142214
AC_DEFINE_UNQUOTED(PG_VERSION_NUM, $PG_VERSION_NUM, [PostgreSQL version as a number])
22152215
AC_SUBST(PG_VERSION_NUM)
22162216

contrib/start-scripts/freebsd

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -43,15 +43,15 @@ test -x $DAEMON ||
4343

4444
case $1 in
4545
start)
46-
su -l $PGUSER -c "$DAEMON -D '$PGDATA' &" >>$PGLOG 2>&1
46+
su -l $PGUSER -c "$DAEMON -D '$PGDATA' >>$PGLOG 2>&1 &"
4747
echo -n ' postgresql'
4848
;;
4949
stop)
5050
su -l $PGUSER -c "$PGCTL stop -D '$PGDATA' -s"
5151
;;
5252
restart)
5353
su -l $PGUSER -c "$PGCTL stop -D '$PGDATA' -s"
54-
su -l $PGUSER -c "$DAEMON -D '$PGDATA' &" >>$PGLOG 2>&1
54+
su -l $PGUSER -c "$DAEMON -D '$PGDATA' >>$PGLOG 2>&1 &"
5555
;;
5656
status)
5757
su -l $PGUSER -c "$PGCTL status -D '$PGDATA'"

contrib/start-scripts/linux

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -91,7 +91,7 @@ case $1 in
9191
start)
9292
echo -n "Starting PostgreSQL: "
9393
test -e "$PG_OOM_ADJUST_FILE" && echo "$PG_MASTER_OOM_SCORE_ADJ" > "$PG_OOM_ADJUST_FILE"
94-
su - $PGUSER -c "$DAEMON_ENV $DAEMON -D '$PGDATA' &" >>$PGLOG 2>&1
94+
su - $PGUSER -c "$DAEMON_ENV $DAEMON -D '$PGDATA' >>$PGLOG 2>&1 &"
9595
echo "ok"
9696
;;
9797
stop)
@@ -103,7 +103,7 @@ case $1 in
103103
echo -n "Restarting PostgreSQL: "
104104
su - $PGUSER -c "$PGCTL stop -D '$PGDATA' -s"
105105
test -e "$PG_OOM_ADJUST_FILE" && echo "$PG_MASTER_OOM_SCORE_ADJ" > "$PG_OOM_ADJUST_FILE"
106-
su - $PGUSER -c "$DAEMON_ENV $DAEMON -D '$PGDATA' &" >>$PGLOG 2>&1
106+
su - $PGUSER -c "$DAEMON_ENV $DAEMON -D '$PGDATA' >>$PGLOG 2>&1 &"
107107
echo "ok"
108108
;;
109109
reload)

contrib/start-scripts/osx/PostgreSQL

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -80,9 +80,9 @@ StartService () {
8080
if [ "${POSTGRESQL:=-NO-}" = "-YES-" ]; then
8181
ConsoleMessage "Starting PostgreSQL database server"
8282
if [ "${ROTATELOGS}" = "1" ]; then
83-
sudo -u $PGUSER sh -c "${DAEMON} -D '${PGDATA}' &" 2>&1 | ${LOGUTIL} "${PGLOG}" ${ROTATESEC} &
83+
sudo -u $PGUSER sh -c "${DAEMON} -D '${PGDATA}' 2>&1 | ${LOGUTIL} \"${PGLOG}\" ${ROTATESEC} &"
8484
else
85-
sudo -u $PGUSER sh -c "${DAEMON} -D '${PGDATA}' &" >>"$PGLOG" 2>&1
85+
sudo -u $PGUSER sh -c "${DAEMON} -D '${PGDATA}' >>\"$PGLOG\" 2>&1 &"
8686
fi
8787
fi
8888
}
@@ -99,9 +99,9 @@ RestartService () {
9999
sudo -u $PGUSER sh -c "$PGCTL stop -D '${PGDATA}' -s"
100100
# should match StartService:
101101
if [ "${ROTATELOGS}" = "1" ]; then
102-
sudo -u $PGUSER sh -c "${DAEMON} -D '${PGDATA}' &" 2>&1 | ${LOGUTIL} "${PGLOG}" ${ROTATESEC} &
102+
sudo -u $PGUSER sh -c "${DAEMON} -D '${PGDATA}' 2>&1 | ${LOGUTIL} \"${PGLOG}\" ${ROTATESEC} &"
103103
else
104-
sudo -u $PGUSER sh -c "${DAEMON} -D '${PGDATA}' &" >>"$PGLOG" 2>&1
104+
sudo -u $PGUSER sh -c "${DAEMON} -D '${PGDATA}' >>\"$PGLOG\" 2>&1 &"
105105
fi
106106
else
107107
StopService

contrib/test_decoding/expected/decoding_into_rel.out

Lines changed: 25 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -59,6 +59,31 @@ SELECT * FROM changeresult;
5959

6060
DROP TABLE changeresult;
6161
DROP TABLE somechange;
62+
-- check calling logical decoding from pl/pgsql
63+
CREATE FUNCTION slot_changes_wrapper(slot_name name) RETURNS SETOF TEXT AS $$
64+
BEGIN
65+
RETURN QUERY
66+
SELECT data FROM pg_logical_slot_peek_changes(slot_name, NULL, NULL, 'include-xids', '0', 'skip-empty-xacts', '1');
67+
END$$ LANGUAGE plpgsql;
68+
SELECT * FROM slot_changes_wrapper('regression_slot');
69+
slot_changes_wrapper
70+
--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
71+
BEGIN
72+
table public.changeresult: INSERT: data[text]:'BEGIN'
73+
table public.changeresult: INSERT: data[text]:'table public.changeresult: INSERT: data[text]:''BEGIN'''
74+
table public.changeresult: INSERT: data[text]:'table public.changeresult: INSERT: data[text]:''table public.somechange: INSERT: id[integer]:1'''
75+
table public.changeresult: INSERT: data[text]:'table public.changeresult: INSERT: data[text]:''COMMIT'''
76+
table public.changeresult: INSERT: data[text]:'COMMIT'
77+
table public.changeresult: INSERT: data[text]:'BEGIN'
78+
table public.changeresult: INSERT: data[text]:'table public.changeresult: INSERT: data[text]:''BEGIN'''
79+
table public.changeresult: INSERT: data[text]:'table public.changeresult: INSERT: data[text]:''table public.changeresult: INSERT: data[text]:''''BEGIN'''''''
80+
table public.changeresult: INSERT: data[text]:'table public.changeresult: INSERT: data[text]:''table public.changeresult: INSERT: data[text]:''''table public.somechange: INSERT: id[integer]:1'''''''
81+
table public.changeresult: INSERT: data[text]:'table public.changeresult: INSERT: data[text]:''table public.changeresult: INSERT: data[text]:''''COMMIT'''''''
82+
table public.changeresult: INSERT: data[text]:'table public.changeresult: INSERT: data[text]:''COMMIT'''
83+
table public.changeresult: INSERT: data[text]:'COMMIT'
84+
COMMIT
85+
(14 rows)
86+
6287
SELECT data FROM pg_logical_slot_get_changes('regression_slot', NULL, NULL, 'include-xids', '0', 'skip-empty-xacts', '1');
6388
data
6489
--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------

contrib/test_decoding/expected/replorigin.out

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,14 @@ SELECT pg_replication_origin_drop('test_decoding: temp');
2626
(1 row)
2727

2828
SELECT pg_replication_origin_drop('test_decoding: temp');
29-
ERROR: cache lookup failed for replication origin 'test_decoding: temp'
29+
ERROR: replication origin "test_decoding: temp" does not exist
30+
-- various failure checks for undefined slots
31+
select pg_replication_origin_advance('test_decoding: temp', '0/1');
32+
ERROR: replication origin "test_decoding: temp" does not exist
33+
select pg_replication_origin_session_setup('test_decoding: temp');
34+
ERROR: replication origin "test_decoding: temp" does not exist
35+
select pg_replication_origin_progress('test_decoding: temp', true);
36+
ERROR: replication origin "test_decoding: temp" does not exist
3037
SELECT 'init' FROM pg_create_logical_replication_slot('regression_slot', 'test_decoding');
3138
?column?
3239
----------

contrib/test_decoding/sql/decoding_into_rel.sql

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -27,5 +27,16 @@ INSERT INTO changeresult
2727
SELECT * FROM changeresult;
2828
DROP TABLE changeresult;
2929
DROP TABLE somechange;
30+
31+
-- check calling logical decoding from pl/pgsql
32+
CREATE FUNCTION slot_changes_wrapper(slot_name name) RETURNS SETOF TEXT AS $$
33+
BEGIN
34+
RETURN QUERY
35+
SELECT data FROM pg_logical_slot_peek_changes(slot_name, NULL, NULL, 'include-xids', '0', 'skip-empty-xacts', '1');
36+
END$$ LANGUAGE plpgsql;
37+
38+
SELECT * FROM slot_changes_wrapper('regression_slot');
39+
3040
SELECT data FROM pg_logical_slot_get_changes('regression_slot', NULL, NULL, 'include-xids', '0', 'skip-empty-xacts', '1');
41+
3142
SELECT 'stop' FROM pg_drop_replication_slot('regression_slot');

contrib/test_decoding/sql/replorigin.sql

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,11 @@ SELECT pg_replication_origin_create('test_decoding: temp');
1313
SELECT pg_replication_origin_drop('test_decoding: temp');
1414
SELECT pg_replication_origin_drop('test_decoding: temp');
1515

16+
-- various failure checks for undefined slots
17+
select pg_replication_origin_advance('test_decoding: temp', '0/1');
18+
select pg_replication_origin_session_setup('test_decoding: temp');
19+
select pg_replication_origin_progress('test_decoding: temp', true);
20+
1621
SELECT 'init' FROM pg_create_logical_replication_slot('regression_slot', 'test_decoding');
1722

1823
-- origin tx

doc/bug.template

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ System Configuration:
2727

2828
Operating System (example: Linux 2.4.18) :
2929

30-
PostgreSQL version (example: PostgreSQL 10.0): PostgreSQL 10.0
30+
PostgreSQL version (example: PostgreSQL 10.1): PostgreSQL 10.1
3131

3232
Compiler used (example: gcc 3.3.5) :
3333

doc/src/sgml/charset.sgml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -912,7 +912,7 @@ CREATE COLLATION german (provider = libc, locale = 'de_DE');
912912
<note>
913913
<para>
914914
By design, ICU will accept almost any string as a locale name and match
915-
it to the closet locale it can provide, using the fallback procedure
915+
it to the closest locale it can provide, using the fallback procedure
916916
described in its documentation. Thus, there will be no direct feedback
917917
if a collation specification is composed using features that the given
918918
ICU installation does not actually support. It is therefore recommended

doc/src/sgml/client-auth.sgml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -959,7 +959,7 @@ omicron bryanh guest1
959959
mechanism. It prevents password sniffing and avoids storing passwords
960960
on the server in plain text but provides no protection if an attacker
961961
manages to steal the password hash from the server. Also, the MD5 hash
962-
algorithm is nowadays no longer consider secure against determined
962+
algorithm is nowadays no longer considered secure against determined
963963
attacks.
964964
</para>
965965

doc/src/sgml/maintenance.sgml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,7 @@
4646

4747
<para>
4848
<ulink
49-
url="http://bucardo.org/wiki/Check_postgres"><application>check_postgres</></ulink>
49+
url="https://bucardo.org/check_postgres/"><application>check_postgres</></ulink>
5050
is available for monitoring database health and reporting unusual
5151
conditions. <application>check_postgres</> integrates with
5252
Nagios and MRTG, but can be run standalone too.
@@ -981,7 +981,7 @@ pg_ctl start | rotatelogs /var/log/pgsql_log 86400
981981
<ulink url="http://dalibo.github.io/pgbadger/"><productname>pgBadger</productname></ulink>
982982
is an external project that does sophisticated log file analysis.
983983
<ulink
984-
url="http://bucardo.org/wiki/Check_postgres"><productname>check_postgres</productname></ulink>
984+
url="https://bucardo.org/check_postgres/"><productname>check_postgres</productname></ulink>
985985
provides Nagios alerts when important messages appear in the log
986986
files, as well as detection of many other extraordinary conditions.
987987
</para>

doc/src/sgml/recovery-config.sgml

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -270,10 +270,11 @@ restore_command = 'copy "C:\\server\\archivedir\\%f" "%p"' # Windows
270270
Specifies whether to stop just after the specified recovery target
271271
(<literal>true</literal>), or just before the recovery target
272272
(<literal>false</literal>).
273-
Applies when either <xref linkend="recovery-target-time">
274-
or <xref linkend="recovery-target-xid"> is specified.
273+
Applies when <xref linkend="recovery-target-lsn">,
274+
<xref linkend="recovery-target-time">, or
275+
<xref linkend="recovery-target-xid"> is specified.
275276
This setting controls whether transactions
276-
having exactly the target commit time or ID, respectively, will
277+
having exactly the target WAL location (LSN), commit time, or transaction ID, respectively, will
277278
be included in the recovery. Default is <literal>true</>.
278279
</para>
279280
</listitem>

doc/src/sgml/ref/grant.sgml

Lines changed: 15 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -156,12 +156,22 @@ GRANT <replaceable class="PARAMETER">role_name</replaceable> [, ...] TO <replace
156156
<para>
157157
&productname; grants default privileges on some types of objects to
158158
<literal>PUBLIC</literal>. No privileges are granted to
159-
<literal>PUBLIC</literal> by default on tables,
160-
columns, schemas or tablespaces. For other types, the default privileges
159+
<literal>PUBLIC</literal> by default on
160+
tables,
161+
table columns,
162+
sequences,
163+
foreign data wrappers,
164+
foreign servers,
165+
large objects,
166+
schemas,
167+
or tablespaces.
168+
For other types of objects, the default privileges
161169
granted to <literal>PUBLIC</literal> are as follows:
162-
<literal>CONNECT</literal> and <literal>CREATE TEMP TABLE</literal> for
163-
databases; <literal>EXECUTE</literal> privilege for functions; and
164-
<literal>USAGE</literal> privilege for languages.
170+
<literal>CONNECT</literal> and <literal>TEMPORARY</literal> (create
171+
temporary tables) privileges for databases;
172+
<literal>EXECUTE</literal> privilege for functions; and
173+
<literal>USAGE</literal> privilege for languages and data types
174+
(including domains).
165175
The object owner can, of course, <command>REVOKE</command>
166176
both default and expressly granted privileges. (For maximum
167177
security, issue the <command>REVOKE</> in the same transaction that

doc/src/sgml/ref/prepare_transaction.sgml

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -100,7 +100,8 @@ PREPARE TRANSACTION <replaceable class="PARAMETER">transaction_id</replaceable>
100100
It is not currently allowed to <command>PREPARE</> a transaction that
101101
has executed any operations involving temporary tables,
102102
created any cursors <literal>WITH HOLD</>, or executed
103-
<command>LISTEN</> or <command>UNLISTEN</>.
103+
<command>LISTEN</>, <command>UNLISTEN</>, or
104+
<command>NOTIFY</>.
104105
Those features are too tightly
105106
tied to the current session to be useful in a transaction to be prepared.
106107
</para>

0 commit comments

Comments
 (0)