[ANNOUNCE] == PostgreSQL Weekly News - September 17 2017 ==
От | David Fetter |
---|---|
Тема | [ANNOUNCE] == PostgreSQL Weekly News - September 17 2017 == |
Дата | |
Msg-id | 20170918045902.GA4968@fetter.org обсуждение исходный текст |
Список | pgsql-announce |
== PostgreSQL Weekly News - September 17 2017 == PGConf India 2018 will be on February 22-23, 2018 in Bengaluru, Karnataka. Proposals are due via https://goo.gl/forms/F9hRjOIsaNasVOAz2 by October 31st, 2017. http://pgconf.in/ == PostgreSQL Product News == PostGIS 2.4.0 rc1 the industry standard geographic information system package for PostgreSQL, released. http://postgis.net/2017/09/13/postgis-2.4.0rc1 PostgreSQL Automatic Failover (PAF) v2.2.0 released. https://github.com/dalibo/PAF/releases/tag/v2.2.0 oracle_fdw 2.0.0 released. https://laurenz.github.io/oracle_fdw == PostgreSQL Jobs for September == http://archives.postgresql.org/pgsql-jobs/2017-09/ == PostgreSQL Local == PGDay.IT 2017 will take place October 13th, in Milan, Italy. http://pgday.it PostgreSQL Conference Europe 2017 will be held on October 24-27, 2017 in the Warsaw Marriott Hotel, in Warsaw, Poland. https://2017.pgconf.eu/ PGConf Local: Seattle will be held November 13 - 14, 2017. https://www.pgconf.us/#Seattle2017 PGDay Australia 2017 will be held on November 17 in Melbourne. The CfP is open through September 8, 2017 at https://goo.gl/5d9EbT http://2017.pgday.com.au/ 2ndQuadrant PostgreSQL Conference 2017 (2Q PGConf, for short) will be hosted on November 6th & 7th in New York City, and November 9th in Chicago. http://www.2qpgconf.com/ PostgreSQL Session November 17th, 2017, in Paris, France. The CfP is open until September 30, 2017 at call-for-paper AT postgresql-sessions DOT org. Details at http://blog.dalibo.com/2017/08/29/cfp_pgsession9.html PGConf Local: Austin will be held December 4 - 5, 2017. Call for Papers is now open at https://www.pgconf.us/conferences/Austin2017 PGConf.ASIA 2017 will take place on December 4-6 2017 in Akihabara, Tokyo, Japan. http://www.pgconf.asia/EN/2017/ == PostgreSQL in the News == Planet PostgreSQL: http://planet.postgresql.org/ PostgreSQL Weekly News is brought to you this week by David Fetter Submit news and announcements by Sunday at 3:00pm EST5EDT. Please send English language ones to david@fetter.org, German language to pwn@pgug.de, Italian language to pwn@itpug.org. == Applied Patches == Peter Eisentraut pushed: - Fix DROP SUBSCRIPTION hang. When ALTER SUBSCRIPTION DISABLE is run in the same transaction before DROP SUBSCRIPTION, thelatter will hang because workers will still be running, not having seen the DISABLE committed, and DROP SUBSCRIPTION willwait until the workers have vacated the replication origin slots. Previously, DROP SUBSCRIPTION killed the logical replicationworkers immediately only if it was going to drop the replication slot, otherwise it scheduled the worker killingfor the end of the transaction, as a result of 7e174fa793a2df89fe03d002a5087ef67abcdde8. This, however, causes thepresent problem. To fix, kill the workers immediately in all cases. This covers all cases: A subscription that doesn'thave a replication slot must be disabled. It was either disabled in the same transaction, or it was already disabledbefore the current transaction, but then there shouldn't be any workers left and this won't make a difference. Reported-by:Arseny Sher <a.sher@postgrespro.ru> Discussion: https://www.postgresql.org/message-id/flat/87mv6av84w.fsf%40ars-thinkpad https://git.postgresql.org/pg/commitdiff/8edacab209957520423770851351ab4013cb0167 - Message style fixes. https://git.postgresql.org/pg/commitdiff/821fb8cdbf700a8aadbe12d5b46ca4e61be5a8a8 - doc: Document function pointer source code style. as implemented in 1356f78ea93395c107cbc75dc923e29a0efccd8a https://git.postgresql.org/pg/commitdiff/3612019a7925012445af29b9ea7af84bd68a5932 - pg_receivewal: Add --endpos option. This is primarily useful for making tests of this utility more deterministic, to avoidthe complexity of starting pg_receivewal as a deamon in TAP tests. While this is less useful than the equivalent pg_recvlogicaloption, users can as well use it for example to enforce WAL streaming up to a end-of-backup position, to saveonly a minimal amount of WAL. Use this new option to stream WAL data in a deterministic way within a new set of TAPtests. Author: Michael Paquier <michael.paquier@gmail.com> https://git.postgresql.org/pg/commitdiff/6d9fa52645e71711410a66b5349df3be0dd49608 - Allow custom search filters to be configured for LDAP auth. Before, only filters of the form "(<ldapsearchattribute>=<user>)"could be used to search an LDAP server. Introduce ldapsearchfilter so that more generalfilters can be configured using patterns, like "(|(uid=$username)(mail=$username))" and "(&(uid=$username) (objectClass=posixAccount))". Also allow search filters to be included in an LDAP URL. Author: Thomas Munro Reviewed-By:Peter Eisentraut, Mark Cave-Ayland, Magnus Hagander Discussion: https://postgr.es/m/CAEepm=0XTkYvMci0WRubZcf_1am8=gP=7oJErpsUfRYcKF2gwg@mail.gmail.com https://git.postgresql.org/pg/commitdiff/83aaac41c66959a3ebaec7daadc4885b5f98f561 - doc: Document default scope in LDAP URL. https://git.postgresql.org/pg/commitdiff/58bd60995f1c7470c0542f591b303bcc586a5d5f - doc: Remove useless marked section. This was left around when this text was moved from installation.sgml in c5ba11f8fb1701441b96a755ea410b96bfe36170. https://git.postgresql.org/pg/commitdiff/2eeaa74b5ba20bc75bbaf10837a1ae966094d6cc - Define LDAP_NO_ATTRS if necessary. Commit 83aaac41c66959a3ebaec7daadc4885b5f98f561 introduced the use of LDAP_NO_ATTRSto avoid requesting a dummy attribute when doing search+bind LDAP authentication. It turns out that not allLDAP implementations define that macro, but its value is fixed by the protocol so we can define it ourselves if it's missing. Author: Thomas Munro Reported-By: Ashutosh Sharma Discussion: https://postgr.es/m/CAE9k0Pm6FKCfPCiAr26-L_SMGOA7dT_k0%2B3pEbB8%2B-oT39xRpw%40mail.gmail.com https://git.postgresql.org/pg/commitdiff/1a2fdc99a4b341feb6c01304e58f01dd0e095d9a - Improve error message in WAL sender. The previous error message when attempting to run a general SQL command in a physicalreplication WAL sender was a bit sloppy. Reported-by: Fujii Masao <masao.fujii@gmail.com> https://git.postgresql.org/pg/commitdiff/61975d6c2cf5bbcf40a2e3160914ecad7a21df1a - doc: Remove incorrect SCRAM protocol documentation. The documentation claimed that one should send "pg_same_as_startup_message"as the user name in the SCRAM messages, but this did not match the actual implementation, soremove it. https://git.postgresql.org/pg/commitdiff/089880ba9af5f95e1a3b050874a90dbe5c33fd61 - Fix bool/int type confusion. Using ++ on a bool variable doesn't work well when stdbool.h is in use. The original BSDcode appears to use int here, so use that instead. Reviewed-by: Thomas Munro <thomas.munro@enterprisedb.com> https://git.postgresql.org/pg/commitdiff/0ec2e908babfbfde83a3925680f06b16408739ff - Remove BoolPtr type. Not used and doesn't seem useful. Reviewed-by: Thomas Munro <thomas.munro@enterprisedb.com> https://git.postgresql.org/pg/commitdiff/8951c65df2701a4620ea43f12b9fbabdb653c164 - Avoid use of bool in thread_test.c. It's not necessary for such a small program, and it causes unnecessary extra workto get the correct definition of bool, more so if we are going to introduce stdbool.h later. Reviewed-by: Thomas Munro<thomas.munro@enterprisedb.com> https://git.postgresql.org/pg/commitdiff/0c4b879b74f891c19b3b431c5f34f94e50daa09b - adminpack: Add test suite. Reviewed-by: David Steele <david@pgmasters.net> https://git.postgresql.org/pg/commitdiff/b28dfa6d6f4e9a7a518d3c22b28375cad8a22272 - pg_archivecleanup: Add test suite. Reviewed-by: David Steele <david@pgmasters.net> https://git.postgresql.org/pg/commitdiff/98470fdfa72b78ec49dea9a25e658876e6e51989 - passwordcheck: Add test suite. Also improve one error message. Reviewed-by: David Steele <david@pgmasters.net> https://git.postgresql.org/pg/commitdiff/af7211e92dc2bba66f90de9e5bea6ae5fa914c61 - lo: Add test suite. Reviewed-by: David Steele <david@pgmasters.net> https://git.postgresql.org/pg/commitdiff/4cb89d830626d009ed6a4482bed3a141c5039a7c - isn: Fix debug code. The ISN_DEBUG code did not compile. Fix that code, don't hide it behind an #ifdef, make it run whenbuilding with asserts, and make it error out instead of just logging if it fails. Reviewed-by: David Steele <david@pgmasters.net>https://git.postgresql.org/pg/commitdiff/9b6cb4650bc6a56114000678c1944afdb95f8333 - fuzzystrmatch: Add test suite. Reviewed-by: David Steele <david@pgmasters.net> https://git.postgresql.org/pg/commitdiff/6141123a827a47d02b8b6c8eb97643c33aa4461d - chkpass: Add test suite. Reviewed-by: David Steele <david@pgmasters.net> https://git.postgresql.org/pg/commitdiff/8423bf4f25ecd7afdd1d89adfbf29ea28992678f - Add LDAP authentication test suite. Like the SSL test suite, this will not be run by default. Reviewed-by: Thomas Munro<thomas.munro@enterprisedb.com> https://git.postgresql.org/pg/commitdiff/f0e60ee4bc04fd4865dbaf2139d50d6fe71c1bc3 - Apply pg_get_serial_sequence() to identity column sequences as well. Bug: #14813 https://git.postgresql.org/pg/commitdiff/3012061b8653a57a098c85f06f1f80ec9576711b Tom Lane pushed: - Doc: update v10 release notes through today. Add item about number of times statement-level triggers will be fired. Rearrangethe compatibility items into (what seems to me) a less random ordering. https://git.postgresql.org/pg/commitdiff/68ab9acd8557a9401a115a5369a14bf0a169e8e7 - Allow rel_is_distinct_for() to look through RelabelType below OpExpr. This lets it do the right thing for, eg, varcharcolumns. Back-patch to 9.5 where this logic appeared. David Rowley, per report from Kim Rose Carlsen Discussion:https://postgr.es/m/VI1PR05MB17091F9A9876528055D6A827C76D0@VI1PR05MB1709.eurprd05.prod.outlook.com https://git.postgresql.org/pg/commitdiff/6f44fe7f121ac7c29c1ac8553e4e209f9c3bfbcb - Fix possible dangling pointer dereference in trigger.c. AfterTriggerEndQuery correctly notes that the query_stack couldget repalloc'd during a trigger firing, but it nonetheless passes the address of a query_stack entry to afterTriggerInvokeEvents,so that if such a repalloc occurs, afterTriggerInvokeEvents is already working with an obsoletedangling pointer while it scans the rest of the events. Oops. The only code at risk is its "delete_ok" cleanupcode, so we can prevent unsafe behavior by passing delete_ok = false instead of true. However, that could have asignificant performance penalty, because the point of passing delete_ok = true is to not have to re-scan possibly a largenumber of dead trigger events on the next time through the loop. There's more than one way to skin that cat, though.What we can do is delete all the "chunks" in the event list except the last one, since we know all events in themmust be dead. Deleting the chunks is work we'd have had to do later in AfterTriggerEndQuery anyway, and it ends up savingrescanning of just about the same events we'd have gotten rid of with delete_ok = true. In v10 and HEAD, we also haveto be careful to mop up any per-table after_trig_events pointers that would become dangling. This is slightly annoying,but I don't think that normal use-cases will traverse this code path often enough for it to be a performance problem. It's pretty hard to hit this in practice because of the unlikelihood of the query_stack getting resized at justthe wrong time. Nonetheless, it's definitely a live bug of ancient standing, so back-patch to all supported branches. Discussion: https://postgr.es/m/2891.1505419542@sss.pgh.pa.us https://git.postgresql.org/pg/commitdiff/27c6619e9c8ff80cd78c7f66443aa005734cda90 - Prefer argument name over "$n" for the refname of a plpgsql argument. If a function argument has a name, use that as the"refname" of the PLpgSQL_datum representing the argument, instead of $n as before. This allows better error messagesin some cases. Pavel Stehule, reviewed by Jeevan Chalke Discussion: https://postgr.es/m/CAFj8pRB9GyU2U1Sb2ssgP26DZ_yq-FYDfpvUvGQ=k4R=yOPVjg@mail.gmail.com https://git.postgresql.org/pg/commitdiff/b8060e41b5994a3cffb3ececaab10ed39b8d5dfd - Fix RecursiveCopy.pm to cope with disappearing files. When copying from an active database tree, it's possible for filesto be deleted after we see them in a readdir() scan but before we can open them. (Once we've got a file open, we don'texpect any further errors from it getting unlinked, though.) Tweak RecursiveCopy so it can cope with this case, soas to avoid irreproducible test failures. Back-patch to 9.6 where this code was added. In v10 and HEAD, also remove unused"use RecursiveCopy" in one recovery test script. Michael Paquier and Tom Lane Discussion: https://postgr.es/m/24621.1504924323@sss.pgh.pa.us https://git.postgresql.org/pg/commitdiff/e183530550dc1b73d24fb5ae7d84e85286e88ffb - Add psql variables to track success/failure of SQL queries. This patch adds ERROR, SQLSTATE, and ROW_COUNT, which areupdated after every query, as well as LAST_ERROR_MESSAGE and LAST_ERROR_SQLSTATE, which are updated only when a queryfails. The expected usage of these is for scripting. Fabien Coelho, reviewed by Pavel Stehule Discussion: https://postgr.es/m/alpine.DEB.2.20.1704042158020.12290@lancre https://git.postgresql.org/pg/commitdiff/69835bc8988812c960f4ed5aeee86b62ac73602a - Distinguish selectivity of < from <= and > from >=. Historically, the selectivity functions have simply not distinguished< from <=, or > from >=, arguing that the fraction of the population that satisfies the "=" aspect can be consideredto be vanishingly small, if the comparison value isn't any of the most-common-values for the variable. (If itis, the code path that executes the operator against each MCV will take care of things properly.) But that isn't reallytrue unless we're dealing with a continuum of variable values, and in practice we seldom are. If "x = const" wouldestimate a nonzero number of rows for a given const value, then it follows that we ought to estimate different numbersof rows for "x < const" and "x <= const", even if the const is not one of the MCVs. Handling this more honestly makesa significant difference in edge cases, such as the estimate for a tight range (x BETWEEN y AND z where y and z areclose together). Hence, split scalarltsel into scalarltsel/scalarlesel, and similarly split scalargtsel into scalargtsel/scalargesel. Adjust <= and >= operator definitions to reference the new selectivity functions. Improve the coreineq_histogram_selectivity() function to make a correction for equality. (Along the way, I learned quite a bit aboutexactly why that function gives good answers, which I tried to memorialize in improved comments.) The correspondingjoin selectivity functions were, and remain, just stubs. But I chose to split them similarly, to avoid confusionand to prevent the need for doing this exercise again if someone ever makes them less stubby. In passing, changeineq_histogram_selectivity's clamp for extreme probability estimates so that it varies depending on the histogram size,instead of being hardwired at 0.0001. With the default histogram size of 100 entries, you still get the old clamp value,but bigger histograms should allow us to put more faith in edge values. Tom Lane, reviewed by Aleksander Alekseevand Kuntal Ghosh Discussion: https://postgr.es/m/12232.1499140410@sss.pgh.pa.us https://git.postgresql.org/pg/commitdiff/7d08ce286cd5854d58152e428c28636a616bdc42 - Update contrib/seg for new scalarlesel/scalargesel selectivity functions. I somehow missed this module in commit 7d08ce286.https://git.postgresql.org/pg/commitdiff/44ba2920644903d7dfceda810e5facdbcbab58a8 - Adjust unstable regression test case. Test queries added by commit 69835bc89 are giving unexpected results on some smallerbuildfarm critters. I think probably the seqscan logic is kicking in to cause the scans to not start at the beginningof the table. Add ORDER BY to make them be indexscans instead. Per buildfarm member chipmunk. https://git.postgresql.org/pg/commitdiff/76e134fefd7de0554536e1b8d45a1878f96cf9c0 - Avoid duplicate typedef for SharedRecordTypmodRegistry. This isn't our usual solution for such problems, and older compilers(not terribly old, either) don't like it. Per buildfarm and local testing. https://git.postgresql.org/pg/commitdiff/fba366555659fc1dc66a825196be3cc68640d289 - Don't use anonymous unions. Commit cc5f81366c36b3dd8f02bd9be1cf75b2cc8482bd introduced a language feature that is notacceptable to strict C89 compilers. Thomas Munro Per buildfarm. https://git.postgresql.org/pg/commitdiff/eaa4070543c2e36f0521f831d051265139875254 - Get rid of shared_record_typmod_registry_worker_detach; it doesn't work. This code is unsafe, as proven by buildfarm failures,because it tries to access shared memory that might already be gone. It's also unnecessary, because we're aboutto exit the process anyway and so the record type cache should never be accessed again. The idea was to lay some foundationsfor someday recycling workers --- which would require attaching to a different shared tupdesc registry --- butthat will require considerably more thought. In the meantime let's save some bytes by just removing the nonfunctionalcode. Problem identification, and proposal to fix by removing functionality from the detach function, by ThomasMunro. I went a bit further by removing the function altogether. Discussion: https://postgr.es/m/E1dsguX-00056N-9x@gemulon.postgresql.org https://git.postgresql.org/pg/commitdiff/71aa4801a8184eb422c6bf51631bda76f1011278 - Fix SQL-spec incompatibilities in new transition table feature. The standard says that all changes of the same kind (insert,update, or delete) caused in one table by a single SQL statement should be reported in a single transition table;and by that, they mean to include foreign key enforcement actions cascading from the statement's direct effects. It'salso reasonable to conclude that if the standard had wCTEs, they would say that effects of wCTEs applying to the sametable as each other or the outer statement should be merged into one transition table. We weren't doing it like that. Hence, arrange to merge tuples from multiple update actions into a single transition table as much as we can. Thereis a problem, which is that if the firing of FK enforcement triggers and after-row triggers with transition tables isinterspersed, we might need to report more tuples after some triggers have already seen the transition table. It seemslike a bad idea for the transition table to be mutable between trigger calls. There's no good way around this withouta major redesign of the FK logic, so for now, resolve it by opening a new transition table each time this happens. Also, ensure that AFTER STATEMENT triggers fire just once per statement, or once per transition table when we'reforced to make more than one. Previous versions of Postgres have allowed each FK enforcement query to cause an additionalfiring of the AFTER STATEMENT triggers for the referencing table, but that's certainly not per spec. (We're stilldoing multiple firings of BEFORE STATEMENT triggers, though; is that something worth changing?) Also, forbid using transitiontables with column-specific UPDATE triggers. The spec requires such transition tables to show only the tuplesfor which the UPDATE trigger would have fired, which means maintaining multiple transition tables or else somehow filteringthe contents at readout. Maybe someday we'll bother to support that option, but it looks like a lot of troublefor a marginal feature. The transition tables are now managed by the AfterTriggers data structures, rather than beingdirectly the responsibility of ModifyTable nodes. This removes a subtransaction-lifespan memory leak introduced bymy previous band-aid patch 3c4359521. In passing, refactor the AfterTriggers data structures to reduce the managementoverhead for them, by using arrays of structs rather than several parallel arrays for per-query-level and per-subtransactionstate. I failed to resist the temptation to do some copy-editing on the SGML docs about triggers, aboveand beyond merely documenting the effects of this patch. Back-patch to v10, because we don't want the semantics of transitiontables to change post-release. Patch by me, with help and review from Thomas Munro. Discussion: https://postgr.es/m/20170909064853.25630.12825@wrigleys.postgresql.org https://git.postgresql.org/pg/commitdiff/0f79440fb0b4c5a9baa9a95570c01828a9093802 - Doc: add example of transition table use in a trigger. I noticed that there were exactly no complete examples of use ofa transition table in a trigger function, and no clear description of just how you'd do it either. Improve that. https://git.postgresql.org/pg/commitdiff/936df5ba80a46fb40bfc93da49a709cbc0aafe5e - Fix bogus size calculation introduced by commit cc5f81366. The elements of RecordCacheArray are TupleDesc, not TupleDesc*. Those are actually the same size, so that this error is harmless, but it's still wrong --- and it might biteus someday, if TupleDesc ever became a struct, say. Per Coverity. https://git.postgresql.org/pg/commitdiff/cad22075bc2ce9c1fbe61e8d3969d4dbdb5bc1f3 - Ensure that BEFORE STATEMENT triggers fire the right number of times. Commit 0f79440fb introduced mechanism to keep AFTERSTATEMENT triggers from firing more than once per statement, which was formerly possible if more than one FK enforcementaction had to be applied to a given table. Add a similar mechanism for BEFORE STATEMENT triggers, so that wedon't have the unexpected situation of firing BEFORE STATEMENT triggers more often than AFTER STATEMENT. As with the previouspatch, back-patch to v10. Discussion: https://postgr.es/m/22315.1505584992@sss.pgh.pa.us https://git.postgresql.org/pg/commitdiff/fd31f9f033213e2ebf00b57ef837e1828c338fc4 Andres Freund pushed: - Constify numeric.c. This allows the compiler/linker to move the static variables to a read-only segment. Not all thesignature changes are necessary, but it seems better to apply const in a consistent manner. Reviewed-By: Tom Lane Discussion:https://postgr.es/m/20170910232154.asgml44ji2b7lv3d@alap3.anarazel.de https://git.postgresql.org/pg/commitdiff/c1898c3e1e235ae35b4759d233253eff221b976a - Introduce BYTES unit for GUCs. This is already useful for track_activity_query_size, and will further be used in a latercommit making the WAL segment size configurable. Author: Beena Emerson Reviewed-By: Andres Freund Discussion: https://postgr.es/m/CAOG9ApEu8bXVwBxkOO9J7ZpM76TASK_vFMEEiCEjwhMmSLiaqQ@mail.gmail.com https://git.postgresql.org/pg/commitdiff/6e7baa322773ff8c79d4d8883c99fdeff5bfa679 - Properly check interrupts in execScan.c. During the development of d47cfef711 the CFI()s in ExecScan() were moved backand forth, ending up in the wrong place. Thus queries that largely spend their time in ExecScan(), and have neither projectionnor a qual, can't be cancelled in a timely manner. Reported-By: Jeff Janes Author: Andres Freund Discussion: https://postgr.es/m/CAMkU=1weDXp8eLLPt9SO1LEUsJYYK9cScaGhLKpuN+WbYo9b5g@mail.gmail.comBackpatch: 10, as d47cfef711 https://git.postgresql.org/pg/commitdiff/1ab973ab600dc4295dbbd38d1643f9bd26f81d8e - Perform only one ReadControlFile() during startup. Previously we read the control file in multiple places. But soon thesegment size will be configurable and stored in the control file, and that needs to be available earlier than it currentlyis needed. Instead of adding yet another place where it's read, refactor things so there's a single processingof the control file during startup (in EXEC_BACKEND that's every individual backend's startup). Author: AndresFreund Discussion: http://postgr.es/m/20170913092828.aozd3gvvmw67gmyc@alap3.anarazel.de https://git.postgresql.org/pg/commitdiff/8356753c212a5865469c9befc4cf1e637a9d8bbc - Remove TupleDesc remapping logic from tqueue.c. With the introduction of a shared memory record typmod registry, it isno longer necessary to remap record typmods when sending tuples between backends so most of tqueue.c can be removed. Author:Thomas Munro Reviewed-By: Andres Freund Discussion: https://postgr.es/m/CAEepm=0ZtQ-SpsgCyzzYpsXS6e=kZWqk3g5Ygn3MDV7A8dabUA@mail.gmail.com https://git.postgresql.org/pg/commitdiff/6b65a7fe62e129d5c2b85cd74d6a91d8f7564608 - Add support for coordinating record typmods among parallel workers. Tuples can have type RECORDOID and a typmod numberthat identifies a blessed TupleDesc in a backend-private cache. To support the sharing of such tuples through sharedmemory and temporary files, provide a typmod registry in shared memory. To achieve that, introduce per-session DSMsegments, created on demand when a backend first runs a parallel query. The per-session DSM segment has a table-of-contentsjust like the per-query DSM segment, and initially the contents are a shared record typmod registry anda DSA area to provide the space it needs to grow. State relating to the current session is accessed via a Session objectreached through global variable CurrentSession that may require significant redesign further down the road as we figureout what else needs to be shared or remodelled. Author: Thomas Munro Reviewed-By: Andres Freund Discussion: https://postgr.es/m/CAEepm=0ZtQ-SpsgCyzzYpsXS6e=kZWqk3g5Ygn3MDV7A8dabUA@mail.gmail.com https://git.postgresql.org/pg/commitdiff/cc5f81366c36b3dd8f02bd9be1cf75b2cc8482bd Bruce Momjian pushed: - PG 10 release notes: update PL/Tcl functions item. Update attribution of PL/Tcl functions item from Jim Nasby to KarlLehenbauer. Reported-by: Jim Nasby Discussion: https://postgr.es/m/ed42f3d6-4251-dabc-747f-1ff936763b2b@nasby.net Backpatch-through:10 https://git.postgresql.org/pg/commitdiff/3126433ae7464ffc25a8317110e79defaa3d8865 - PG 10 release notes: change trigger transition tables. Add attribution of trigger transition tables for Thomas Munro. Reported-by: Thomas Munro Discussion: https://postgr.es/m/CAEepm=2bDFgr4ut+1-QjKQY4MA=5ek8Ap3nyB19y2tpTL6xxtA@mail.gmail.comBackpatch-through: 10 https://git.postgresql.org/pg/commitdiff/57e1c007939447ecf8c2d2aa2f507124613324ad - docs: improve pg_upgrade rsync instructions. This explains how rsync accomplishes updating standby servers and clarifiesthe instructions. Reported-by: Andreas Joseph Krogh Discussion: https://postgr.es/m/VisenaEmail.10.2b4049e43870bd16.15d898d696f@tc7-visenaBackpatch-through: 9.5 https://git.postgresql.org/pg/commitdiff/2d4a614e1ec34a746aca43d6a02aa3344dcf5fd4 - docs: improve pg_upgrade standby instructions. This makes it clear that pg_upgrade standby upgrade instructions shouldonly be used in link mode, adds examples, and explains how rsync works with links. Reported-by: Andreas Joseph KroghDiscussion: https://postgr.es/m/VisenaEmail.6c.c0e592c5af4ef0a2.15e785dcb61@tc7-visena Backpatch-through: 9.5 https://git.postgresql.org/pg/commitdiff/9521ce4a7a1125385fb4de9689f345db594c516a - docs: adjust "link mode" mention in pg_upgrade streaming steps. Backpatch-through: 9.5 https://git.postgresql.org/pg/commitdiff/82e367ddbfdf798ea8a30da15db3984017277342 - docs: clarify pg_upgrade docs regarding standbys and rsync. Document that rsync is an _optional_ way to upgrade standbys,suggest rsync option --dry-run, and mention a way of upgrading one standby from another using rsync. Also clarifysome instructions by specifying if they operate on the old or new clusters. Reported-by: Stephen Frost, Magnus HaganderDiscussion: https://postgr.es/m/20170914191250.GB6595@momjian.us Backpatch-through: 9.5 https://git.postgresql.org/pg/commitdiff/04b64b8ddf9926950fe86d7d489825c46665dc01 Michael Meskes pushed: - Fixed ECPG to correctly handle out-of-scope cursor declarations with pointers. or array variables. https://git.postgresql.org/pg/commitdiff/35e15688269a2af13f4cddff0c13536a9a42115d Stephen Frost pushed: - Fix ordering in pg_dump of GRANTs. The order in which GRANTs are output is important as GRANTs which have been GRANT'dby individuals via WITH GRANT OPTION GRANTs have to come after the GRANT which included the WITH GRANT OPTION. Thishappens naturally in the backend during normal operation as we only change existing ACLs in-place, only add new ACLsto the end, and when removing an ACL we remove any which depend on it also. Also, adjust the comments in acl.h to makethis clear. Unfortunately, the updates to pg_dump to handle initial privileges involved pulling apart ACLs and thencombining them back together and could end up putting them back together in an invalid order, leading to dumps whichwouldn't restore. Fix this by adjusting the queries used by pg_dump to ensure that the ACLs are rebuilt in the sameorder in which they were originally. Back-patch to 9.6 where the changes for initial privileges were done. https://git.postgresql.org/pg/commitdiff/d2e40b310aea1050fd499f62f391329f2c331f6a Robert Haas pushed: - Set partitioned_rels appropriately when UNION ALL is used. In most cases, this omission won't matter, because the appropriatelocks will have been acquired during parse/plan or by AcquireExecutorLocks. But it's a bug all the same. Reportby Ashutosh Bapat. Patch by me, reviewed by Amit Langote. Discussion: http://postgr.es/m/CAFjFpRdHb_ZnoDTuBXqrudWXh3H1ibLkr6nHsCFT96fSK4DXtA@mail.gmail.com https://git.postgresql.org/pg/commitdiff/1555566d9ee1a996a28cc4601840a67831112695 - Fix inconsistent capitalization. Amit Langote Discussion: http://postgr.es/m/a83a0899-19f5-594c-9aac-3ba0f16989a1@lab.ntt.co.jp https://git.postgresql.org/pg/commitdiff/42651bdd68a123544d5bfd0773a170aa3b443f1b - Make RelationGetPartitionDispatchInfo expand depth-first. With this change, the order of leaf partitions as returned byRelationGetPartitionDispatchInfo should now be the same as the order used by expand_inherited_rtentry. This will makeit simpler for future patches to match up the partition dispatch information with the planner data structures. The newcode is also, in my opinion anyway, simpler and easier to understand. Amit Langote, reviewed by Amit Khandekar. I alsoreviewed and made a few cosmetic revisions. Discussion: http://postgr.es/m/d98d4761-5071-1762-501e-0e15047c714b@lab.ntt.co.jp https://git.postgresql.org/pg/commitdiff/77b6b5e9ceca04dbd6f0f6cd3fc881519acc8714 - Add missing tags to GetCommandLogLevel. Otherwise, log_statement = 'ddl' causes errors if those statement types are used. Michael Paquier, reviewed by Ashutosh Sharma Discussion: http://postgr.es/m/CAB7nPqStC3HkE76Q1MnHsVd1vF1Td9zXApzYadzDMyLMRkkGrw@mail.gmail.com https://git.postgresql.org/pg/commitdiff/81276fdd3931d286e62b86b2512a517de2ba2de8 - Test coverage for CREATE/ALTER FOREIGN DATA WRAPPER .. HANDLER. Amit Langote, per a suggestion from Mark Dilger. Reviewedby Marc Dilger and Ashutosh Bapat. Discussion: http://postgr.es/m/CAFjFpReL0oeN7SCpnsEPbqJhB2Bp1wnH1uvbOF_w6KEuv6ZXvg@mail.gmail.com https://git.postgresql.org/pg/commitdiff/60cd2f8a2d1a1e763b2df015e2e660caa9e39a67 - After a MINVALUE/MAXVALUE bound, allow only more of the same. In the old syntax, which used UNBOUNDED, we had a similarrestriction, but commit d363d42bb9a4399a0207bd3b371c966e22e06bd3, which changed the syntax, eliminated it. Put itback. Patch by me, reviewed by Dean Rasheed. Discussion: http://postgr.es/m/CA+Tgmobs+pLPC27tS3gOpEAxAffHrq5w509cvkwTf9pF6cWYbg@mail.gmail.com https://git.postgresql.org/pg/commitdiff/9361f6f54e3ff9bab84e80d4b1e15be79b48d60e - Expand partitioned table RTEs level by level, without flattening. Flattening the partitioning hierarchy at this stagemakes various desirable optimizations difficult. The original use case for this patch was partition-wise join, whichwants to match up the partitions in one partitioning hierarchy with those in another such hierarchy. However, it nowseems that it will also be useful in making partition pruning work using the PartitionDesc rather than constraint exclusion,because with a flattened expansion, we have no easy way to figure out which PartitionDescs apply to which leaftables in a multi-level partition hierarchy. As it turns out, we end up creating both rte->inh and !rte->inh RTEs foreach intermediate partitioned table, just as we previously did for the root table. This seems unnecessary since the partitionedtables have no storage and are not scanned. We might want to go back and rejigger things so that no partitionedtables (including the parent) need !rte->inh RTEs, but that seems to require some adjustments not related to thecore purpose of this patch. Ashutosh Bapat, reviewed by me and by Amit Langote. Some final adjustments by me. Discussion:http://postgr.es/m/CAFjFpRd=1venqLL7oGU=C1dEkuvk2DJgvF+7uKbnPHaum1mvHQ@mail.gmail.com https://git.postgresql.org/pg/commitdiff/0a480502b092195a9b25a2f0f199a21d592a9c57 Álvaro Herrera pushed: - src/test/ldap: Fix test function in Linux port. https://git.postgresql.org/pg/commitdiff/c29145f00df2aa873672ab9f1b3fc4ec6a0ec05d == Pending Patches == Yuto Hayamizu sent in a patch to mitigate the fact that filter cost is estimated to be too high. Etsuro Fujita sent in another revision of a patch to add support for tuple routing to foreign partitions. Fabien COELHO sent in two more revisions of a patch to pgbench which fixes meta command only scripts. Konstantin Knizhnik sent in two more revisions of a patch to implement autoprepare. Nathan Bossart sent in four more revisions of a patch to allow VACUUM to take multiple tables and error out on duplicate columns in ANALYZE calls. Michael Banck sent in two more revisions of a patch to add an option to create a replication slot in pg_basebackup if not yet present. Andrey Borodin sent in two more revisions of a patch to allow GiST opcalsses without (de)compression functions. Peter Geoghegan sent in another revision of a patch to remove replacement selection sort from the code. Amit Kapila sent in a patch to change metapage usage for hash and b-tree indexes. Michaël Paquier sent in a patch to remove wal_keep_segments as the default configuration in PostgresNode.pm. Tom Lane sent in another revision of a patch to improve OR conditions on joined columns. Tom Lane sent in another revision of a patch to fix an infelicity between eval_const_expressions and ScalarArrayOpExpr. Ildus Kurbangaliev sent in another revision of a patch to add custom compression methods. Yura Sokolov sent in another revision of a patch to improve compactify_tuples by implementing a bucket sort with one pass of stable prefix sort on high 8 bits of offset and insertion sort for buckets larger than 1 element, and simplify PageRepairFragmentation. Simon Riggs sent in another revision of a patch to add toast_tuple_target(). Tomas Vondra sent in another revision of a patch to implement multivariate histograms and multivariate MCV lists. Haribabu Kommi sent in two more revisions of a patch to implement a pg_stat_wal_write statistics view. Elvis Pranskevichus sent in a patch to add a session_read_only GUC. Fabien COELHO sent in a patch to fix a pgbench regression test failure. Thomas Munro sent in another revision of a patch to support huge pages on Windows. Kyotaro HORIGUCHI sent in two more revisions of a patch to fix wal_level_minimal. Pavel Stěhule sent in another revision of a patch to enable PL/pgsql functions to take composite types as arguments. Hadi Moshayedi sent in a patch to call RelationDropStorage() for broader range of object drops. Jing Wang sent in two more revisions of a patch to support to COMMENT ON DATABASE CURRENT_DATABASE. Thomas Munro sent in another revision of a patch to allow custom search filters to be configured for LDAP auth, add LDAP authentication test suite, and add tests for ldapsearchfilter functionality. Jeevan Ladhe and Amit Langote traded patches to optimize default partition scanning while adding new partition. Ashutosh Bapat sent in a patch to ensure that the correct range table entry is being used in the planner for joins between declaratively partitioned tables. Amit Langote sent in four more revisions of a patch to set pd_lower correctly in the GIN metapage, BRIN metapage, and SP-GiST metapage. Tom Lane sent in another revision of a patch to enable making arrays of domains. Amit Langote sent in another revision of a patch to add some enhancments for \d+ output of partitioned tables. Pavel Stěhule sent in another revision of a patch to add some new optional checks to PL/pgsql. Vaishnavi Prabakaran sent in another revision of a patch to add batch/pipelining support to libpq. Kyotaro HORIGUCHI sent in two more revisions of a patch to enable restricting maximum keep segments by replication slots. Victor Drobny sent in another revision of a patch to add queryto_tsquery(). Thomas Munro sent in a patch to define LDAP_NO_ATTRS if necessary. Peter Moser sent in another revision of a patch to add temporal processing primitives. David Steele sent in another revision of a patch to refactor OpenFile() permissions. Adrian Escoms sent in two revisions of a patch to fix some inconsistencies between pg_settings and postgresql.conf. Pierre Ducroquet sent in another revision of a patch to allow a pg_basebackup when a tablespace is shared between two versions. Andres Freund and Beena Emerson traded patches to allow setting the default WAL segment size at initdb time. Pierre Ducroquet sent in another revision of a patch to port most calls of atoi(optarg) to strcol. Kyotaro HORIGUCHI sent in another revision of a patch to fix a race between SELECT and ALTER TABLE NO INHERIT. Amit Khandekar sent in two more revisions of a patch to implement hash partitioning. Amul Sul sent in another revision of a patch to set the ctid.ip_blkid to InvalidBlockNumber while moving a tuple to the another partition. Thomas Munro sent in two more revisions of a patch to improve the LDAP cleanup code in error paths and log diagnostic messages if errors occur during LDAP auth. Ashutosh Bapat sent in a patch to reparamterize partial nestloop paths in response to a bug report. Mark Rofail sent in another revision of a patch to implement foreign key arrays. Peter Eisentraut and Masahiko Sawada traded patches to fix an issue where DROP SUBSCRIPTION hangs if sub is disabled in the same transaction. Amit Kapila sent in another revision of a patch to make parallel paths include tlist cost. Amit Kapila sent in another revision of a patch to ensure that GatherMerge pushes target list. Andres Freund sent in a patch to improve catcache/syscache performance. Andres Freund sent in a patch to fix a binary search bottleneck in fmgr_isbuiltin() by replacing it with a hash table. Amit Langote sent in a patch to move some of the partitioning code to the executor. Alexey Chernyshov sent in another revision of a patch to add citext_pattern_ops to the citext contrib module. Thomas Munro sent in another revision of a patch to implement parallel hash. Amit Langote sent in a patch to teach ATExecAttachPartition to skip validation in more cases. Alexander Korotkov sent in two more revisions of a patch to implement 64-bit XIDs. Haribabu Kommi sent in another revision of a patch to add the infrastructure for pluggable storage by changing the Create Access method to include storage handler, adding storage AM API hooks and related functions, addadding a storageam handler to the relation structure, adding a tuple visibility function, slot hooks, a tuple insert API and scan functions to the storage AM, and moving HeapScanDesc usage outside the heap. Amul Sul sent in two more revisions of a patch to add hash partitioning. Konstantin Knizhnik sent in three more revisions of a patch to add projection autotuning. Andres Freund sent in two revisions of a patch to speed up pgstat_report_activity by moving multibyte-aware truncation to the read side. Andres Freund sent in a patch to fix an issue where SendRowDescriptionMessage() was slow for queries with a lot of columns by adding more efficient functions to pqformat API, improving the performance of SendRowDescriptionMessage, adding an inline murmurhash32(int32) function, replacing the binary search in fmgr_isbuiltin with hashtable, adding a pg_noinline macro to c.h, improving sys/catcache performance, and improving the getBaseTypeAndTypemod() performance for builtin types. Alexander Korotkov sent in two more revisions of a patch to implement incremental sort. Ashutosh Bapat sent in two more revisions of a patch to implement partition-wise join for join between (declaratively) partitioned tables. Peter Eisentraut sent in a patch to use stdbool.h instead of rolling our own. Jeff Janes sent in a patch to fix issues around superuser as it pertains to foreign tables. Amit Kapila sent in another revision of a patch to parallelize queries containing initplans. Ivan Kartyshov sent in another revision of a patch to deal with long-running transactions on subscriber nodes. Amit Langote sent in a patch to add some optimizer data structures for partitioned rels, make some planner-side changes for partition-pruning, make some interface changes for partition_bound_{cmp/bsearch}, implement get_partitions_for_keys(), and add more tests for the new partitioning-related planning code. Dmitry Dolgov sent in another revision of a patch to implement generic type subscripting. Thomas Munro sent in a patch to add coverage tests for partition-wise join for join between (declaratively) partitioned tables. Chen Huajun sent in a patch to make pg_rewind to not copy useless WAL files. Nikita Glukhov sent in another revision of a patch to add the SQL standard SQL/JSON feature. David Rowley sent in a patch to fix join removal in subqueries. Peter Geoghegan sent in a patch to allow ICU to use SortSupport on Windows with UTF-8. Andres Freund sent in a patch to fix an issue which manifested on crash and restart. Dilip Kumar sent in another revision of a patch to improve bitmap_cost. Andreas Karlsson sent in another revision of a patch to support GnuTLS for SSL. Rosser Schwarz sent in another revision of a patch to add --if-exists to pg_recvlogical. Amit Kapila sent in a patch to fix worker startup failures. Dilip Kumar sent in another revision of a patch to improve bitmap costing for lossy pages. -- Sent via pgsql-announce mailing list (pgsql-announce@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-announce
В списке pgsql-announce по дате отправления:
Предыдущее
От: Willy RichardsonДата:
Сообщение: [ANNOUNCE] Brimbox 2.3.4 Released (Postgres/PHP Web App)
Следующее
От: Alexey BorzovДата:
Сообщение: [ANNOUNCE] Introducing pg_builder and pg_wrapper packages for PHP