Commit Graph

16584 Commits

Author SHA1 Message Date
Daniel Gustafsson 913b3da6ae doc: fix typo in language tag documentation
Commit 1e16af8ab5 accidentally mistyped 'language' in one place.
2023-05-25 12:49:26 +02:00
Daniel Gustafsson 661bf96cd2 doc: Fix example query for pg_walinspect
The LIMIT clause had ended up in the wrong place in the query.
Backpatch to v15 where pg_walinspect was introduced.

Reported-by: Jian He <jian.universality@gmail.com>
Discussion: https://postgr.es/m/CACJufxHqXDr4NnmwmR6pEiVPAg54J0dgwMuYQzrH5BX6+NtF1g@mail.gmail.com
Backpatch-through: 15
2023-05-25 12:43:16 +02:00
Bruce Momjian 46ba86cd32 doc: PG 16 relnotes, add author from previous merge
Reported-by: John Naylor

Discussion: https://postgr.es/m/CAFBsxsEMoNdg6CCMuQ-6YJ8G=AgGNMVuiTb5Di5bsoPfBb=9CA@mail.gmail.com
2023-05-24 22:03:40 -04:00
Bruce Momjian 5c2c59ba0b doc: PG 16 relnotes, wording adjustments
Reported-by: Erik Rijkers

Discussion: https://postgr.es/m/c4a88acf-ab1a-a912-d4a9-5e19b323c5ed@xs4all.nl
2023-05-24 12:18:43 -04:00
Bruce Momjian ad5406246b doc: PG 16 relnotes, merge and move vector items
Reported-by: John Naylor

Discussion: https://postgr.es/m/CAFBsxsEPg8L2MmGqavc8JByC=WF_Mnkhn-KKnFPkcqh0hydung@mail.gmail.com
2023-05-24 09:54:34 -04:00
Bruce Momjian a817edbf6f doc: PG 16 relnotes, update xid/subxid searches item
Reported-by: John Naylor

Discussion: https://postgr.es/m/CAFBsxsEPg8L2MmGqavc8JByC=WF_Mnkhn-KKnFPkcqh0hydung@mail.gmail.com
2023-05-24 00:09:13 -04:00
Nathan Bossart 381d19b3ea Document deprecated createuser option.
2dcd1578c4 left the --role option undocumented, which is
inconsistent with other deprecated options such as pg_dump's
--blobs and --no-blobs.  This change adds --role back to
createuser's documentation and usage output and marks it as
deprecated.

Suggested-by: Peter Eisentraut
Reviewed-by: Michael Paquier
Discussion: https://postgr.es/m/0e85c9e7-4804-1cdb-5a4a-c72c328f9ad8%40enterprisedb.com
2023-05-23 19:35:05 -07:00
Bruce Momjian 5cb54fc310 doc: PG 16 relnotes, SIMD improvements
Reported-by: John Naylor

Discussion: https://postgr.es/m/CAFBsxsEuAx4_nq=200u=70S5r83C2hzO-a9+c6YXTCbOFeDAfw@mail.gmail.com
2023-05-23 00:27:01 -04:00
Bruce Momjian 60751aa503 doc: PG 16 relnotes, add major features list
Reported-by: Jonathan Katz

Discussion: https://postgr.es/m/2fd2cc0e-df39-3e77-8fcf-35aad5796b0a@postgresql.org
2023-05-22 13:58:24 -04:00
Tom Lane 1f9f6aa491 Spell the values of libpq's gssdelegation parameter as "0" and "1".
That's how other boolean options are handled, so do likewise.
The previous coding with "enable" and "disable" was seemingly
modeled on gssencmode, but that's a three-way flag.

While at it, add PGGSSDELEGATION to the set of environment
variables cleared by pg_regress and Utils.pm.

Abhijit Menon-Sen, per gripe from Alvaro Herrera

Discussion: https://postgr.es/m/20230522091609.nlyuu4nolhycqs2p@alvherre.pgsql
2023-05-22 11:50:27 -04:00
Bruce Momjian 4123455a9e doc: PG 16 relnotes, improve desc. of pg_log_standby_snapshot() 2023-05-22 10:21:20 -04:00
Alvaro Herrera 4042b2e187
pg_dump doc: mention 'long' is valid for --compress
Apparently an oversight in 2820adf775.
2023-05-22 12:26:40 +02:00
Bruce Momjian ac298d3cb5 doc: PG 16 relnotes, improve description of standby log. decode
Improve description of "Allow logical decoding on standbys".
2023-05-21 23:39:50 -04:00
Nathan Bossart 2dcd1578c4 Rename some createuser options.
This change renames --admin to --with-admin, --role to --member-of,
and --member to --with-member.  Many people found the previous
names to be confusing.  The --admin and --member options are new in
v16, but --role has been there for a while, so that one has been
kept (but left undocumented) for backward compatibility.

Suggested-by: Peter Eisentraut
Reviewed-by: Tom Lane, Michael Paquier
Discussion: https://postgr.es/m/ZFvVZvQDliIWmOwg%40momjian.us
2023-05-21 20:06:38 -07:00
Bruce Momjian de7c3fd34e doc: PG 16 relnotes, misc merged items and bootstrap detail
Reported-by: Andres Freund, jian he

Discussion: https://postgr.es/m/20230521171341.jjxykfsefsek4kzj@awork3.anarazel.de, 20230521171341.jjxykfsefsek4kzj@awork3.anarazel.de
2023-05-21 22:52:42 -04:00
Bruce Momjian c822358a25 doc: PG 16 relnotes, misc. updates
Reported-by: Tom Lane

Discussion: https://postgr.es/m/277016.1684689065@sss.pgh.pa.us
2023-05-21 15:57:59 -04:00
Bruce Momjian 30579d23b2 doc: PG 16 relnotes, add commits
Reported-by: Ian Lawrence Barwick

Discussion: https://postgr.es/m/CAB8KJ=hLvQDb53WdigV7OBEBh5tzQ7eA=pG0ZpccoRVBUNCXYA@mail.gmail.com
2023-05-21 11:56:16 -04:00
Tom Lane b62381d9a2 Doc: fix some rendering problems in the PDF docs build.
Tweak column widths in a couple of tables to avoid "contents
... exceed the available area" warnings.  Remove usage of
some non-Latin-1 characters.

Discussion: https://postgr.es/m/614600.1684537037@sss.pgh.pa.us
2023-05-21 11:21:19 -04:00
Tom Lane a2eb99a01e Expand some more uses of "deleg" to "delegation" or "delegated".
Complete the task begun in 9c0a0e2ed: we don't want to use the
abbreviation "deleg" for GSS delegation in any user-visible places.
(For consistency, this also changes most internal uses too.)

Abhijit Menon-Sen and Tom Lane

Discussion: https://postgr.es/m/949048.1684639317@sss.pgh.pa.us
2023-05-21 10:55:18 -04:00
Nathan Bossart f4001a5537 Fix remaining references to gss_accept_deleg.
These were missed in 9c0a0e2ed9.

Discussion: https://postgr.es/m/20230521031757.GA3835667%40nathanxps13
2023-05-20 20:32:56 -07:00
Bruce Momjian 9c0a0e2ed9 rename "gss_accept_deleg" to "gss_accept_delegation".
This is more consistent with existing GUC spelling.

Discussion: https://postgr.es/m/ZGdnEsGtNj7+fZoa@momjian.us
2023-05-20 21:32:54 -04:00
Bruce Momjian cf109ffc20 doc: PG 16 relnotes, misc updates
*  document to_reg* accepting OIDs
*  document pg_log_standby_snapshot()
*  document pg_input_is_valid() and pg_input_error_info()
*  handle rename of function to pg_split_walfile_name()
*  fix character encoding problem for Przemyslaw Sztoch
*  remove partition section

Reported-by: jian he, Tom Lane, Bertrand Drouvot
2023-05-20 21:03:13 -04:00
Tom Lane 0245f8db36 Pre-beta mechanical code beautification.
Run pgindent, pgperltidy, and reformat-dat-files.

This set of diffs is a bit larger than typical.  We've updated to
pg_bsd_indent 2.1.2, which properly indents variable declarations that
have multi-line initialization expressions (the continuation lines are
now indented one tab stop).  We've also updated to perltidy version
20230309 and changed some of its settings, which reduces its desire to
add whitespace to lines to make assignments etc. line up.  Going
forward, that should make for fewer random-seeming changes to existing
code.

Discussion: https://postgr.es/m/20230428092545.qfb3y5wcu4cm75ur@alvherre.pgsql
2023-05-19 17:24:48 -04:00
Bruce Momjian e5f85744ea doc: PG 16 relnotes, delete reverted grant, adjust version num
Reported-by: Nathan Bossart, Sehrope Sarkuni
2023-05-19 12:30:14 -04:00
Bruce Momjian 6ff33cdbab doc: PG 16 relnotes, merge REINDEX and reindexdb items
Reported-by: Vibhor Kumar
2023-05-19 09:30:00 -04:00
Bruce Momjian 1a620cbae5 doc: PG 16 relnotes, add missing parentheses
Reported-by: Hans Buschmann
2023-05-19 08:31:11 -04:00
Michael Paquier e7bff46e50 pageinspect: Fix gist_page_items() with included columns
Non-leaf pages of GiST indexes contain key attributes, leaf pages
contain both key and non-key attributes, and gist_page_items() ignored
the handling of non-key attributes.  This caused a few problems when
using gist_page_items() on a GiST index with INCLUDE:
- On a non-leaf page, the function would crash.
- On a leaf page, the function would work, but miss to display all the
values for included attributes.

This commit fixes gist_page_items() to handle such cases in a more
appropriate way, and now displays the values of key and non-key
attributes for each item separately in a style consistent with what
ruleutils.c would generate for the attribute list, depending on the page
type dealt with.  In a way similar to how a record is displayed, values
would be double-quoted for key or non-key attributes if required.

ruleutils.c did not provide a routine able to control if non-key
attributes should be displayed, so an extended() routine for index
definitions is added to work around the leaf and non-leaf page
differences.

While on it, this commit fixes a third problem related to the amount of
data reported for key attributes.  The code originally relied on
BuildIndexValueDescription() (used for error reports on constraints)
that would not print all the data stored in the index but the index
opclass's input type, so this limited the amount of information
available.  This switch makes gist_page_items() much cheaper as there is
no need to run ACL checks for each item printed, which is not an issue
anyway as superuser rights are required to execute the functions of
pageinspect.  Opclasses whose data cannot be displayed can rely on
gist_page_items_bytea().

The documentation of this function was slightly incorrect for the
output results generated on HEAD and v15, so adjust it on these
branches.

Author: Alexander Lakhin, Michael Paquier
Discussion: https://postgr.es/m/17884-cb8c326522977acb@postgresql.org
Backpatch-through: 14
2023-05-19 12:37:58 +09:00
Bruce Momjian 613a7eca9c doc: improve pg_walinspect and role membership items
Reported-by: Peter Geoghegan
2023-05-18 23:17:03 -04:00
Bruce Momjian ce3673dade doc: improve description of adding roles as members
Discussion: https://postgr.es/m/ZFvVZvQDliIWmOwg@momjian.us
2023-05-18 22:22:17 -04:00
Bruce Momjian f79ee34702 doc: update PG 16 relnotes for pg_walinspect changes
Reported-by: Peter Geoghegan
2023-05-18 21:44:45 -04:00
Tomas Vondra 428c0cae92 Show empty BRIN ranges in brin_page_items
Commit 3581cbdcd6 added a flag to identify empty BRIN ranges. This adds
the new flag to brin_page_items() output.

This is kept as a separate commit as it should not be backpatched.

Reviewed-by: Justin Pryzby, Matthias van de Meent, Alvaro Herrera
Discussion: https://postgr.es/m/402430e4-7d9d-6cf1-09ef-464d80afff3b@enterprisedb.com
2023-05-19 02:00:21 +02:00
Bruce Momjian 1158c8c4e3 doc: PG 16 relnotes, add freeze and update walinspect items
Reported-by: Peter Geoghegan
2023-05-18 18:53:28 -04:00
Bruce Momjian 07ef30a028 docs: re-order some PG 16 relnotes items
Reported-by: Jonathan Katz
2023-05-18 18:25:21 -04:00
Bruce Momjian d8a81108a8 doc: more PG 16 relnote wording improvements 2023-05-18 17:43:10 -04:00
Bruce Momjian 0791930aaa doc: add more sections to PG 16 release notes 2023-05-18 16:33:05 -04:00
Bruce Momjian 206a67e27f doc: first draft of the PG 16 release notes 2023-05-18 16:00:04 -04:00
Jeff Davis c9dc480a21 Fix documentation build broken by 1e16af8ab5. 2023-05-18 11:04:30 -07:00
Jeff Davis 1e16af8ab5 Doc improvements for language tags and custom ICU collations.
Separate the documentation for language tags themselves from the
available collation settings which can be included in a language tag.

Include tables of the available options, more details about the
effects of each option, and additional examples.

Also include an explanation of the "levels" of textual features and
how they relate to collation.

Discussion: https://postgr.es/m/25787ec7-4c04-9a8a-d241-4dc9be0b1ba3@postgresql.org
Reviewed-by: Jonathan S. Katz
2023-05-18 10:37:55 -07:00
Jeff Davis 6de31ce446 Reduce icu_validation_level default to WARNING.
Discussion: https://postgr.es/m/daa9f060aa2349ebc84444515efece49e7b32c5d.camel@j-davis.com
2023-05-17 13:18:40 -07:00
Andres Freund 093e5c57d5 Add writeback to pg_stat_io
28e626bde0 added the concept of IOOps but neglected to include writeback
operations. ac8d53dae5 added time spent doing these I/O operations. Without
counting writeback, checkpointer write time in the log often differed
substantially from that in pg_stat_io. To fix this, add IOOp IOOP_WRITEBACK
and track writeback in pg_stat_io.

Bumps catversion.

Author: Melanie Plageman <melanieplageman@gmail.com>
Reviewed-by: Kyotaro Horiguchi <horikyota.ntt@gmail.com>
Reported-by: Andres Freund <andres@anarazel.de>
Discussion: https://postgr.es/m/20230419172326.dhgyo4wrrhulovt6%40awork3.anarazel.de
2023-05-17 11:18:35 -07:00
Alexander Korotkov b9a7a82272 Revert "Add USER SET parameter values for pg_db_role_setting"
This reverts commit 096dd80f3c and its fixups beecbe8e50, afdd9f7f0e,
529da086ba, db93e739ac.

Catversion is bumped.

Discussion: https://postgr.es/m/d46f9265-ff3c-6743-2278-6772598233c2%40pgmasters.net
2023-05-17 20:28:57 +03:00
Michael Paquier 44e977d7ec doc: Fix ordering of entries in wait event table for I/O type
Issue spotted while reviewing a different patch touching this area.

Discussion: https://postgr.es/m/ZGM1U5D5EuBUbasi@paquier.xyz
2023-05-16 16:51:44 +09:00
Michael Paquier 08c45ae235 doc: Fix incorrect version list for Windows SDK
References to SDK 8.1a should have been cleaned up in 495ed0e, as only
version 10 and above are supported with Windows 10 and newer versions.

Reported-by: Thomas Munro
Discussion: https://postgr.es/m/CA+hUKG++qE9uVjQaTTD7oaC8a2T3h8K50=Eqyx9uUZvOHa__ww@mail.gmail.com
2023-05-15 16:02:07 +09:00
Thomas Munro 319bae9a8d Rename io_direct to debug_io_direct.
Give the new GUC introduced by d4e71df6 a name that is clearly not
intended for mainstream use quite yet.

Future proposals would drop the prefix only after adding infrastructure
to make it efficient.  Having the switch in the tree sooner is good
because it might lead to new discoveries about the hazards awaiting us
on a wide range of systems, but that name was too enticing and could
lead to cross-version confusion in future, per complaints from Noah and
Justin.

Suggested-by: Noah Misch <noah@leadboat.com>
Reviewed-by: Noah Misch <noah@leadboat.com>
Reviewed-by: Justin Pryzby <pryzby@telsasoft.com> (the idea, not the patch)
Reviewed-by: Tom Lane <tgl@sss.pgh.pa.us> (ditto)
Discussion: https://postgr.es/m/20230430041106.GA2268796%40rfd.leadboat.com
2023-05-15 10:31:14 +12:00
Tom Lane 51b2c08798 Tighten usage of PSQL_WATCH_PAGER.
Don't use PSQL_WATCH_PAGER when stdin/stdout are not a terminal.
This corresponds to the restrictions on when other commands will
use [PSQL_]PAGER.  There isn't a lot of sense in trying to use a
pager in non-interactive cases, and doing so allows an environment
setting to break our tests.

Also, ignore PSQL_WATCH_PAGER if it is set but empty or all-blank,
for the same reasons we ignore such settings of [PSQL_]PAGER (see
commit 18f8f784c).

No documentation change is really needed, since there is nothing
suggesting that these constraints on [PSQL_]PAGER didn't already
apply to PSQL_WATCH_PAGER too.  But I rearranged the text
a little to make it read more naturally (IMHO anyway).

Per report from Pavel Stehule.  Back-patch to v15 where
PSQL_WATCH_PAGER was introduced.

Discussion: https://postgr.es/m/CAFj8pRDTwFzmEWdA-gdAcUh0ZnxUioSfTMre71WyB_wNJy-8gw@mail.gmail.com
2023-05-12 16:11:14 -04:00
Peter Geoghegan 375407f494 Doc: Fix link to fillfactor reloption.
Fix a link from the "Heap-Only Tuples" documentation section.
Previously, its "fillfactor" link pointed to the "CREATE TABLE"
command's documentation.  Now the link directly points to the fillfactor
storage parameter documentation (which is about half way into the
"CREATE TABLE" sect1).

Oversight in commit 115464bb.

Backpatch: 12-, the first version with a usable reloption link.
2023-05-10 10:49:50 -07:00
Michael Paquier 605994651b Fix assertion failure when updating stats_fetch_consistency in a transaction
An update of the GUC stats_fetch_consistency in a transaction would be
able to trigger an assertion when doing cache->snapshot.  In this case,
when retrieving a pgstat entry after the switch, a new snapshot would be
rebuilt, confusing pgstat_build_snapshot() because a snapshot is already
cached with an unexpected mode ("cache").

In order to fix this problem, this commit adds a flag to force a
snapshot clear each time this GUC is changed.  Some tests are added to
check, while on it.

Some optimizations in avoiding the snapshot clear should be possible
depending on what is cached and the current GUC value, I guess, but this
solution is simple, and ensures that the state of the cache is updated
each time a new pgstat entry is fetched, hence being consistent with the
level wanted by the client that has set the GUC.

Note that cache->none and snapshot->none would not cause issues, as
fetching a pgstat entry would be retrieved from shared memory on the
second attempt, however a snapshot would still be cached.  Similarly,
none->snapshot and none->cache would build a new snapshot on the second
fetch attempt.  Finally, snapshot->cache would cache a new snapshot on
the second attempt.

Reported-by: Alexander Lakhin
Author: Kyotaro Horiguchi
Discussion: https://postgr.es/m/17804-2a118cd046f2d0e5@postgresql.org
backpatch-through: 15
2023-05-10 11:24:30 +09:00
Peter Geoghegan 5698f07947 Doc: update VACUUM FREEZE query conflict guidance.
Commit 1de58df4, which added page-level freezing, taught VACUUM to reuse
each page's "set-visibility-map" snapshotConflictHorizon for freezing
(at least in the vast majority of cases where freezing went ahead).
This made VACUUM FREEZE much less prone to generating recovery conflicts
on standbys; VACUUM FREEZE became only slightly more likely to cause
recovery conflicts than an equivalent VACUUM.

Update old documentation that specifically warned of the likelihood of
recovery conflicts from VACUUM FREEZE.  Explain the same general issue
(the issue of VACUUM generating recovery conflicts even in the absence
of dead row cleanup) using the example of conflicts caused by VISIBLE
WAL records.
2023-05-08 13:17:31 -07:00
Michael Paquier 0890f7d528 doc: Fix some markups in logical replication section
Author: Peter Smith
Reviewed-by: David Zhang
Discussion: https://postgr.es/m/CAHut+Pst11ac2hcmePt1=oTmBwTT=DAssRR1nsdoy4BT+68=Mg@mail.gmail.com
2023-05-08 13:47:36 +09:00
Peter Eisentraut 919c486a27 doc: New glossary entries
Add:

- "Restartpoint"
- "Log sequence number"

"LSN" was already listed in the Acronyms appendix, but it is more
suitable as a glossary entry, so move it there and have the acronyms
entry link into the glossary.

Also turn on DocBook parameter glossentry.show.acronym to show
acronyms for glossary entries, which is being used here.

Reviewed-by: Daniel Gustafsson <daniel@yesql.se>
Reviewed-by: Alvaro Herrera <alvherre@alvh.no-ip.org>
Discussion: https://www.postgresql.org/message-id/flat/60915312-62cd-9c94-0d94-556023ece45f%40enterprisedb.com
2023-05-04 07:32:09 +02:00