Re: [HACKERS] PostgreSQL not setting OpenSSL session id context?

2017-07-31 Thread Shay Rojansky
Hi Tom and Heikki. As Tom says, session caching and session tickets seem to be two separate things. However, I think you may be reading more into the session ticket feature than there is - AFAICT there is no expectation or mechanism for restoring *application* state of any kind - the mechanism is

Re: [HACKERS] Freeze on Cygwin w/ concurrency

2017-07-31 Thread Noah Misch
On Mon, Mar 20, 2017 at 11:47:03PM -0400, Noah Misch wrote: > "pgbench -i -s 50; pgbench -S -j2 -c16 -T900 -P5" freezes consistently on > Cygwin 2.2.1 and Cygwin 2.6.0. (I suspect most other versions are affected.) > I've pinged[1] the Cygwin bug thread with some additional detail. The problem

Re: [HACKERS] segfault in HEAD when too many nested functions call

2017-07-31 Thread Noah Misch
On Fri, Jul 28, 2017 at 02:42:06PM -0400, Robert Haas wrote: > On Fri, Jul 28, 2017 at 12:29 PM, Noah Misch wrote: > > Your colleagues achieve compliance despite uncertainty; for inspiration, I > > recommend examining Alvaro's status updates as examples of this. The policy > >

[HACKERS] Improve the performance of the standby server when dropping tables on the primary server

2017-07-31 Thread Tokuda, Takashi
Hi, The attached patch changes data structure storing unowned SMgrRelation objects from list structure to hash structure. The reason why I change it is that list structure very slowly removes a node. And list structure takes longer time to remove a node than hash structure. The problem was

Re: [HACKERS] [BUGS] BUG #14759: insert into foreign data partitions fail

2017-07-31 Thread Amit Langote
On 2017/08/01 12:45, Etsuro Fujita wrote: > On 2017/08/01 10:18, Amit Langote wrote: >> Good points; fixed in the updated patch. > > I should have mentioned this in an earlier mail, but one thing I noticed > is this: > > -the remote server. > +the remote server. That becomes especially

Re: [HACKERS] Update comments in nodeModifyTable.c

2017-07-31 Thread Etsuro Fujita
On 2017/08/01 1:03, Robert Haas wrote: On Fri, Jul 28, 2017 at 8:12 AM, Etsuro Fujita wrote: On 2017/07/26 22:39, Robert Haas wrote: So the first part of the change weakens the assertion that a 'ctid' or 'wholerow' attribute will always be present by saying that

Re: [HACKERS] Partitioning vs ON CONFLICT

2017-07-31 Thread Amit Langote
On 2017/08/01 10:52, Robert Haas wrote: > On Mon, Apr 3, 2017 at 6:28 AM, Amit Langote > wrote: >> Since nowhere has the user asked to ensure unique(b) across partitions by >> defining the same on parent, this seems just fine. But one question to >> ask may be

[HACKERS] Re: [BUGS] BUG #14758: Segfault with logical replication on a function index

2017-07-31 Thread Noah Misch
On Mon, Jul 31, 2017 at 09:40:34AM +0900, Masahiko Sawada wrote: > On Sat, Jul 29, 2017 at 4:35 AM, Scott Milliken wrote: > > Thank you Masahiko! I've tested and confirmed that this patch fixes the > > problem. > > > > Thank you for the testing. This issue should be added to

Re: [HACKERS] Subscription code improvements

2017-07-31 Thread Noah Misch
On Fri, Jul 07, 2017 at 10:19:19PM +0200, Petr Jelinek wrote: > I have done some review of subscription handling (well self-review) and > here is the result of that (It's slightly improved version from another > thread [1]). > Only the 0002, 0004 and 0005 are actual bug fixes, but I'd still like

Re: [HACKERS] [BUGS] BUG #14759: insert into foreign data partitions fail

2017-07-31 Thread Etsuro Fujita
On 2017/08/01 10:18, Amit Langote wrote: Good points; fixed in the updated patch. I should have mentioned this in an earlier mail, but one thing I noticed is this: -the remote server. +the remote server. That becomes especially important if the table is +being used in a

Re: [HACKERS] A bug in mapping attributes in ATExecAttachPartition()

2017-07-31 Thread Amit Langote
Thanks for taking a look at this. On 2017/08/01 6:26, Robert Haas wrote: > On Wed, Jul 26, 2017 at 9:50 PM, Amit Langote > wrote: >> At least patch 0001 does address a bug. Not sure if we can say that 0002 >> addresses a bug; it implements a feature that might be

Re: [HACKERS] Update description of \d[S+] in \?

2017-07-31 Thread David G. Johnston
On Mon, Jul 31, 2017 at 7:06 PM, Robert Haas wrote: > On Thu, Jul 13, 2017 at 8:40 PM, Amit Langote > wrote: > > On 2017/07/13 19:57, Ashutosh Bapat wrote: > >> On Thu, Jul 13, 2017 at 12:01 PM, Amit Langote > >>

Re: [HACKERS] PL_stashcache, or, what's our minimum Perl version?

2017-07-31 Thread Tom Lane
Peter Eisentraut writes: > On 7/31/17 16:54, Tom Lane wrote: >> Maybe "which" isn't the best tool for the job, not sure. > Yeah, "which" is not portable. This would need a bit more work and > portability testing. Fair enough. This late in beta is probably not

Re: [HACKERS] [PATCH v3] pg_progress() SQL function to monitor progression of long running SQL queries/utilities

2017-07-31 Thread Robert Haas
On Mon, Jul 31, 2017 at 6:10 AM, Pavel Stehule wrote: > you can support XML, JSON output format like EXPLAIN does. > > https://www.postgresql.org/docs/current/static/sql-explain.html +1 for that approach. -- Robert Haas EnterpriseDB: http://www.enterprisedb.com The

Re: [HACKERS] Update description of \d[S+] in \?

2017-07-31 Thread Robert Haas
On Thu, Jul 13, 2017 at 8:40 PM, Amit Langote wrote: > On 2017/07/13 19:57, Ashutosh Bapat wrote: >> On Thu, Jul 13, 2017 at 12:01 PM, Amit Langote >> wrote: >>> The description of \d[S+] currently does not mention that it will list

Re: [HACKERS] Parallel Hash take II

2017-07-31 Thread Robert Haas
On Mon, Jul 31, 2017 at 9:11 PM, Andres Freund wrote: > - Echoing concerns from other threads (Robert: ping): I'm doubtful that > it makes sense to size the number of parallel workers solely based on > the parallel scan node's size. I don't think it's this patch's job to

Re: [HACKERS] Partitioning vs ON CONFLICT

2017-07-31 Thread Robert Haas
On Mon, Apr 3, 2017 at 6:28 AM, Amit Langote wrote: > Since nowhere has the user asked to ensure unique(b) across partitions by > defining the same on parent, this seems just fine. But one question to > ask may be whether that will *always* be the case? That is,

Re: [HACKERS] Constraint exclusion for partitioned tables

2017-07-31 Thread Robert Haas
On Thu, Apr 6, 2017 at 6:47 AM, Ashutosh Bapat wrote: > I am guessing that for normal inheritance, a constraint on parent > doesn't necessarily imply the same constraint on the child (Amit > Langote gives me an example of NOT NULL constraint). CHECK constraints

Re: [HACKERS] [BUGS] BUG #14759: insert into foreign data partitions fail

2017-07-31 Thread Amit Langote
On 2017/08/01 10:10, David G. Johnston wrote: > On Mon, Jul 31, 2017 at 5:42 PM, Amit Langote > wrote: > >> >> On a second thought though, I think we should list the foreign table >> partitions' limitations in only one place, that is, the CREATE FOREIGN >> TABLE

[HACKERS] Re: [BUGS] BUG #14758: Segfault with logical replication on a function index

2017-07-31 Thread Andres Freund
On 2017-07-31 09:40:34 +0900, Masahiko Sawada wrote: > Moved to -hackers. > > On Sat, Jul 29, 2017 at 4:35 AM, Scott Milliken wrote: > > Thank you Masahiko! I've tested and confirmed that this patch fixes the > > problem. > > > > Thank you for the testing. This issue should

Re: [HACKERS] Parallel Hash take II

2017-07-31 Thread Andres Freund
From: Thomas Munro Date: Wed 26 Jul 2017 19:58:20 NZST Subject: [PATCH] Add support for parallel-aware hash joins. Hi, WRT the main patch: - Echoing concerns from other threads (Robert: ping): I'm doubtful that it makes sense to size the number of parallel

Re: [HACKERS] [BUGS] BUG #14759: insert into foreign data partitions fail

2017-07-31 Thread David G. Johnston
On Mon, Jul 31, 2017 at 5:42 PM, Amit Langote wrote: > > On a second thought though, I think we should list the foreign table > partitions' limitations in only one place, that is, the CREATE FOREIGN > TABLE reference page. Listing them under 5.10.2.3. seems a bit

Re: [HACKERS] PL_stashcache, or, what's our minimum Perl version?

2017-07-31 Thread Peter Eisentraut
On 7/31/17 16:54, Tom Lane wrote: > Maybe "which" isn't the best tool for the job, not sure. Yeah, "which" is not portable. This would need a bit more work and portability testing. -- Peter Eisentraut http://www.2ndQuadrant.com/ PostgreSQL Development, 24x7 Support, Remote DBA,

Re: [HACKERS] AlterUserStmt anmd RoleSpec rules in grammar.y

2017-07-31 Thread Peter Eisentraut
On 7/26/17 11:29, Tom Lane wrote: > You'll notice that that statement fails in the regression tests: > > ALTER USER ALL SET application_name to 'SLAP'; > ERROR: syntax error at or near "ALL" > > The one that works is > > ALTER ROLE ALL SET application_name to 'SLAP'; > > and the reason is

Re: [HACKERS] [BUGS] BUG #14759: insert into foreign data partitions fail

2017-07-31 Thread Amit Langote
On 2017/08/01 6:41, David G. Johnston wrote: > On Tue, Jul 25, 2017 at 11:29 PM, Amit Langote < > langote_amit...@lab.ntt.co.jp> wrote: > >>> I'm curious what the other limitations are... >> >> When I first wrote that documentation line (I am assuming you're asking >> about "although these have

Re: [HACKERS] Fix a typo in pg_upgrade/info.c

2017-07-31 Thread Masahiko Sawada
On Tue, Aug 1, 2017 at 6:23 AM, Peter Eisentraut wrote: > On 7/13/17 03:22, Masahiko Sawada wrote: >> Hi, >> >> Attached patch for $subject. >> >> s/reporing/reporting/g > > fixed Thank you! Regards, -- Masahiko Sawada NIPPON TELEGRAPH AND TELEPHONE

Re: [HACKERS] PL_stashcache, or, what's our minimum Perl version?

2017-07-31 Thread Tom Lane
I wrote: > If we need to fix things so that AC_PATH_PROG will honor a non-path > input value, then let's do that. But let's not make the build system > shakier/less reproducible than it is already. > I suggest that we could inject logic like this: > if

Re: [HACKERS] 10 beta docs: different replication solutions

2017-07-31 Thread Steve Singer
On Mon, 31 Jul 2017, Merlin Moncure wrote: On Sun, Jul 30, 2017 at 8:34 PM, Steve Singer wrote: We don't seem to describe logical replication on https://www.postgresql.org/docs/10/static/different-replication-solutions.html The attached patch adds a section. This is a

Re: [HACKERS] Parallel Hash take II

2017-07-31 Thread Thomas Munro
On Tue, Aug 1, 2017 at 9:28 AM, Andres Freund wrote: > On 2017-07-26 20:12:56 +1200, Thomas Munro wrote: >> 2. Simplified costing. There is now just one control knob >> "parallel_synchronization_cost", which I charge for each time the >> participants will wait for each other

Re: [HACKERS] PostgreSQL 10 (latest beta) and older ICU

2017-07-31 Thread Peter Eisentraut
On 7/25/17 15:20, Victor Wagner wrote: > It turns out, that PostgreSQL enumerates collations for all ICU locales > and passes it into uloc_toLanguageTag function with strict argument of > this function set to TRUE. But for some locales > (es*@collation=tradtiional, si*@collation=dictionary) only

[HACKERS] Re: [PATCH] Pattern based listeners for asynchronous messaging (LISTEN/NOTIFY)

2017-07-31 Thread Chapman Flack
On 07/31/17 16:30, Peter Eisentraut wrote: > I would think about specifying an operator somewhere in the syntax, like > you have with LISTEN SIMILAR TO. It would even be nice if a > non-built-in operator could be used for matching names. Hmm ... as I was reading through the email thread, I saw

Re: [HACKERS] Incorrect comment of XLByteToSeg() and XLByteToPrevSeg()

2017-07-31 Thread Tatsuo Ishii
> Thanks for the patch. Looks good to me. I will commit/push into all > supported branches if there's no objection. Done. Best regards, -- Tatsuo Ishii SRA OSS, Inc. Japan English: http://www.sraoss.co.jp/index_en.php Japanese:http://www.sraoss.co.jp -- Sent via pgsql-hackers mailing list

Re: [HACKERS] PL_stashcache, or, what's our minimum Perl version?

2017-07-31 Thread Tom Lane
I wrote: > Done. I have also reconfigured buildfarm member prairiedog to use > a non-MULTIPLICITY build of Perl 5.8.3, with the oldest Test::More > and IPC::Run versions I could lay my hands on. Although I'd gotten > through a manual "make check-world" with this configuration in HEAD > before

Re: [HACKERS] pg_dump does not handle indirectly-granted permissions properly

2017-07-31 Thread Stephen Frost
Tom, * Tom Lane (t...@sss.pgh.pa.us) wrote: > Stephen Frost writes: > > * Tom Lane (t...@sss.pgh.pa.us) wrote: > >> AFAICT, pg_dump has no notion that it needs to be careful about the order > >> in which permissions are granted. I did > > > I'm afraid that's correct, though

Re: LP_DEAD hinting and not holding on to a buffer pin on leaf page (Was: [HACKERS] [WIP] Zipfian distribution in pgbench)

2017-07-31 Thread Peter Geoghegan
Robert Haas wrote: On Mon, Jul 31, 2017 at 1:54 PM, Peter Geoghegan wrote: That is hard to justify. I don't think that failing to set LP_DEAD hints is the cost that must be paid to realize a benefit elsewhere, though. I don't see much problem with having

Re: [HACKERS] [BUGS] BUG #14759: insert into foreign data partitions fail

2017-07-31 Thread David G. Johnston
On Tue, Jul 25, 2017 at 11:29 PM, Amit Langote < langote_amit...@lab.ntt.co.jp> wrote: > > I'm curious what the other limitations are... > > When I first wrote that documentation line (I am assuming you're asking > about "although these have some limitations that normal tables do not"), I > was

Re: [HACKERS] building libpq.a static library

2017-07-31 Thread Tom Lane
Peter Eisentraut writes: > On 7/12/17 11:11, Tom Lane wrote: >> FWIW, we used to have support for building static libpq, but >> we got rid of it a long time ago. I couldn't find the exact >> spot in some desultory trawling of the commit history. > We still

Re: [HACKERS] Parallel Hash take II

2017-07-31 Thread Andres Freund
Hi, On 2017-07-26 20:12:56 +1200, Thomas Munro wrote: > Here is a new version of my parallel-aware hash join patchset. Yay! Working on reviewing this. Will send separate emails for individual patch reviews. > 2. Simplified costing. There is now just one control knob >

Re: [HACKERS] building libpq.a static library

2017-07-31 Thread Peter Eisentraut
On 7/12/17 11:11, Tom Lane wrote: > FWIW, we used to have support for building static libpq, but > we got rid of it a long time ago. I couldn't find the exact > spot in some desultory trawling of the commit history. We still build and install static libraries. -- Peter Eisentraut

Re: [HACKERS] PostgreSQL not setting OpenSSL session id context?

2017-07-31 Thread Tom Lane
Heikki Linnakangas writes: > I agree with Tom that we don't really want abbreviated SSL handshakes, > or other similar optimizations, to take place. PostgreSQL connections > are quite long-lived, so we have little to gain. But it makes the attack > surface larger. There have

Re: [HACKERS] A bug in mapping attributes in ATExecAttachPartition()

2017-07-31 Thread Robert Haas
On Wed, Jul 26, 2017 at 9:50 PM, Amit Langote wrote: > At least patch 0001 does address a bug. Not sure if we can say that 0002 > addresses a bug; it implements a feature that might be a > nice-to-have-in-PG-10. I think 0001 is actually several fixes that should

Re: [HACKERS] Fix a typo in pg_upgrade/info.c

2017-07-31 Thread Peter Eisentraut
On 7/13/17 03:22, Masahiko Sawada wrote: > Hi, > > Attached patch for $subject. > > s/reporing/reporting/g fixed -- Peter Eisentraut http://www.2ndQuadrant.com/ PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services -- Sent via pgsql-hackers mailing list

Re: [HACKERS] Another comment typo in execMain.c

2017-07-31 Thread Peter Eisentraut
On 7/6/17 03:23, Etsuro Fujita wrote: > Here is a comment in ExecFindPartition() in execMain.c: > > /* > * First check the root table's partition constraint, if any. No > point in > * routing the tuple it if it doesn't belong in the root table itself. > */ > > I think

Re: [HACKERS] POC: Sharing record typmods between backends

2017-07-31 Thread Andres Freund
Hi, diff --git a/src/backend/access/common/tupdesc.c b/src/backend/access/common/tupdesc.c index 9fd7b4e019b..97c0125a4ba 100644 --- a/src/backend/access/common/tupdesc.c +++ b/src/backend/access/common/tupdesc.c @@ -337,17 +337,75 @@ DecrTupleDescRefCount(TupleDesc tupdesc) {

Re: [HACKERS] Inconsistencies in from_char_parse_int_len()

2017-07-31 Thread Tom Lane
Douglas Doole writes: > I was playing with TO_TIMESTAMP() and I noticed a weird result: > postgres=# select to_timestamp('20170-07-24 21:59:57.12345678', '-mm-dd > hh24:mi:ss.us'); > to_timestamp > > 20170-07-24

Re: [HACKERS] PL_stashcache, or, what's our minimum Perl version?

2017-07-31 Thread Tom Lane
Peter Eisentraut writes: > On 7/31/17 15:38, Tom Lane wrote: >> Really? That seems pretty broken, independently of how many variables >> are affected. But the ones you'd be most likely to do that with are >> using AC_PATH_PROG already, I think. Having

Re: [HACKERS] PG 10 release notes

2017-07-31 Thread Thomas Munro
On Tue, Apr 25, 2017 at 1:31 PM, Bruce Momjian wrote: > I have committed the first draft of the Postgres 10 release notes. They > are current as of two days ago, and I will keep them current. Please > give me any feedback you have. Hi Bruce, "Add AFTER trigger transition

[HACKERS] Inconsistencies in from_char_parse_int_len()

2017-07-31 Thread Douglas Doole
I was playing with TO_TIMESTAMP() and I noticed a weird result: postgres=# select to_timestamp('20170-07-24 21:59:57.12345678', '-mm-dd hh24:mi:ss.us'); to_timestamp 20170-07-24 22:00:09.345678+00 (1 row) Even though the "us" token is supposed to

Re: [HACKERS] [PATCH] Pattern based listeners for asynchronous messaging (LISTEN/NOTIFY)

2017-07-31 Thread Peter Eisentraut
On 7/31/17 16:13, Markus Sintonen wrote: > This patch has no know backward compatibility issues with the existing > /LISTEN///UNLISTEN/ features. This is because patch extends the existing > syntax by accepting quoted strings which define the patterns as opposed > to the existing SQL literals. I

Re: [HACKERS] PL_stashcache, or, what's our minimum Perl version?

2017-07-31 Thread Peter Eisentraut
On 7/31/17 15:38, Tom Lane wrote: > Peter Eisentraut writes: >> One major PITA with the AC_PATH_* checks is that you can only override >> them with environment variables that are full paths; otherwise the >> environment variables are ignored. For example,

[HACKERS] [PATCH] Pattern based listeners for asynchronous messaging (LISTEN/NOTIFY)

2017-07-31 Thread Markus Sintonen
Hi This patch adds an ability to use patterns in *LISTEN* commands. Patch uses '*SIMILAR TO*' patterns for matching *NOTIFY* channel names ( https://www.postgresql.org/docs/9.0/static/functions-matching.html#FUNCTIONS-SIMILARTO-REGEXP ). This patch is related to old discussion in

Re: [HACKERS] PostgreSQL - Weak DH group

2017-07-31 Thread Heikki Linnakangas
On 07/31/2017 02:27 PM, Heikki Linnakangas wrote: Rebased patch attached, with proposed release notes included. Barring new objections or arguments, I'll commit this (only) to v10 later today. Ok, committed for v10. Thanks Nicolas and Damien, and everyone else involved! - Heikki -- Sent

Re: [HACKERS] PL_stashcache, or, what's our minimum Perl version?

2017-07-31 Thread Peter Eisentraut
On 7/31/17 15:17, Peter Eisentraut wrote: > On 7/31/17 14:55, Tom Lane wrote: >>> We use the "PATH" variants when we need a fully qualified name. For >>> example, at some point or another, we needed to substitute a fully >>> qualified perl binary name into the headers of scripts. >> >>> If there

Re: [HACKERS] PL_stashcache, or, what's our minimum Perl version?

2017-07-31 Thread Tom Lane
Peter Eisentraut writes: > One major PITA with the AC_PATH_* checks is that you can only override > them with environment variables that are full paths; otherwise the > environment variables are ignored. For example, currently, running > ./configure

Re: [HACKERS] PL_stashcache, or, what's our minimum Perl version?

2017-07-31 Thread Peter Eisentraut
On 7/31/17 14:55, Tom Lane wrote: >> We use the "PATH" variants when we need a fully qualified name. For >> example, at some point or another, we needed to substitute a fully >> qualified perl binary name into the headers of scripts. > >> If there is no such requirement, then we should use the

Re: [HACKERS] pg_stop_backup(wait_for_archive := true) on standby server

2017-07-31 Thread Stephen Frost
* Robert Haas (robertmh...@gmail.com) wrote: > On Thu, Jul 27, 2017 at 10:27 AM, Stephen Frost wrote: > > * Noah Misch (n...@leadboat.com) wrote: > >> This PostgreSQL 10 open item is past due for your status update. Kindly > >> send > >> a status update within 24 hours, and

Re: [HACKERS] pg_stop_backup(wait_for_archive := true) on standby server

2017-07-31 Thread Robert Haas
On Thu, Jul 27, 2017 at 10:27 AM, Stephen Frost wrote: > * Noah Misch (n...@leadboat.com) wrote: >> This PostgreSQL 10 open item is past due for your status update. Kindly send >> a status update within 24 hours, and include a date for your subsequent >> status >> update.

Re: [HACKERS] PL_stashcache, or, what's our minimum Perl version?

2017-07-31 Thread Tom Lane
Peter Eisentraut writes: > On 7/30/17 12:50, Tom Lane wrote: >> The reason it does that seems to be that we use AC_CHECK_PROGS >> rather than AC_PATH_PROGS for locating "prove". I can see no >> particular consistency to the decisions made in configure.in >>

Re: LP_DEAD hinting and not holding on to a buffer pin on leaf page (Was: [HACKERS] [WIP] Zipfian distribution in pgbench)

2017-07-31 Thread Robert Haas
On Mon, Jul 31, 2017 at 1:54 PM, Peter Geoghegan wrote: > That is hard to justify. I don't think that failing to set LP_DEAD hints > is the cost that must be paid to realize a benefit elsewhere, though. I > don't see much problem with having both benefits consistently. It's >

Re: [HACKERS] PL_stashcache, or, what's our minimum Perl version?

2017-07-31 Thread Peter Eisentraut
On 7/30/17 12:50, Tom Lane wrote: > Noah Misch writes: >> On Sun, Jul 30, 2017 at 12:05:10PM -0400, Tom Lane wrote: >>> Well, OK, but I'd still like to tweak configure so that it records >>> an absolute path for prove rather than just setting PROVE=prove. >>> That way you'd at

Re: [HACKERS] Transactions involving multiple postgres foreign servers

2017-07-31 Thread Robert Haas
On Mon, Jul 31, 2017 at 1:27 PM, Alvaro Herrera wrote: > Postgres-XL seems to manage this problem by using a transaction manager > node, which is in charge of assigning snapshots. I don't know how that > works, but perhaps adding that concept here could be useful too.

Re: LP_DEAD hinting and not holding on to a buffer pin on leaf page (Was: [HACKERS] [WIP] Zipfian distribution in pgbench)

2017-07-31 Thread Peter Geoghegan
Robert Haas wrote: On Thu, Jul 27, 2017 at 10:05 PM, Peter Geoghegan wrote: I really don't know if that would be worthwhile. It would certainly fix the regression shown in my test case, but that might not go far enough. I strongly suspect that there are

Re: [HACKERS] PL_stashcache, or, what's our minimum Perl version?

2017-07-31 Thread Tom Lane
Noah Misch writes: > On Sun, Jul 30, 2017 at 01:21:28AM -0400, Tom Lane wrote: >> Anyway, pending some news about compatibility of the MSVC scripts, >> I think we ought to adjust our docs to state that 5.8.3 is the >> minimum supported Perl version. > Works for me. Done. I

Re: LP_DEAD hinting and not holding on to a buffer pin on leaf page (Was: [HACKERS] [WIP] Zipfian distribution in pgbench)

2017-07-31 Thread Robert Haas
On Thu, Jul 27, 2017 at 10:05 PM, Peter Geoghegan wrote: > I really don't know if that would be worthwhile. It would certainly fix > the regression shown in my test case, but that might not go far enough. > I strongly suspect that there are more complicated workloads where > LP_DEAD

Re: [HACKERS] Transactions involving multiple postgres foreign servers

2017-07-31 Thread Alvaro Herrera
Robert Haas wrote: > An alternative approach is to have some kind of other identifier, > let's call it a distributed transaction ID (DXID) which is mapped by > each node onto a local XID. Postgres-XL seems to manage this problem by using a transaction manager node, which is in charge of

Re: [HACKERS] GSoC 2017: Foreign Key Arrays

2017-07-31 Thread Mark Rofail
On Mon, Jul 31, 2017 at 5:18 PM, Alvaro Herrera wrote: > Tom Lane wrote: > > Alvaro Herrera writes: > > > ... However, when you create an index, you can > > > indicate which operator class to use, and it may not be the default > one. > > > If

Re: [HACKERS] Increase Vacuum ring buffer.

2017-07-31 Thread Sokolov Yura
On 2017-07-27 11:53, Sokolov Yura wrote: On 2017-07-26 20:28, Sokolov Yura wrote: On 2017-07-26 19:46, Claudio Freire wrote: On Wed, Jul 26, 2017 at 1:39 PM, Sokolov Yura wrote: On 2017-07-24 12:41, Sokolov Yura wrote: test_master_1/pretty.log ... time

Re: [HACKERS] Transactions involving multiple postgres foreign servers

2017-07-31 Thread Robert Haas
On Fri, Jul 28, 2017 at 10:14 AM, Michael Paquier wrote: > On Fri, Jul 28, 2017 at 7:28 AM, Masahiko Sawada > wrote: >> That also requires to share the same XID space with all remote nodes. > > You are putting your finger on the main bottleneck

Re: [HACKERS] pl/perl extension fails on Windows

2017-07-31 Thread Christoph Berg
Re: Tom Lane 2017-07-31 <30582.1501508...@sss.pgh.pa.us> > Christoph Berg writes: > >>> The only interesting line in log/postmaster.log is a log_line_prefix-less > >>> Util.c: loadable library and perl binaries are mismatched (got handshake > >>> key 0xd500080, needed 0xd600080)

Re: [HACKERS] Transactions involving multiple postgres foreign servers

2017-07-31 Thread Robert Haas
On Thu, Jul 27, 2017 at 8:25 AM, Ashutosh Bapat wrote: > The remote transaction can be committed/aborted only after the fate of > the local transaction is decided. If we commit remote transaction and > abort local transaction, that's not good. AtEOXact* functions

Re: [HACKERS] Clarification in pg10's pgupgrade.html step 10 (upgrading standby servers)

2017-07-31 Thread Robert Haas
On Fri, Jul 28, 2017 at 10:35 AM, Andreas Joseph Krogh wrote: > I'm reading https://www.postgresql.org/docs/10/static/pgupgrade.html to try > to understand how to upgrade standby-servers using pg_upgrade with pg10. > > The text in step 10 sais: > "You will not be running

[HACKERS] [GOSC' 17][Performance report] Eliminate O(N^2) scaling from rw-conflict tracking in serializable transactions

2017-07-31 Thread Mengxing Liu
Hi, all. I wrote a performance report to conclude what I've done so far. https://docs.google.com/document/d/16A6rfJnQSTkd0SHK-2XzDiLj7aZ5nC189jGPcfVdhMQ/edit?usp=sharing Three patch are attached. I used the benchmark below to test the performance. https://github.com/liumx10/pg-bench It requires

Re: [HACKERS] Update comments in nodeModifyTable.c

2017-07-31 Thread Robert Haas
On Fri, Jul 28, 2017 at 8:12 AM, Etsuro Fujita wrote: > On 2017/07/26 22:39, Robert Haas wrote: >> So the first part of the change weakens the assertion that a 'ctid' or >> 'wholerow' attribute will always be present by saying that an FDW may >> instead have other

Re: [HACKERS] Persistent wait event sets and socket changes

2017-07-31 Thread Andres Freund
Hi Craig, On 2017-07-31 14:08:58 +0800, Craig Ringer wrote: > Hi all > > I've been looking into the wait event set interface added in 9.6 with an > eye to using it in an extension that maintains a set of non-blocking libpq > connections to other PostgreSQL instances. > > In the process I've

Re: [HACKERS] GSoC 2017: Foreign Key Arrays

2017-07-31 Thread Alvaro Herrera
Tom Lane wrote: > Alvaro Herrera writes: > > ... However, when you create an index, you can > > indicate which operator class to use, and it may not be the default one. > > If a different one is chosen at index creation time, then a query using > > COUNT(distinct) will

Re: [HACKERS] pl/perl extension fails on Windows

2017-07-31 Thread Tom Lane
Christoph Berg writes: >>> The only interesting line in log/postmaster.log is a log_line_prefix-less >>> Util.c: loadable library and perl binaries are mismatched (got handshake >>> key 0xd500080, needed 0xd600080) Can we see the Perl-related output from configure, particularly

Re: [HACKERS] 10 beta docs: different replication solutions

2017-07-31 Thread Merlin Moncure
On Sun, Jul 30, 2017 at 8:34 PM, Steve Singer wrote: > > We don't seem to describe logical replication on > > https://www.postgresql.org/docs/10/static/different-replication-solutions.html > > The attached patch adds a section. This is a good catch. Two quick observations:

Re: [HACKERS] [PROPOSAL] Temporal query processing with range types

2017-07-31 Thread Peter Moser
On 06.04.2017 01:24, Andres Freund wrote: Unfortunately I don't think this patch has received sufficient design and implementation to consider merging it into v10. As code freeze is in two days, I think we'll have to move this to the next commitfest. We rebased our patch on top of commit

Re: [HACKERS] Default Partition for Range

2017-07-31 Thread Beena Emerson
On Wed, Jul 26, 2017 at 7:05 PM, Jeevan Ladhe wrote: > Hi Beena, > > I have posted the rebased patches[1] for default list partition. > Your patch also needs a rebase. > > [1] >

Re: [HACKERS] Partition-wise join for join between (declaratively) partitioned tables

2017-07-31 Thread Ashutosh Bapat
On Mon, Jul 31, 2017 at 8:32 AM, Robert Haas wrote: > On Fri, Jul 14, 2017 at 3:02 AM, Ashutosh Bapat > wrote: >> Here's revised patch set with only 0004 revised. That patch deals with >> creating multi-level inheritance hierarchy from

Re: [HACKERS] PostgreSQL not setting OpenSSL session id context?

2017-07-31 Thread Heikki Linnakangas
On 07/31/2017 02:24 AM, Shay Rojansky wrote: Just to continue the above, I can confirm that adding a simple call to SSL_CTX_set_session_id_context() to be_tls_init() with some arbitrary const value fixes the error for me. Attached is a patch (ideally a test should be done for this, but that's

[HACKERS] Minor comment update in partition.c

2017-07-31 Thread Beena Emerson
The commit d363d42bb9a4399a0207bd3b371c966e22e06bd3 changed RangeDatumContent *content to PartitionRangeDatumKind *kind but a comment on function partition_rbound_cmp was left unedited and it still mentions content1 instead of kind1. PFA the patch to fix this. -- Beena Emerson EnterpriseDB:

Re: [HACKERS] PostgreSQL - Weak DH group

2017-07-31 Thread Heikki Linnakangas
On 07/13/2017 11:07 PM, Heikki Linnakangas wrote: On 07/13/2017 10:13 PM, Robert Haas wrote: On Thu, Jul 13, 2017 at 1:30 PM, Tom Lane wrote: Heikki Linnakangas writes: I don't think this can be backpatched. It changes the default DH parameters from 1024

Re: [HACKERS] [PATCH v3] pg_progress() SQL function to monitor progression of long running SQL queries/utilities

2017-07-31 Thread Pavel Stehule
2017-07-31 11:09 GMT+02:00 Remi Colinet : > > > 2017-07-26 15:27 GMT+02:00 Robert Haas : > >> On Wed, Jun 21, 2017 at 10:01 AM, Remi Colinet >> wrote: >> > test=# SELECT pid, ppid, bid, concat(repeat(' ', 3 * indent),name),

Re: [HACKERS] map_partition_varattnos() and whole-row vars

2017-07-31 Thread Amit Langote
Thanks a lot Amit for looking at this and providing some useful pointers. On 2017/07/28 20:46, Amit Khandekar wrote: > On 28 July 2017 at 11:17, Amit Langote wrote: >> On 2017/07/26 16:58, Amit Langote wrote: >>> Rajkumar Raghuwanshi reported [1] on the "UPDATE

Re: [HACKERS] asynchronous execution

2017-07-31 Thread Kyotaro HORIGUCHI
At Fri, 28 Jul 2017 17:31:05 +0900 (Tokyo Standard Time), Kyotaro HORIGUCHI wrote in <20170728.173105.238045591.horiguchi.kyot...@lab.ntt.co.jp> > Thank you for the comment. > > At Wed, 26 Jul 2017 17:16:43 -0400, Robert Haas wrote > in

Re: [HACKERS] [PATCH v3] pg_progress() SQL function to monitor progression of long running SQL queries/utilities

2017-07-31 Thread Remi Colinet
2017-07-26 16:24 GMT+02:00 Pavel Stehule : > > > 2017-07-26 15:27 GMT+02:00 Robert Haas : > >> On Wed, Jun 21, 2017 at 10:01 AM, Remi Colinet >> wrote: >> > test=# SELECT pid, ppid, bid, concat(repeat(' ', 3 *

Re: [HACKERS] [PATCH v3] pg_progress() SQL function to monitor progression of long running SQL queries/utilities

2017-07-31 Thread Remi Colinet
2017-07-26 15:27 GMT+02:00 Robert Haas : > On Wed, Jun 21, 2017 at 10:01 AM, Remi Colinet > wrote: > > test=# SELECT pid, ppid, bid, concat(repeat(' ', 3 * indent),name), > value, > > unit FROM pg_progress(0,0); > > pid | ppid | bid |

Re: [HACKERS] pl/perl extension fails on Windows

2017-07-31 Thread Christoph Berg
Re: Ashutosh Sharma 2017-07-31 > > The only interesting line in log/postmaster.log is a log_line_prefix-less > > Util.c: loadable library and perl binaries are mismatched (got handshake > > key 0xd500080, needed 0xd600080) > >

Re: [HACKERS] Adding support for Default partition in partitioning

2017-07-31 Thread Ashutosh Bapat
On Sun, Jul 30, 2017 at 8:07 AM, Jeevan Ladhe wrote: > Hi Ashutosh, > > 0003 patch >> >> +parentRel = heap_open(parentOid, AccessExclusiveLock); >> In [2], Amit Langote has given a reason as to why heap_drop_with_catalog() >> should not heap_open() the

Re: [HACKERS] pl/perl extension fails on Windows

2017-07-31 Thread Ashutosh Sharma
Hi Christoph, On Mon, Jul 31, 2017 at 9:18 AM, Ashutosh Sharma wrote: > Hi Christoph, > > On Mon, Jul 31, 2017 at 2:44 AM, Christoph Berg wrote: >> Re: Tom Lane 2017-07-28 <3254.1501276...@sss.pgh.pa.us> >>> Christoph Berg writes: >>> >

[HACKERS] Persistent wait event sets and socket changes

2017-07-31 Thread Craig Ringer
Hi all I've been looking into the wait event set interface added in 9.6 with an eye to using it in an extension that maintains a set of non-blocking libpq connections to other PostgreSQL instances. In the process I've been surprised to find that there does not appear to be any interface to