Skip to content

Wöchentlicher PostgreSQL Newsletter - 23. Januar 2011

Der Originalartikel befindet sich unter:

== Wöchentlicher PostgreSQL Newsletter - 23. Januar 2011 ==

== PostgreSQL Produkt Neuigkeiten ==

DBSolo 4.0, ein SQL Query Werkzeug, das PostgreSQL
unterstützt, ist erschienen.

== PostgreSQL Jobs im Januar ==

== PostgreSQL Lokal ==

Selena Deckelmann wird über die Entwicklung der PostgreSQL
Community am 7. Februar 2010 um 16 Uhr an der Oregon State
University in Corvallis, OR sprechen.

Der Call for Papers für den vierten Prager
Development Day ist eröffnet. Die Veranstaltung
findet am 10. Februar 2011 an der Charles
Universität in Prag statt.

Der PostgreSQLFr Call for Projects ist offen. Projekte müssen
PostgreSQL und die französisch-sprechende Community ansprechen.
Maile an appel-projets-2010 AT postgresql DOT fr.

PGDay findet dieses Jahr während der südkalifornischen Linux Ausstellung
(SCALE) im LAX Hilton Hotel in Los Angeles, Kalifornien am Freitag dem
25. Februar 2011 statt. Vorträge kannst du unter pgday-submissions AT
googlegroups DOT com einreichen.

PostgreSQL Conference East 2011: New York,
vom 22. bis 25. März

Das Open Database Camp findet vom 7. bis 9. Mai 2011 in Sardinien,
Italien statt.

PGCon findet am 19. und 20. Mai 2011 an der Universität
von Ottawa statt, vorher gibt es am 17. und 18. Mai
zwei Tage mit Trainings. Der Call for Papers ist offen.

== PostgreSQL in den News ==

Planet PostgreSQL:

Dieser wöchentliche PostgreSQL Newsletter wurde erstellt von David Fetter.

Sende Neuigkeiten und Ankündigungen bis Sonntag, 15 Uhr Pazifischer
Zeit. Bitte sende englische Beiträge an, deutsche an, italienische an, spanische an

== Reviews ==

ITAGAKI Takahiro reviewed Marko (johto) Tiikkaja's patch to add
transaction-scope advisory locks.

Anssi Kaariainen reviewed Dimitri Fontaine's patch to add EXTENSION
support to pg_dump, several times.

Chris Browne reviewed the patch to compact the fsync request queue.

Steve Singer reviewed the patch for log_hostname and pg_stat_activity.

Kevin Grittner reviewed the file_fdw patch.

Noah Misch reviewed the snapshot synchronization patch.

Jan Urbanski reviewed the patch to add wildcard search support for

Dimitri Fontaine reviewed the patch to add FOR KEY LOCK for foreign
key checks.

Stephen Frost reviewed the patch to add FOREACH ... IN ARRAY to

Marko (johto) Tiikkaja reviewed the patch to add ALTER TABLE ... ADD

== Angewandte Patches ==

Heikki Linnakangas pushed:

- Before exiting walreceiver, fsync() all the WAL received.  Otherwise
  WAL recovery will replay the un-flushed WAL after walreceiver has
  exited, which can lead to a non-recoverable standby if the system
  crashes hard at that point.;a=commitdiff;h=34ef02b4d4c06e2bae6ad09cfd6d9c097eb73743

- Set fallback_application_name in walreceiver.  Makes replication
  slaves identify themselves in the new pg_stat_replication view.;a=commitdiff;h=48075095ac3ce1aaa63624ea0148dbe5bcba3b09

- Fix thinko in comment. Spotted by Jim Nasby.;a=commitdiff;h=b1dc45c11d8e63df34044ea73e643f5fa9d8c316

- Don't require usage privileges on the foreign data wrapper when
  creating a foreign table. We check for usage privileges on the
  foreign server, that ought to be enough.  Shigeru HANADA.;a=commitdiff;h=8aea1373d8f88bf389def1af10d06f1e67e25249

- Add 'directory' format to pg_dump. The new directory format is
  compatible with the 'tar' format, in that untarring a tar format
  archive produces a valid directory format archive.  Joachim Wieland
  and Heikki Linnakangas;a=commitdiff;h=7f508f1c6b515df66d27f860b2faa7b5761fa55d

- Silence compiler warning about uninitialized variable, noted by
  Itagaki Takahiro.;a=commitdiff;h=56d77c9e56adbd856beba00af3dc607687d30198

Bruce Momjian pushed:

- Add getopt() support to test_fsync;  also fix printf() format

- In the docs, better distinguish server from client SSL settings in
  the documentation.  Ray Stell.  Also fix some libpq title
  capitalization problems.;a=commitdiff;h=74bcdfbe2dd656f04db4e883b5bdcdafddebff08

- github test.;a=commitdiff;h=2c38cce1be4f57e353805e529e6d993c9c28535e

- Remove "github test" that somehow got into my tree.  Sorry.;a=commitdiff;h=4acfd43a7d6194fa735a6b7b06a1554909123d41

- In test_fsync, adjust test headings to match wal_sync_method values;
  add more test cases for open_sync of different sizes.;a=commitdiff;h=8995440e387846261d18e728f11adc528ccc5c1b

- Move test_fsync to /contrib.;a=commitdiff;h=606a3d54fcd053c31e52886f4c69848a68777480

- Update C banner on new pg_test_fsync file.;a=commitdiff;h=b35bfcae937810f43fdf2327bcea2e8a03ccbf68

- Update SGML docs to point to new /contrib/pg_test_fsync.;a=commitdiff;h=5925aa09a9110fe0d12393c758812e7149546443

Alvaro Herrera pushed:

- Increment Py_None refcount for NULL array elements.  Per bug #5835
  by Julien Demoor Author: Alex Hunsaker;a=commitdiff;h=978445bece6ce3df55599ee971a4a5dc217bf34c

Tom Lane pushed:

- Fix miscalculation of itemsafter in array_set_slice().  If the slice
  to be assigned to was before the existing array lower bound
  (requiring at least one null element to spring into existence to
  fill the gap), the code miscalculated how many entries needed to be
  copied from the old array's null bitmap.  This could result in
  trashing the array's data area (as seen in bug #5840 from Karsten
  Loesing), or worse.  This has been broken since we first allowed the
  behavior of assigning to non-adjacent slices, in 8.2.  Back-patch to
  all affected versions.;a=commitdiff;h=bdd8ed973da9ab48aba2292b01f71d2f9968b82c

- Avoid detoast in texteq/textne/byteaeq/byteane for unequal-length
  strings.  We can get the length of a compressed or out-of-line datum
  without actually detoasting it.  If the lengths of two strings are
  unequal, we can then conclude they are unequal without detoasting.
  That saves considerable work in an admittedly less-common case,
  without costing anything much when the optimization doesn't apply.
  Noah Misch.;a=commitdiff;h=1b393f4e5db4fd6bbc86a4e88785b6945a1541d0

- Show correct datatype for pg_class.relpersistence, plus a typo fix.
  Thom Brown;a=commitdiff;h=357faea82e93712937cd109b48ce006789ec7a8f

- Fix pg_restore to do the right thing when escaping large objects.
  Specifically, this makes the workflow pg_dump -Fc -> pg_restore ->
  file produce correct output for BLOBs when the source database has
  standard_conforming_strings turned on.  It was already okay when
  that was off, or if pg_restore was told to restore directly into a
  database.  This is a back-port of commit
  b1732111f233bbb72788e92a627242ec28a85631 of 2009-08-04, with
  additional changes to emit old-style escaped bytea data instead of
  hex-style.  At the time, we had not heard of anyone encountering the
  problem in the field, so I judged it not worth the risk of changing
  back branches.  Now we do have a report, from Bosco Rama, so
  back-patch into 8.2 through 8.4.  9.0 and up are okay already.;a=commitdiff;h=2a1ef1011548e329f4eca86671401bf4124f9d1e

- Fix broken markup, also minor copy-editing.;a=commitdiff;h=0cf3db2175ec770097b9c44d9a8e1e8c281ee5a6

- Clean up pg_test_fsync commit.  Actually rename the program, rather
  than just claiming we did.  Hook it into the build system.  Get rid
  of useless dependency on libpq.  Clean up #include list and messy

- More pg_test_fsync cleanup.  Un-break Windows build (I hope) by
  making the HAVE_FSYNC_WRITETHROUGH code match the backend.  Fix
  incorrect program help message.  static-ize all functions.;a=commitdiff;h=cb38ab6d3b89eccb75b3337f8723cfc283fb77fb

- Suppress unused-variables warning when OPEN_SYNC_FLAG isn't defined.
  Per buildfarm.;a=commitdiff;h=3ae28ce8c437811bba47c09d1212c2d3c41cb7ff

- More pg_test_fsync fixups.  Reduce #includes to minimum actually
  needed; in particular include postgres_fe.h not postgres.h, so as to
  stop build failures on some platforms.  Use get_progname() instead
  of hardwired program name; improve error checking for command line
  syntax; bring error messages into line with style guidelines;
  include strerror result in die() cases.;a=commitdiff;h=37eb2cd4ad4c3323f1c7ed1c893c9d645fbaeb1a

- Suppress possibly-uninitialized-variable warnings from gcc 4.5.  It
  appears that gcc 4.5 can issue such warnings for whole structs, not
  just scalar variables as in the past.  Refactor some pg_dump code
  slightly so that the OutputContext local variables are always
  initialized, even if they won't be used.  It's cheap enough to not
  be worth worrying about.;a=commitdiff;h=e2627258c3cc43b8b00c5c29c35933a33259e718

- Suppress "control reaches end of non-void function" warning from gcc
  4.5.  Not sure why I'm seeing this on Fedora 14 and not earlier
  versions.  Seems like a regression that gcc no longer knows that
  DIE() doesn't return.  Still, adding a dummy return is harmless

- Allow the wal_buffers setting to be auto-tuned to a reasonable
  value.  If wal_buffers is initially set to -1 (which is now the
  default), it's replaced by 1/32nd of shared_buffers, with a minimum
  of 8 (the old default) and a maximum of the XLOG segment size.  The
  allowed range for manual settings is still from 4 up to whatever
  will fit in shared memory.  Greg Smith, with implementation
  correction by me.;a=commitdiff;h=0f73aae13def660371c34c8feda6e684e6366bdb

- Quick hack to un-break plpython regression tests.  It's not clear to
  me what should happen to the other plpython_unicode variant expected
  files, but this patch gets things passing on my own machines and at
  least some of the buildfarm.;a=commitdiff;h=cc73c160507588bdc5822d7f2bb79d6b3a386761

- Suppress uninitialized-variable warning.;a=commitdiff;h=b3cfcdaad27bea9bb86d6de6cbf8d184c16fbceb

- Add .gitignore file to silence complaints about pg_basebackup.;a=commitdiff;h=10e99f15d423b1730929af1992593c6649952fd5

- Revert "Factor out functions responsible for caching I/O routines".
  This reverts commit 740e54ca84c437fd67524f97a3ea9ddea752e208, which
  seems to have tickled an optimization bug in gcc 4.5.x, as reported
  upstream at Since
  this patch had no purpose beyond code beautification, it's not worth
  expending a lot of effort to look for another workaround.;a=commitdiff;h=de3c2d6e928b0f7fb2840914351b96fecce2a30d

- Improve getObjectDescription's display of pg_amop and pg_amproc
  entries.  Include the lefttype/righttype columns explicitly (instead
  of assuming the reader can deduce them from the operator or function
  description), and move the operator or function description to the
  end of the string, to make it clearer that it's a referenced object
  and not the amop or amproc item itself.  Per extensive discussion of
  Andreas Karlsson's original patch.  Andreas Karlsson, Tom Lane;a=commitdiff;h=dd5f0db96ba68553e3ab2c1d9d117863a5637c67

- Fix another portability issue in pg_basebackup.  The target of
  sscanf with a %o format had better be of integer width, but "mode_t"
  conceivably isn't that.  Another compiler warning seen only on some
  platforms; this one I think is potentially a real bug and not just a

Peter Eisentraut pushed:

- Use HTABs instead of Python dictionary objects to cache procedures
  Two separate hash tables are used for regular procedures and for
  trigger procedures, since the way trigger procedures work is quite
  different from normal stored procedures.  Change the signatures of
  PLy_procedure_{get,create} to accept the function OID and a Boolean
  flag indicating whether it's a trigger.  This should make
  implementing a PL/Python validator easier.  Using HTABs instead of
  Python dictionaries makes error recovery easier, and allows for
  procedures to be cached based on their OIDs, not their names.  It
  also allows getting rid of the PyCObject field that used to hold a
  pointer to PLyProcedure, since PyCObjects are deprecated in Python
  2.7 and replaced by Capsules in Python 3.  Jan Urbański;a=commitdiff;h=46211da1b84bc3537e799ee1126098e71c2428e8

- Skip dropped attributes when converting Python objects to tuples.
  Pay attention to the attisdropped field and skip over TupleDesc
  fields that have it set.  Not a real problem until we get table
  returning functions, but it's the right thing to do anyway.  Jan

- Free plan values in the PLyPlanObject dealloc function.  Jan

- Use palloc in TopMemoryContext instead of malloc.  As discussed,
  even if the PL needs a permanent memory location, it should use
  palloc, not malloc.  It also makes error handling easier.  Jan

- Use PyObject_New instead of PyObject_NEW.  The latter is
  undocumented and the speed gain is negligible.  Jan Urbański.;a=commitdiff;h=d9a95c0adb11f7a3ca5aa9ab8a900018832ed4ea

- Improve message for errors in compiling anonymous PL/Python blocks
  The previous code would try to print out a null pointer.  Jan

- Fix an error when a set-returning function fails halfway through the
  execution.  If the function using yield to return rows fails
  halfway, the iterator stays open and subsequent calls to the
  function will resume reading from it.  The fix is to unref the
  iterator and set it to NULL if there has been an error.  Jan

- Add braces around an if block, for readability.  Jan Urbański,
  reviewed by Peter Eisentraut, Álvaro Herrera, Tom Lane :-);a=commitdiff;h=fbed5d48307528c8b49ba48e741817e75146ea8f

- Fix typo.  Hitoshi Harada;a=commitdiff;h=81f79dbf2e551978300ee85d42026e26f932089a

- Factor out functions responsible for caching I/O routines.  This
  makes PLy_procedure_create a bit more manageable.  Jan Urbański;a=commitdiff;h=740e54ca84c437fd67524f97a3ea9ddea752e208

- Fix wrong comment.  Hitoshi Harada.;a=commitdiff;h=14b9f69cb2077c65a09df78d167d45c35b1d7973

- Correctly add exceptions to the plpy module for Python 3.  The way
  the exception types where added to the module was wrong for Python
  3.  Exception classes were not actually available from plpy.  Fix
  that by factoring out code that is responsible for defining new
  Python exceptions and make it work with Python 3.  New regression
  test makes sure the plpy module has the expected contents.  Jan
  Urbanśki, slightly revised by me.;a=commitdiff;h=4609caf3645ae975724af1f7f57f831e516cf220

- Get rid of the global variable holding the error state.  Global
  error handling led to confusion and was hard to manage.  With this
  change, errors from PostgreSQL are immediately reported to Python as
  exceptions.  This requires setting a Python exception after
  reporting the caught PostgreSQL error as a warning, because PLy_elog
  destroys the Python exception state.  Ideally, all places where
  PostgreSQL errors need to be reported back to Python should be
  wrapped in subtransactions, to make going back to Python from a
  longjmp safe.  This will be handled in a separate patch.  Jan

Magnus Hagander pushed:

- Log replication connections only when log_connections is on.
  Previously we'd always log replication connections, with no way to
  turn them off.;a=commitdiff;h=6e1726d082b5a9c305ed44a69ff50bc3407d01a2

- Link libpgport into pg_test_fsync on msvc;a=commitdiff;h=f5a0fd2f3bbe233802cbbddfe8bdf086c69c1ac3

- Add pg_basebackup tool for streaming base backups.  This tool makes
  it possible to do the pg_start_backup/ copy files/pg_stop_backup
  step in a single command.  There are still some steps to be done
  before this is a complete backup solution, such as the ability to
  stream the required WAL logs, but it's still usable, and could do
  with some buildfarm coverage.  In passing, make the checkpoint
  request optionally fast instead of hardcoding it.  Magnus Hagander,
  reviewed by Fujii Masao and Dimitri Fontaine;a=commitdiff;h=048d148fe63102fafb2336ab5439c950dea7f692

- filemode is parsed on win32 even if never used.  Per buildfarm

- Only show pg_stat_replication details to superusers.;a=commitdiff;h=f88a638199d8505e7a01548cb647f908ae1e469f

- Use pg_strcasecmp instead of strcasecmp for portability.  Per

- Reorder includes to unbreak MSVC.;a=commitdiff;h=39e911e28a7a998d9439c0f5886c97fbbfc72a75

- Make walsender options order-independent While doing this, also move
  base backup options into a struct instead of increasing the number
  of parameters to multiple functions for each new option.;a=commitdiff;h=e5487f65fdbd05716ade642a3ae1c5c6e85b6f22

Robert Haas pushed:

- Document that WITH queries are also called Common Table Expressions.
  Peter Geoghegan, reviewed by Stephen Frost.;a=commitdiff;h=92f7eebbbd6554f0414ab869abd8733cef751249

- Add new psql command \dL to list languages.  Original patch by
  Fernando Ike, revived by Josh Kuperschmidt, reviewed by Andreas
  Karlsson, and in earlier versions by Tom Lane and Peter Eisentraut.;a=commitdiff;h=9c5e2c120be42fbd1a743ddf539ff451e1cce23b

- Make ALTER TABLE revalidate uniqueness and exclusion constraints.
  Failure to do so can lead to constraint violations.  This was broken
  by commit 1ddc2703a936d03953657f43345460b9242bbed1 on 2010-02-07, so
  back-patch to 9.0.  Noah Misch.  Regression test by me.;a=commitdiff;h=8ceb24568054232696dddc1166a8563bc78c900a

- Emphasize where OVER needs to be when using a window function.  Jeff

- Code cleanup for assign_XactIsoLevel.  The new coding avoids a
  spurious debug message when a transaction that has changed the
  isolation level has been rolled back.  It also allows the property
  to be freely changed to the current value within a subtransaction.
  Kevin Grittner, with one small change by me.;a=commitdiff;h=fb4c5d2798730f60b102d775f22fb53c26a6445d

- Avoid treating WAL senders as normal backends.  The previous coding
  treated anything that wasn't an autovacuum launcher as a normal
  backend, which is wrong now that we also have WAL senders.  Fujii
  Masao, reviewed by Robert Haas, Alvaro Herrera, Tom Lane, and Bernd

- Code cleanup for assign_transaction_read_only.  As in commit
  fb4c5d2798730f60b102d775f22fb53c26a6445d on 2011-01-21, this avoids
  spurious debug messages and allows idempotent changes at any time.
  Along the way, make assign_XactIsoLevel allow idempotent changes
  even when not within a subtransaction, to be consistent with the new
  coding of assign_transaction_read_only and because there's no
  compelling reason to do otherwise.  Kevin Grittner, with some

- sepgsql, an SE-Linux integration for PostgreSQL.  This is still
  pretty rough - among other things, the documentation needs work, and
  the messages need a visit from the style police - but this gets the
  basic framework in place.  KaiGai Kohei.;a=commitdiff;h=968bc6fac91d6aaca594488ab85c179b686cbbdd

- First round of cleanup of sepgsql code and documentation.  Robert
  Haas, with a few suggestions from Thom Brown.;a=commitdiff;h=194c8f713aa62a528afa4ce4274b80aaff9eb264

- Blind attempt to exclude sepgsql from MSVC build system.;a=commitdiff;h=c26ac226e45fbf84cd63588498c00da9417aebc1

- PGXS support for contrib/hstore.  Joey Adams;a=commitdiff;h=41611f16e933dafa9c3ae0477f89537ea1459eb6

Andrew Dunstan pushed:

- Silence flex warnings about DOS file paths in MSVC builds.;a=commitdiff;h=6c41cf5977ca3f13159b980d4b216e3bc9df90e8

== Abgelehnte Patches (bis jetzt) ==

Pavel Stehule's patch to remove redundant code from PL/pgsql.  Too
much added complexity for too little benefit.

== Eingesandte Patches ==

Alexander Korotkov sent in another revision of the patch to add
wildcards to contrib/pg_trgm.

Heikki Linnakangas sent in a patch to fix some typos, etc., in the SSI

Dimitri Fontaine sent in two more revisions of the patch to add

Shigeru HANADA sent in another revision of the patch to add file_fdw,
which implements file-based access in SQL/MED.

ITAGAKI Takahiro sent in another revision of the MULTISET patch.

Magnus Hagander sent in two more revisions of the patch to add
pg_basebackup to streaming backups.

Shigeru HANADA sent in another revision of the patches to implement
the foreign data wrapper API for SQL/MED.

Jan Urbanski sent in another revision of the PL/Python validator

Joachim Wieland sent in another revision of the patch to implement
synchronized snapshots.

Stephen Frost sent in another revision of the patch to allow logging

Fujii Masao sent in another revision of the patch to add "pg_ctl
promote," used when the replication origin has failed, or is presumed
to have failed.

Robert Haas sent in another revision of the patch to limit hint bit I/O.

Noah Misch sent in a review and another revision of the patch to add

Jan Urbanski sent another flock of patches to refactor PL/PythonU.

Stephen Frost sent in another revision of the patch to add FOREACH ...
IN ARRAY to PL/pgsql.

Jeff Davis sent in another revision of the patch to add range types,
this one with generic range functions.

Stephen Frost reviewed and revised the patch to add nfiltered to
EXPLAIN output.

Kevin Grittner sent in another revision of the patch to implement true

Noah Misch sent in another revision of the ALTER TYPE patch.

Kris Shannon sent in a patch to fix gripes with an ECPG conversion
script, which was using deprecated features in Perl.

Per review from Hitoshi Harada, Jan Urbanski sent in another revision
of the patch to fix table functions in PL/PythonU.

Pavel Stehule sent in another revision of the patch to add FOREACH ...
IN ARRAY to PL/pgsql.

Fujii Masao sent in another revision of the patch to fix a bug in


No Trackbacks


Display comments as Linear | Threaded

No comments

Add Comment

Enclosing asterisks marks text as bold (*word*), underscore are made via _word_.
E-Mail addresses will not be displayed and will only be used for E-Mail notifications.
To leave a comment you must approve it via e-mail, which will be sent to your address after submission.
Form options