Commit Graph

10435 Commits

Author SHA1 Message Date
Robert Haas 463f2625a5 Support SECURITY LABEL on databases, tablespaces, and roles.
This requires a new shared catalog, pg_shseclabel.

Along the way, fix the security_label regression tests so that they
don't monkey with the labels of any pre-existing objects.  This is
unlikely to matter in practice, since only the label for the "dummy"
provider was being manipulated.  But this way still seems cleaner.

KaiGai Kohei, with fairly extensive hacking by me.
2011-07-20 13:18:24 -04:00
Robert Haas d79a601fd9 Improve sepgsql and SECURITY LABEL documentation.
KaiGai Kohei, based on feedback from Yeb Havinga, with some
corrections by me.
2011-07-20 09:24:26 -04:00
Robert Haas 550cd074f9 Minor improvement to pg_seclabel documentation.
This is a bit more consistent with the way pg_description is
documented, and also include a useful cross-link.
2011-07-20 09:24:22 -04:00
Simon Riggs 6ba77bce93 Minor doc additions for cascading replication. 2011-07-19 09:07:42 +01:00
Simon Riggs 5286105800 Cascading replication feature for streaming log-based replication.
Standby servers can now have WALSender processes, which can work with
either WALReceiver or archive_commands to pass data. Fully updated
docs, including new conceptual terms of sending server, upstream and
downstream servers. WALSenders terminated when promote to master.

Fujii Masao, review, rework and doc rewrite by Simon Riggs
2011-07-19 03:40:03 +01:00
Tom Lane 3d4890c0c5 Add GET STACKED DIAGNOSTICS plpgsql command to retrieve exception info.
This is more SQL-spec-compliant, more easily extensible, and better
performing than the old method of inventing special variables.

Pavel Stehule, reviewed by Shigeru Hanada and David Wheeler
2011-07-18 14:47:18 -04:00
Robert Haas 367bc426a1 Avoid index rebuild for no-rewrite ALTER TABLE .. ALTER TYPE.
Noah Misch.  Review and minor cosmetic changes by me.
2011-07-18 11:04:43 -04:00
Robert Haas 3cba8999b3 Create a "fast path" for acquiring weak relation locks.
When an AccessShareLock, RowShareLock, or RowExclusiveLock is requested
on an unshared database relation, and we can verify that no conflicting
locks can possibly be present, record the lock in a per-backend queue,
stored within the PGPROC, rather than in the primary lock table.  This
eliminates a great deal of contention on the lock manager LWLocks.

This patch also refactors the interface between GetLockStatusData() and
pg_lock_status() to be a bit more abstract, so that we don't rely so
heavily on the lock manager's internal representation details.  The new
fast path lock structures don't have a LOCK or PROCLOCK structure to
return, so we mustn't depend on that for purposes of listing outstanding
locks.

Review by Jeff Davis.
2011-07-18 00:49:28 -04:00
Peter Eisentraut 7ed8f6c517 Remove claim that the project is not represented in the SQL working group
We have a few people involved there now.
2011-07-18 07:30:00 +03:00
Peter Eisentraut 3835855589 Note that information_schema.sql_languages was removed in SQL:2008 2011-07-18 07:26:30 +03:00
Robert Haas b59d2fe497 Add pg_opfamily_is_visible.
We already have similar functions for many other object types, including
operator classes, so it seems like we should have this one, too.

Extracted from a larger patch by Josh Kupershmidt
2011-07-17 23:23:55 -04:00
Tom Lane 23e5b16c71 Add temp_file_limit GUC parameter to constrain temporary file space usage.
The limit is enforced against the total amount of temp file space used by
each session.

Mark Kirkwood, reviewed by Cédric Villemain and Tatsuo Ishii
2011-07-17 14:19:31 -04:00
Tom Lane ed7ed76712 Add an errdetail_internal() ereport auxiliary routine.
This function supports untranslated detail messages, in the same way that
errmsg_internal supports untranslated primary messages.  We've needed this
for some time IMO, but discussion of some cases in the SSI code provided
the impetus to actually add it.

Kevin Grittner, with minor adjustments by me
2011-07-16 14:22:15 -04:00
Peter Eisentraut bf3c585681 Set information_schema.tables.commit_action to null
The commit action of temporary tables is currently not cataloged, so
we can't easily show it.  The previous value was outdated from before
we had different commit actions.
2011-07-15 21:11:14 +03:00
Bruce Momjian c1129a14e1 Doc clarification for pg_locks columns.
Florian Pflug
2011-07-15 13:12:36 -04:00
Bruce Momjian 1be9cdf6aa In docs, start window function sentence with "The asterisk (*)" rather
than "*";  it is confusing to start a sentence with a symbol.
2011-07-14 17:59:49 -04:00
Alvaro Herrera c529f8800e Fix broken markup 2011-07-14 13:43:01 -04:00
Peter Eisentraut f4678c205a Set information_schema.routines.is_udt_dependent to NO
It previously said YES, but that is incorrect.
2011-07-14 19:18:17 +03:00
Peter Eisentraut a99d45b805 Small update on suggested startup file locations
Debian/Ubuntu don't have a /etc/rc.d/ directory, so add some
alternative names as suggestions.
2011-07-14 19:07:39 +03:00
Peter Eisentraut 469a1087e2 Remove README.mb.big5 and README.mb.jp
They were wildly outdated.
2011-07-14 18:28:07 +03:00
Peter Eisentraut 0527a454ec Implement information schema interval_type columns
Also correct reporting of interval precision when field restrictions
are specified in the typmod.
2011-07-13 20:32:08 +03:00
Bruce Momjian 80a1d16935 Use clearer woring for pg_locks columns, identifying which items are
related to lock objects.
2011-07-13 11:42:17 -04:00
Peter Eisentraut 3315020a09 Fix and clarify information schema interval_precision fields
The fields were previously wrongly typed as character_data; change to
cardinal_number.  Update the documentation and the implementation to
show more clearly that this applies to a feature not available in
PostgreSQL, rather than just not yet being implemented in the
information schema.
2011-07-11 18:49:44 +03:00
Andrew Dunstan 75726307e6 Improve wording of documentation on default privileges.
Per recent -hackers discussion.
2011-07-11 11:12:34 -04:00
Peter Eisentraut 7544064b15 Add item about Clang support to 9.1 release notes 2011-07-08 17:04:49 +03:00
Peter Eisentraut f05c65090a Message style improvements 2011-07-08 07:37:04 +03:00
Tom Lane c59b8ba6cd Update examples for string-related functions.
In the example for decode(), show the bytea result in hex format,
since that's now the default.  Use an E'' string in the example for
quote_literal(), so that it works regardless of the
standard_conforming_strings setting.  On the functions-for-binary-strings
page, leave the examples as-is for readability, but add a note pointing out
that they are shown in escape format.  Per comments from Thom Brown.

Also, improve the description for encode() and decode() a tad.

Backpatch to 9.0, where bytea_output was introduced.
2011-07-07 19:34:19 -04:00
Tom Lane 997d5b488a Update 9.1 release notes to reflect commits through today. 2011-07-07 17:56:15 -04:00
Tom Lane 60a81ad133 Reclassify replication-related GUC variables as "master" and "standby".
Per discussion, this structure seems more understandable than what was
there before.  Make config.sgml and postgresql.conf.sample agree.

In passing do a bit of editorial work on the variable descriptions.
2011-07-07 15:11:41 -04:00
Tom Lane a195e3c34f Finish disabling reduced-lock-levels-for-DDL feature.
Previous patch only covered the ALTER TABLE changes, not changes in other
commands; and it neglected to revert the documentation changes.
2011-07-07 13:15:15 -04:00
Robert Haas c7f23494c1 Add \ir command to psql.
\ir is short for "include relative"; when used from a script, the
supplied pathname will be interpreted relative to the input file,
rather than to the current working directory.

Gurjeet Singh, reviewed by Josh Kupershmidt, with substantial further
cleanup by me.
2011-07-06 11:45:13 -04:00
Tom Lane 3b3152853a Restructure foreign data wrapper chapter so it has more than one section.
As noted by Laurenz Albe, our SGML tools deal rather oddly with chapters
having just one <sect1>.  Perhaps the tooling could be fixed, but really
the design of this chapter's introduction is pretty bogus anyhow.  Split
it into a true introduction and a <sect1> about the FDW functions, so
that it reads better and dodges the lack-of-a-chapter-TOC problem.
2011-07-05 15:54:45 -04:00
Tom Lane 52a4255055 Improve documentation about foreign data wrapper validator functions.
Modified version of a patch by Shigeru Hanada.
2011-07-05 15:38:18 -04:00
Magnus Hagander cd34647c66 Fix typo in sslmode documentation
Per bug #6089, noted by Sidney Cadot
2011-07-05 09:45:19 +02:00
Peter Eisentraut d479a0f92f Small documentation tweaks 2011-07-05 00:00:14 +03:00
Peter Eisentraut 6fbc80349f Set user_defined_types.data_type to null
On re-reading the standard, this field is only used for distinct or
reference types.
2011-07-04 23:09:42 +03:00
Heikki Linnakangas e24662c423 Clarify that you need ActiveState perl 5.8 *or later* to build on Windows. 2011-07-04 22:42:17 +03:00
Heikki Linnakangas f7ea6beaf4 Remove silent_mode. You get the same functionality with "pg_ctl -l
postmaster.log", or nohup.

There was a small issue with LINUX_OOM_ADJ and silent_mode, namely that with
silent_mode the postmaster process incorrectly used the OOM settings meant
for backend processes. We certainly could've fixed that directly, but since
silent_mode was redundant anyway, we might as well just remove it.
2011-07-04 14:35:44 +03:00
Simon Riggs 2c3d9db56d Reset ALTER TABLE lock levels to AccessExclusiveLock in all cases.
Locks on inheritance parent remain at lower level, as they were before.
Remove entry from 9.1 release notes.
2011-07-04 09:31:40 +01:00
Tom Lane 4fa046a39e Fix omissions in documentation of the pg_roles view.
Somehow, column rolconfig got removed from the documentation of the
pg_roles view in the 9.0 cycle, although the column is actually still
there.  In 9.1, we'd also forgotten to document the rolreplication column.
Spotted by Sakamoto Masahiko.
2011-07-03 22:12:14 -04:00
Bruce Momjian cc81d9969c In the pg_upgrade docs, move 50432 port mention to the place where we
talk about client access.
2011-07-01 18:36:00 -04:00
Bruce Momjian a88f4496b7 Change pg_upgrade to use port 50432 by default to avoid unintended
client connections during the upgrade.  Also rename data/bin/port
environment variables to being with 'PG'.  Also no longer honor PGPORT.
2011-07-01 18:17:12 -04:00
Alvaro Herrera 897795240c Enable CHECK constraints to be declared NOT VALID
This means that they can initially be added to a large existing table
without checking its initial contents, but new tuples must comply to
them; a separate pass invoked by ALTER TABLE / VALIDATE can verify
existing data and ensure it complies with the constraint, at which point
it is marked validated and becomes a normal part of the table ecosystem.

An non-validated CHECK constraint is ignored in the planner for
constraint_exclusion purposes; when validated, cached plans are
recomputed so that partitioning starts working right away.

This patch also enables domains to have unvalidated CHECK constraints
attached to them as well by way of ALTER DOMAIN / ADD CONSTRAINT / NOT
VALID, which can later be validated with ALTER DOMAIN / VALIDATE
CONSTRAINT.

Thanks to Thom Brown, Dean Rasheed and Jaime Casanova for the various
reviews, and Robert Hass for documentation wording improvement
suggestions.

This patch was sponsored by Enova Financial.
2011-06-30 11:24:31 -04:00
Peter Eisentraut 21f1e15aaf Unify spelling of "canceled", "canceling", "cancellation"
We had previously (af26857a27)
established the U.S. spellings as standard.
2011-06-29 09:28:46 +03:00
Peter Eisentraut 615c384972 Implement the collation columns of various information schema views
Fill in the collation columns of the views attributes, columns,
domains, and element_types.  Also update collation information in
sql_implementation_info.
2011-06-28 17:49:28 +03:00
Peter Eisentraut 5594d14696 Add composite-type attributes to information_schema.element_types view 2011-06-28 16:08:52 +03:00
Robert Haas 66a36ef949 Mention that SSPI authentication can use GSSAPI on non-Windows systems.
As noted by Christian Ullrich.
2011-06-27 10:38:45 -04:00
Robert Haas eb03cff820 Documentation improvements for pg_locks with respect to SSI.
Explain that querying pg_locks does not simultaneously lock both the
normal lock manager and the predicate lock manager.

Per discussion with Kevin Grittner.
2011-06-24 16:09:35 -04:00
Bruce Momjian 194e6ee74b In pg_upgrade docs, clarify that link mode uses "hard" links.
Backpatch to 9.1 and 9.0.
2011-06-23 19:58:14 -04:00
Peter Eisentraut d34e142c51 Add information schema views role_udt_grants, udt_privileges, user_defined_types 2011-06-23 22:12:46 +03:00