Re: [HACKERS] [PATCH] Negative Transition Aggregate Functions (WIP)

2014-01-25 Thread David Rowley
On Thu, Jan 23, 2014 at 1:57 PM, Florian Pflug f...@phlo.org wrote: On Jan23, 2014, at 01:17 , David Rowley dgrowle...@gmail.com wrote: On Wed, Jan 22, 2014 at 12:46 AM, Florian Pflug f...@phlo.org wrote: If you want to play with this, I think the first step has to be to find a set of

Re: [HACKERS] extension_control_path

2014-01-25 Thread Magnus Hagander
I haven't actually looked at the patch itself, but I noted this from the other review: On Fri, Jan 24, 2014 at 6:43 PM, Sergey Muraviov sergey.k.murav...@gmail.com wrote: = postgresql.conf: extension_control_path =

Re: [HACKERS] proposal: hide application_name from other users

2014-01-25 Thread Greg Stark
On Fri, Jan 24, 2014 at 6:46 AM, Magnus Hagander mag...@hagander.net wrote: What actually happens if you set the application_name in the connection string in that environment? Does it override it to it's own default? If so, the developers there clearly need to be taught about

Re: [HACKERS] proposal: hide application_name from other users

2014-01-25 Thread Magnus Hagander
On Sat, Jan 25, 2014 at 10:42 AM, Greg Stark st...@mit.edu wrote: On Fri, Jan 24, 2014 at 6:46 AM, Magnus Hagander mag...@hagander.net wrote: What actually happens if you set the application_name in the connection string in that environment? Does it override it to it's own default? If so,

Re: [HACKERS] proposal: hide application_name from other users

2014-01-25 Thread Magnus Hagander
On Fri, Jan 24, 2014 at 5:21 PM, Harold Giménez har...@heroku.com wrote: On Fri, Jan 24, 2014 at 6:46 AM, Magnus Hagander mag...@hagander.net wrote: On Thu, Jan 23, 2014 at 2:01 AM, Greg Stark st...@mit.edu wrote: On Wed, Jan 22, 2014 at 1:03 PM, Josh Berkus j...@agliodbs.com wrote:

Re: [HACKERS] [bug fix] postgres.exe fails to start on Windows Server 2012 due to ASLR

2014-01-25 Thread Craig Ringer
On 01/24/2014 06:42 PM, MauMau wrote: Hello, My customer reported the following problem on Windows. I'm afraid this is a serious problem, and I think we should provide a fix in the next minor release. I've attached a fix, and I would wish it to be back-ported. [Problem] The customer

Re: [HACKERS] pg_get_viewdefs() indentation considered harmful

2014-01-25 Thread Tom Lane
Robert Haas robertmh...@gmail.com writes: On Fri, Jan 24, 2014 at 8:53 PM, Greg Stark st...@mit.edu wrote: Indeed even aside from the performance questions, once you're indented 5-10 times the indention stops being useful at all. The query would probably be even more readable if we just made

Re: [HACKERS] [COMMITTERS] pgsql: libpq: Support TLS versions beyond TLSv1.

2014-01-25 Thread Tom Lane
Noah Misch n...@leadboat.com writes: libpq: Support TLS versions beyond TLSv1. Per report from Jeffrey Walton, libpq has been accepting only TLSv1 exactly. Along the lines of the backend code, libpq will now support new versions as OpenSSL adds them. This patch seems fishy. The commit

Re: [HACKERS] extension_control_path

2014-01-25 Thread Tom Lane
Magnus Hagander mag...@hagander.net writes: Using colon as the path separator is going to break on windows. The patch notices this and uses semicolon on Windows instead. Do we really want to go down that path - that means that everybody who writes any sorts of installation instructions

Re: [HACKERS] [PATCH] Negative Transition Aggregate Functions (WIP)

2014-01-25 Thread Tom Lane
David Rowley dgrowle...@gmail.com writes: My point was more that since sum(float) can give different results if it used an index scan rather than a seq scan, trying to get the inverse transition to match something that gives varying results sounds like a tricky task to take on. This is just a

Re: [HACKERS] [COMMITTERS] pgsql: libpq: Support TLS versions beyond TLSv1.

2014-01-25 Thread Noah Misch
On Sat, Jan 25, 2014 at 11:24:19AM -0500, Tom Lane wrote: Noah Misch n...@leadboat.com writes: libpq: Support TLS versions beyond TLSv1. Per report from Jeffrey Walton, libpq has been accepting only TLSv1 exactly. Along the lines of the backend code, libpq will now support new versions

Re: [HACKERS] extension_control_path

2014-01-25 Thread Dimitri Fontaine
Magnus Hagander mag...@hagander.net writes: Using colon as the path separator is going to break on windows. The patch notices this and uses semicolon on Windows instead. Do we really want to go down that path - that means that everybody who writes any sorts of installation instructions

Re: [HACKERS] [COMMITTERS] pgsql: libpq: Support TLS versions beyond TLSv1.

2014-01-25 Thread Tom Lane
Noah Misch n...@leadboat.com writes: On Sat, Jan 25, 2014 at 11:24:19AM -0500, Tom Lane wrote: why wasn't the backend also made to reject SSL v3? The backend allows SSLv3, TLSv1, TLSv1.1 and TLSv1.2. Before the patch, libpq allowed TLSv1 only. Since the patch, libpq allows TLSv1, TLSv1.1

Re: [HACKERS] extension_control_path

2014-01-25 Thread Magnus Hagander
On Sat, Jan 25, 2014 at 6:07 PM, Dimitri Fontaine dimi...@2ndquadrant.frwrote: Magnus Hagander mag...@hagander.net writes: Using colon as the path separator is going to break on windows. The patch notices this and uses semicolon on Windows instead. Do we really want to go down that path -

Re: [HACKERS] [COMMITTERS] pgsql: libpq: Support TLS versions beyond TLSv1.

2014-01-25 Thread Noah Misch
On Sat, Jan 25, 2014 at 12:25:30PM -0500, Tom Lane wrote: Noah Misch n...@leadboat.com writes: On Sat, Jan 25, 2014 at 11:24:19AM -0500, Tom Lane wrote: why wasn't the backend also made to reject SSL v3? The backend allows SSLv3, TLSv1, TLSv1.1 and TLSv1.2. Before the patch, libpq

Re: [HACKERS] pg_get_viewdefs() indentation considered harmful

2014-01-25 Thread Andrew Dunstan
On 01/25/2014 11:06 AM, Tom Lane wrote: Robert Haas robertmh...@gmail.com writes: On Fri, Jan 24, 2014 at 8:53 PM, Greg Stark st...@mit.edu wrote: Indeed even aside from the performance questions, once you're indented 5-10 times the indention stops being useful at all. The query would

Re: Fwd: [HACKERS] patch: make_timestamp function

2014-01-25 Thread Marko Tiikkaja
Looks good to me. Regards, Marko Tiikkaja -- Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-hackers

Re: [HACKERS] Postgresql for cygwin - 3rd

2014-01-25 Thread Andrew Dunstan
On 01/24/2014 07:50 AM, Marco Atzeri wrote: Those two issues need to be fixed. And yes, they are regressions from my Cygwin 1.7.7 setup where they pass consistently, just about every day. See http://www.pgbuildfarm.org/cgi-bin/show_history.pl?nm=brolgabr=HEAD 1.7.7 is 3.5 years hold. In

[HACKERS] Questionable coding in orderedsetaggs.c

2014-01-25 Thread Jeremy Harris
In ordered_set_startup() sorts are initialised in non-randomAccess mode (tuplesort_begin_heap() and ~datum(), last argument). The use of tuplesort_skip_tuples() feels very like a random access to me. I think it doesn't fail because the only use (and implementation) is to skip forwards; if

Re: [HACKERS] Storing pg_stat_statements query texts externally, pg_stat_statements in core

2014-01-25 Thread Tom Lane
Peter Geoghegan p...@heroku.com writes: On Wed, Jan 22, 2014 at 1:22 PM, Tom Lane t...@sss.pgh.pa.us wrote: BTW, have you got any sort of test scenario you could share for this purpose? I'm sure I could build something, but if you've already done it ... I simply ran the standard regression

Re: [HACKERS] GIN improvements part2: fast scan

2014-01-25 Thread Tomas Vondra
On 23.1.2014 17:22, Heikki Linnakangas wrote: I measured the time that query takes, and the number of pages hit, using explain (analyze, buffers true) patchestime (ms)buffers --- unpatched6501316 patch 10.521316 patches 1+20.501316

Re: [HACKERS] Questionable coding in orderedsetaggs.c

2014-01-25 Thread Tom Lane
Jeremy Harris j...@wizmail.org writes: In ordered_set_startup() sorts are initialised in non-randomAccess mode (tuplesort_begin_heap() and ~datum(), last argument). The use of tuplesort_skip_tuples() feels very like a random access to me. I think it doesn't fail because the only use (and

Re: [HACKERS] Storing pg_stat_statements query texts externally, pg_stat_statements in core

2014-01-25 Thread Peter Geoghegan
On Sat, Jan 25, 2014 at 11:04 AM, Tom Lane t...@sss.pgh.pa.us wrote: Do the regression tests fail for you when doing this? What I see is a duplicate occurrence of an escape_string_warning bleat: *** /home/postgres/pgsql/src/test/regress/expected/plpgsql.out Fri Jan 3 17:07 :46 2014 ---

Re: [HACKERS] A minor correction in comment in heaptuple.c

2014-01-25 Thread Bruce Momjian
On Tue, Jun 18, 2013 at 11:04:25AM -0700, Kevin Grittner wrote: D'Arcy J.M. Cain da...@druid.net Although, the more I think about it, the more I think that the comment is both confusing and superfluous.  The code itself is much clearer. Seriously, if there is any comment there at all, it

Re: [HACKERS] A minor correction in comment in heaptuple.c

2014-01-25 Thread Andres Freund
On 2014-01-25 16:28:09 -0500, Bruce Momjian wrote: On Tue, Jun 18, 2013 at 11:04:25AM -0700, Kevin Grittner wrote: D'Arcy J.M. Cain da...@druid.net Although, the more I think about it, the more I think that the comment is both confusing and superfluous.  The code itself is much

Re: [HACKERS] A minor correction in comment in heaptuple.c

2014-01-25 Thread Bruce Momjian
On Sat, Jan 25, 2014 at 10:29:36PM +0100, Andres Freund wrote: On 2014-01-25 16:28:09 -0500, Bruce Momjian wrote: On Tue, Jun 18, 2013 at 11:04:25AM -0700, Kevin Grittner wrote: D'Arcy J.M. Cain da...@druid.net Although, the more I think about it, the more I think that the comment

Re: [HACKERS] Memory leak in PL/pgSQL function which CREATE/SELECT/DROP a temporary table

2014-01-25 Thread Bruce Momjian
On Tue, Jun 18, 2013 at 09:07:59PM +0300, Heikki Linnakangas wrote: Hmm. I could repeat this, and it seems that the catcache for pg_statistic accumulates negative cache entries. Those slowly take up the memory. Digging a bit deeper, this is a rather common problem with negative catcache

Re: [HACKERS] A minor correction in comment in heaptuple.c

2014-01-25 Thread Andres Freund
On 2014-01-25 16:33:16 -0500, Bruce Momjian wrote: On Sat, Jan 25, 2014 at 10:29:36PM +0100, Andres Freund wrote: On 2014-01-25 16:28:09 -0500, Bruce Momjian wrote: On Tue, Jun 18, 2013 at 11:04:25AM -0700, Kevin Grittner wrote: D'Arcy J.M. Cain da...@druid.net Although, the

Re: [HACKERS] Postgresql for cygwin - 3rd

2014-01-25 Thread Marco Atzeri
On 25/01/2014 19:23, Andrew Dunstan wrote: On 01/24/2014 07:50 AM, Marco Atzeri wrote: Those two issues need to be fixed. And yes, they are regressions from my Cygwin 1.7.7 setup where they pass consistently, just about every day. See

Re: [HACKERS] A minor correction in comment in heaptuple.c

2014-01-25 Thread Bruce Momjian
On Sat, Jan 25, 2014 at 10:40:28PM +0100, Andres Freund wrote: I don't think it improves things relevantly, but it doesn't make anything worse either. So if that makes anybody happy... I think this style of pinhole copy editing is pretty pointless. There's dozen checks just like this around.

Re: [HACKERS] What is happening on buildfarm member crake?

2014-01-25 Thread Andrew Dunstan
On 01/19/2014 08:22 PM, Robert Haas wrote: Hmm, that looks an awful lot like the SIGUSR1 signal handler is getting called after we've already completed shmem_exit. And indeed that seems like the sort of thing that would result in dying horribly in just this way. The obvious fix seems to be to

Re: [HACKERS] A minor correction in comment in heaptuple.c

2014-01-25 Thread Tom Lane
Andres Freund and...@2ndquadrant.com writes: On 2014-01-25 16:28:09 -0500, Bruce Momjian wrote: Is everyone OK with me applying this patch from Kevin, attached? No. I still think this is stupid. Not at all clearer and possibly breaks stuff. I agree; this patch is flat out wrong. It converts

Re: [HACKERS] A better way than tweaking NTUP_PER_BUCKET

2014-01-25 Thread Bruce Momjian
Uh, were are we on this? Is it a TODO? --- On Wed, Jul 3, 2013 at 01:39:28PM +0530, Atri Sharma wrote: Hi all, I have been working on a patch for the above discussed functionalities. I made an array of int32s, one

Re: [HACKERS] A minor correction in comment in heaptuple.c

2014-01-25 Thread Tom Lane
Bruce Momjian br...@momjian.us writes: On Sat, Jan 25, 2014 at 10:40:28PM +0100, Andres Freund wrote: I think this style of pinhole copy editing is pretty pointless. There's dozen checks just like this around. If somebody wants to change the rules or improve comment it takes more than picking

Re: [HACKERS] A better way than tweaking NTUP_PER_BUCKET

2014-01-25 Thread Stephen Frost
* Bruce Momjian (br...@momjian.us) wrote: Uh, were are we on this? Is it a TODO? I've been strongly considering my previous patch which tweaked NTUP_PER_BUCKET to '1' (instead of the default '10') when there's sufficient work_mem for it. There was recently another complaint on IRC about our

Re: [HACKERS] [PATCH] Negative Transition Aggregate Functions (WIP)

2014-01-25 Thread Florian Pflug
On Jan25, 2014, at 09:50 , David Rowley dgrowle...@gmail.com wrote: On Thu, Jan 23, 2014 at 1:57 PM, Florian Pflug f...@phlo.org wrote: On Jan23, 2014, at 01:17 , David Rowley dgrowle...@gmail.com wrote: On Wed, Jan 22, 2014 at 12:46 AM, Florian Pflug f...@phlo.org wrote: If you want to play

Re: [HACKERS] What is happening on buildfarm member crake?

2014-01-25 Thread Tom Lane
Andrew Dunstan and...@dunslane.net writes: On 01/19/2014 08:22 PM, Robert Haas wrote: Hmm, that looks an awful lot like the SIGUSR1 signal handler is getting called after we've already completed shmem_exit. And indeed that seems like the sort of thing that would result in dying horribly in

Re: [HACKERS] Storing pg_stat_statements query texts externally, pg_stat_statements in core

2014-01-25 Thread Peter Geoghegan
On Sat, Jan 25, 2014 at 1:11 PM, Tom Lane t...@sss.pgh.pa.us wrote: I've chosen to handle failures to load query text data by just returning NULL for that query text, which seems reasonable given the new mindset that the query text is auxiliary data less important than the actual counts. I

Re: [HACKERS] Storing pg_stat_statements query texts externally, pg_stat_statements in core

2014-01-25 Thread Peter Geoghegan
Why do you think it's better to release the shared lock while generating a normalized query text, only to acquire it once more? I'm not suggesting that it's the wrong thing to do. I'm curious about the reasoning around assessing the costs. -- Peter Geoghegan -- Sent via pgsql-hackers mailing

Re: [HACKERS] A better way than tweaking NTUP_PER_BUCKET

2014-01-25 Thread Tom Lane
Stephen Frost sfr...@snowman.net writes: * Bruce Momjian (br...@momjian.us) wrote: Uh, were are we on this? Is it a TODO? I've been strongly considering my previous patch which tweaked NTUP_PER_BUCKET to '1' (instead of the default '10') when there's sufficient work_mem for it. There was

Re: [HACKERS] [COMMITTERS] pgsql: libpq: Support TLS versions beyond TLSv1.

2014-01-25 Thread Stephen Frost
* Noah Misch (n...@leadboat.com) wrote: +1. If you can upgrade to 9.4, you can also bring your TLS protocol out of the iron age. Agreed- this was going to be my 2c. Anyone w/ an SSL library that old isn't likely to be upgrading to 9.4 of libpq or PG. Thanks, Stephen

Re: [HACKERS] A minor correction in comment in heaptuple.c

2014-01-25 Thread Bruce Momjian
On Sat, Jan 25, 2014 at 04:56:37PM -0500, Tom Lane wrote: Bruce Momjian br...@momjian.us writes: On Sat, Jan 25, 2014 at 10:40:28PM +0100, Andres Freund wrote: I think this style of pinhole copy editing is pretty pointless. There's dozen checks just like this around. If somebody wants to

Re: [HACKERS] Storing pg_stat_statements query texts externally, pg_stat_statements in core

2014-01-25 Thread Tom Lane
Peter Geoghegan p...@heroku.com writes: Why do you think it's better to release the shared lock while generating a normalized query text, only to acquire it once more? I'm not suggesting that it's the wrong thing to do. I'm curious about the reasoning around assessing the costs. Well, it's

Re: [HACKERS] Changeset Extraction v7.1

2014-01-25 Thread Andres Freund
Hi Robert, all, On 2014-01-24 20:38:11 -0500, Robert Haas wrote: On Fri, Jan 24, 2014 at 12:49 PM, Andres Freund and...@2ndquadrant.com wrote: But this code is riddled with places where you track a catalog xmin and a data xmin separately. The only point of doing it that way is to

Re: [HACKERS] A better way than tweaking NTUP_PER_BUCKET

2014-01-25 Thread Stephen Frost
Tom, * Tom Lane (t...@sss.pgh.pa.us) wrote: Stephen Frost sfr...@snowman.net writes: In the end, I believe we absolutely should do something about this. Hashing a 64M-row table (requiring upwards of 8G) instead of hashing a 2M-row table is really bad of us. Huh? I don't see anything in

Re: [HACKERS] Postgresql for cygwin - 3rd

2014-01-25 Thread Marco Atzeri
On 25/01/2014 22:42, Marco Atzeri wrote: On 25/01/2014 19:23, Andrew Dunstan wrote: On 01/24/2014 07:50 AM, Marco Atzeri wrote: * LDAP libraries - the way you have proposed surely isn't right. What we want is something more like this in the Makefile.global.in: ifeq

Re: [HACKERS] A minor correction in comment in heaptuple.c

2014-01-25 Thread Andres Freund
On 2014-01-25 17:15:01 -0500, Bruce Momjian wrote: On Sat, Jan 25, 2014 at 04:56:37PM -0500, Tom Lane wrote: Bruce Momjian br...@momjian.us writes: On Sat, Jan 25, 2014 at 10:40:28PM +0100, Andres Freund wrote: I think this style of pinhole copy editing is pretty pointless. There's

Re: [HACKERS] What is happening on buildfarm member crake?

2014-01-25 Thread Andrew Dunstan
On 01/25/2014 05:04 PM, Tom Lane wrote: Andrew Dunstan and...@dunslane.net writes: On 01/19/2014 08:22 PM, Robert Haas wrote: Hmm, that looks an awful lot like the SIGUSR1 signal handler is getting called after we've already completed shmem_exit. And indeed that seems like the sort of thing

Re: [HACKERS] A better way than tweaking NTUP_PER_BUCKET

2014-01-25 Thread Simon Riggs
On 25 January 2014 22:33, Stephen Frost sfr...@snowman.net wrote: * Tom Lane (t...@sss.pgh.pa.us) wrote: AFAICT, there was no consensus in this thread on what to do, which probably has something to do with the lack of concrete performance tests presented to back up any particular proposal.

Re: [HACKERS] [PATCH] Negative Transition Aggregate Functions (WIP)

2014-01-25 Thread David Rowley
On Sat, Jan 25, 2014 at 3:21 PM, Florian Pflug f...@phlo.org wrote: On Jan24, 2014, at 08:47 , Dean Rasheed dean.a.rash...@gmail.com wrote: The invtrans_minmax patch doesn't contain any patches yet - David, could you provide some for these functions, and also for bool_and and bool_or? We

Re: [HACKERS] Storing pg_stat_statements query texts externally, pg_stat_statements in core

2014-01-25 Thread Peter Geoghegan
On Sat, Jan 25, 2014 at 2:20 PM, Tom Lane t...@sss.pgh.pa.us wrote: Well, it's fairly expensive to generate that text, in the case of a large/complex statement. It's possible that continuing to hold the lock is nonetheless the right thing to do because release+reacquire is also expensive; but

Re: [HACKERS] Visual Studio 2013 build

2014-01-25 Thread Andrew Dunstan
On 12/02/2013 05:12 PM, Brar Piening wrote: Hackers, the attached patch enables Microsoft Visual Studio 2013 as additional build environment. After some tweaking (VS now has got its own rint and a few macro definitions that were previously missing) the build runs without errors or warnings

Re: [HACKERS] [COMMITTERS] pgsql: libpq: Support TLS versions beyond TLSv1.

2014-01-25 Thread Alvaro Herrera
Stephen Frost escribió: * Noah Misch (n...@leadboat.com) wrote: +1. If you can upgrade to 9.4, you can also bring your TLS protocol out of the iron age. Agreed- this was going to be my 2c. Anyone w/ an SSL library that old isn't likely to be upgrading to 9.4 of libpq or PG. What about

Re: [HACKERS] INTERVAL overflow detection is terribly broken

2014-01-25 Thread Bruce Momjian
On Sun, Jun 23, 2013 at 03:00:59PM +0200, Rok Kralj wrote: Hi, after studying ITERVAL and having a long chat with RhoidumToad and StuckMojo on #postgresql, I am presenting you 3 bugs regarding INTERVAL. OK, I am going to merge this with the previous report/patch which fixes: SELECT

Re: [HACKERS] Questionable coding in orderedsetaggs.c

2014-01-25 Thread Atri Sharma
On Sunday, January 26, 2014, Tom Lane t...@sss.pgh.pa.us wrote: Jeremy Harris j...@wizmail.org javascript:; writes: In ordered_set_startup() sorts are initialised in non-randomAccess mode (tuplesort_begin_heap() and ~datum(), last argument). The use of tuplesort_skip_tuples() feels very

Re: [HACKERS] Freezing without write I/O

2014-01-25 Thread Peter Geoghegan
Shouldn't this patch be in the January commitfest? -- Peter Geoghegan -- Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-hackers

Re: [HACKERS] GIN improvements part2: fast scan

2014-01-25 Thread Tomas Vondra
Hi! On 25.1.2014 22:21, Heikki Linnakangas wrote: Attached is a new version of the patch set, with those bugs fixed. I've done a bunch of tests with all the 4 patches applied, and it seems to work now. I've done tests with various conditions (AND/OR, number of words, number of conditions) and I