Re: [HACKERS] Postgres code for a query intermediate dataset

2014-09-14 Thread Mark Kirkwood
On 14/09/14 20:43, Mark Kirkwood wrote: On 14/09/14 20:24, Atri Sharma wrote: How do you plan to do all that VACUUM does for this table then? It seems to me that you are saying to VACUUM that it need not be concerned with table 'A' and you are assuming ownership of all the tasks performed by

Re: [HACKERS] orangutan seizes up during isolation-check

2014-09-14 Thread Noah Misch
On Tue, Sep 02, 2014 at 12:25:39AM -0400, Tom Lane wrote: > Noah Misch writes: > > Buildfarm member orangutan has failed chronically on both of the branches > > for > > which it still reports, HEAD and REL9_1_STABLE, for over two years. The > > postmaster appears to jam during isolation-check.

Re: [HACKERS] [REVIEW] Re: Compression of full-page-writes

2014-09-14 Thread Craig Ringer
On 09/14/2014 09:27 AM, k...@rice.edu wrote: > Thank you for running this sample benchmark. It definitely shows that the > hardware version of the CRC is very fast, unfortunately it is really only > available on x64 Intel/AMD processors which leaves all the rest lacking. We're talking about someth

Re: [HACKERS] Obsolete comment within execTuples.c

2014-09-14 Thread Peter Geoghegan
On Sun, Sep 14, 2014 at 9:05 PM, Tom Lane wrote: > More generally, though, it seems like the header comments in execTuples.c > are not the best place to document global behavior ... Yeah, my thoughts exactly. -- Peter Geoghegan -- Sent via pgsql-hackers mailing list (pgsql-hackers@postgresq

Re: [HACKERS] Obsolete comment within execTuples.c

2014-09-14 Thread Tom Lane
Peter Geoghegan writes: > Header comments within execTuples.c state: > * - ExecutePlan() calls ExecSelect(), which passes the result slot > * to printtup(), which uses slot_getallattrs() to extract the > * individual Datums for printing. > This isn't true, though - the function ExecSelect()

[HACKERS] Obsolete comment within execTuples.c

2014-09-14 Thread Peter Geoghegan
Header comments within execTuples.c state: * - ExecutePlan() calls ExecSelect(), which passes the result slot * to printtup(), which uses slot_getallattrs() to extract the * individual Datums for printing. This isn't true, though - the function ExecSelect() no longer exists. This is because

Re: [HACKERS] pgbench throttling latency limit

2014-09-14 Thread Robert Haas
On Sat, Sep 13, 2014 at 4:25 AM, Fabien COELHO wrote: >> [about logging...] > > Here is an attempt at updating the log features, including the aggregate and > sampling stuff, with skipped transactions under throttling. > > I moved the logging stuff into a function which is called when a transactio

Re: BRIN indexes (was Re: [HACKERS] Minmax indexes)

2014-09-14 Thread Emanuel Calvo
El 08/09/14 13:02, Alvaro Herrera escribió: > Here's version 18. I have renamed it: These are now BRIN indexes. > > I have fixed numerous race conditions and deadlocks. In particular I > fixed this problem you noted: > > Heikki Linnakangas wrote: >> Another race condition: >> >> If a new tuple i

Re: [HACKERS] [REVIEW] Re: Compression of full-page-writes

2014-09-14 Thread Arthur Silva
Em 14/09/2014 12:21, "Andres Freund" escreveu: > > On 2014-09-13 20:27:51 -0500, k...@rice.edu wrote: > > > > > > What we are looking for here is uniqueness thus better error detection. Not > > > avalanche effect, nor cryptographically secure, nor bit distribution. > > > As far as I'm aware CRC32C

Re: [HACKERS] Sequence Access Method WIP

2014-09-14 Thread Petr Jelinek
On 18/11/13 11:50, Heikki Linnakangas wrote: I don't think the sequence AM should be in control of 'cached'. The caching is done outside the AM. And log_cnt probably should be passed to the _alloc function directly as an argument, ie. the server code asks the AM to allocate N new values in one c

Re: [HACKERS] SKIP LOCKED DATA (work in progress)

2014-09-14 Thread Thomas Munro
On 12 September 2014 03:56, Alvaro Herrera wrote: > Thomas Munro wrote: >> But to reach the case you mentioned, it would need to get past that >> (xmax is not a valid transaction) but then the tuple would need to be >> locked by another session before heap_lock_tuple is called a few lines >> below

Re: [HACKERS] Turning off HOT/Cleanup sometimes

2014-09-14 Thread Simon Riggs
On 12 September 2014 18:19, Simon Riggs wrote: > On 12 September 2014 15:30, Tom Lane wrote: >> After a little bit I remembered there was already a function for this. >> So specifically, I'd suggest using ExecRelationIsTargetRelation() >> to decide whether to mark the scan as requiring pruning.

Re: [HACKERS] B-Tree support function number 3 (strxfrm() optimization)

2014-09-14 Thread Peter Geoghegan
On Sun, Sep 14, 2014 at 7:37 AM, Heikki Linnakangas wrote: > Got to be careful to not let the compiler optimize away microbenchmarks like > this. At least with my version of gcc, the strcoll calls get optimized away, > as do the memcmp calls, if you don't use the result for anything. Clang was > e

Re: [HACKERS] KNN-GiST with recheck

2014-09-14 Thread Alexander Korotkov
On Sun, Sep 14, 2014 at 10:09 PM, Emre Hasegeli wrote: > I added the point to polygon distance operator patch to the open > CommitFest as ready for committer and added myself as reviewer to > both of the patches. > Thanks. > Cost estimation of GiST is a big problem anyway. It doesn't care (and

Re: [HACKERS] proposal: plpgsql - Assert statement

2014-09-14 Thread Jan Wieck
On 09/14/2014 02:25 PM, Pavel Stehule wrote: a) Isn't possible handle a assertion exception anywhere .. it enforce ROLLBACK in 100% b) Assertions should be disabled globally .. I am not sure, it it is a good idea, but I can understand so some tests based on queries to data can be performance iss

Re: [HACKERS] proposal: plpgsql - Assert statement

2014-09-14 Thread Pavel Stehule
2014-09-09 7:54 GMT+02:00 Craig Ringer : > On 09/05/2014 05:21 PM, Pavel Stehule wrote: > > > > *shrug* Doing it in SQL would probably break more stuff. I'm trying to > > contain the damage. And arguably, this is mostly only useful in > PL/PgSQL. > > I've wanted assertions in SQL enough that I

Re: [HACKERS] KNN-GiST with recheck

2014-09-14 Thread Emre Hasegeli
I added the point to polygon distance operator patch to the open CommitFest as ready for committer and added myself as reviewer to both of the patches. > I think that for most use cases just some operators require further sorting > and some of them not. But it could appear one day that some index

Re: [HACKERS] [REVIEW] Re: Compression of full-page-writes

2014-09-14 Thread k...@rice.edu
On Sun, Sep 14, 2014 at 05:21:10PM +0200, Andres Freund wrote: > On 2014-09-13 20:27:51 -0500, k...@rice.edu wrote: > > > Also, while I understand that CRC has a very venerable history and > > is well studied for transmission type errors, I have been unable to find > > any research on its applicab

Re: [HACKERS] Aussie timezone database changes incoming

2014-09-14 Thread Tom Lane
Martijn van Oosterhout writes: > On Thu, Sep 11, 2014 at 03:42:14PM +1000, Andrew McNamara wrote: >> Quite likely this change will break stuff, but my feeling is more people >> will be cheering than screaming. > Indeed, this has been a pain in the ass for a long long time. It's good news that pe

Re: [HACKERS] alter user set local_preload_libraries.

2014-09-14 Thread Tom Lane
Peter Eisentraut writes: > On 9/1/14 7:51 AM, Kyotaro HORIGUCHI wrote: >> The attached patch simply changes the context for local_... to >> PGC_USERSET and edits the doc. > I had this ready to commit, but then > Invent PGC_SU_BACKEND and mark log_connections/log_disconnections > that way. >

Re: [HACKERS] documentation update for doc/src/sgml/func.sgml

2014-09-14 Thread Peter Eisentraut
On 9/12/14 3:13 PM, Andreas 'ads' Scherbaum wrote: > Of course a general rule how to link to WP would be nice ... I think Wikipedia links should be avoided altogether. We can assume that readers are technically proficient to look up general technical concepts on their own using a reference system

Re: [HACKERS] [REVIEW] Re: Compression of full-page-writes

2014-09-14 Thread Andres Freund
On 2014-09-13 20:27:51 -0500, k...@rice.edu wrote: > > > > What we are looking for here is uniqueness thus better error detection. Not > > avalanche effect, nor cryptographically secure, nor bit distribution. > > As far as I'm aware CRC32C is unbeaten collision wise and time proven. > > > > I cou

Re: [HACKERS] alter user set local_preload_libraries.

2014-09-14 Thread Peter Eisentraut
On 9/1/14 7:51 AM, Kyotaro HORIGUCHI wrote: > The attached patch simply changes the context for local_... to > PGC_USERSET and edits the doc. I had this ready to commit, but then Invent PGC_SU_BACKEND and mark log_connections/log_disconnections that way. was committed in the meantime. Does

Re: [HACKERS] B-Tree support function number 3 (strxfrm() optimization)

2014-09-14 Thread Heikki Linnakangas
On 09/13/2014 11:28 PM, Peter Geoghegan wrote: Anyway, attached rough test program implements what you outline. This is for 30,000 32 byte strings (where just the final two bytes differ). On my laptop, output looks like this (edited to only show median duration in each case): Got to be careful

Re: [HACKERS] Aussie timezone database changes incoming

2014-09-14 Thread Martijn van Oosterhout
On Thu, Sep 11, 2014 at 03:42:14PM +1000, Andrew McNamara wrote: > >Anyone from down under care to remark about the actual usage of old > >and new abbreviations? About bloody time! > > AEST/AEDT/etc are the official abbreviations and are commonly used. > They have been increasingly used over the

Re: [HACKERS] Postgres code for a query intermediate dataset

2014-09-14 Thread Mark Kirkwood
On 14/09/14 21:18, Rohit Goyal wrote: Hi Mark & Atri, :) Thanks for reply. But, I think i confused you. I am talking about access using indexes. So, I assume that B+ tree store key-value pair where rohit is the key and all the versions are its value. Another way to think is I have a secondary i

Re: [HACKERS] Postgres code for a query intermediate dataset

2014-09-14 Thread Rohit Goyal
Hi Mark & Atri, :) Thanks for reply. But, I think i confused you. I am talking about access using indexes. So, I assume that B+ tree store key-value pair where rohit is the key and all the versions are its value. Another way to think is I have a secondary index on emp. name and there are 4 rohit

Re: [HACKERS] Tips/advice for implementing integrated RESTful HTTP API

2014-09-14 Thread Björn Harrtell
FYI, got an initial implementation of http://wiki.postgresql.org/wiki/HTTP_API done in Java (intended to run as a servlet) at https://github.com/bjornharrtell/jdbc-http-server. Feedback is welcome :) Regards, Björn 2014-09-03 1:19 GMT+02:00 Álvaro Hernández Tortosa : > > On 02/09/14 04:47, Dobe

Re: [HACKERS] Postgres code for a query intermediate dataset

2014-09-14 Thread Mark Kirkwood
On 14/09/14 20:11, Rohit Goyal wrote: Hi Mark, On Sun, Sep 14, 2014 at 8:57 AM, Mark Kirkwood mailto:mark.kirkw...@catalyst.net.nz>> wrote: Currently in Postgres, these intermediate versions all exist - however a given session can only see one of them. Also VACUUM is allowed to de

Re: [HACKERS] Postgres code for a query intermediate dataset

2014-09-14 Thread Mark Kirkwood
On 14/09/14 20:24, Atri Sharma wrote: On Sun, Sep 14, 2014 at 1:30 PM, Mark Kirkwood mailto:mark.kirkw...@catalyst.net.nz>> wrote: On 14/09/14 19:25, Atri Sharma wrote: On Sunday, September 14, 2014, Mark Kirkwood mailto:mark.kirkw...@catalyst.net.nz>

Re: [HACKERS] Postgres code for a query intermediate dataset

2014-09-14 Thread Atri Sharma
On Sun, Sep 14, 2014 at 1:30 PM, Mark Kirkwood < mark.kirkw...@catalyst.net.nz> wrote: > On 14/09/14 19:25, Atri Sharma wrote: > >> >> >> On Sunday, September 14, 2014, Mark Kirkwood >> mailto:mark.kirkw...@catalyst.net.nz>> >> >> wrote: >> >> On 14/09/14 05:36, Rohit Goyal wrote: >> >>

Re: [HACKERS] Postgres code for a query intermediate dataset

2014-09-14 Thread Atri Sharma
On Sun, Sep 14, 2014 at 1:30 PM, Mark Kirkwood < mark.kirkw...@catalyst.net.nz> wrote: > On 14/09/14 19:25, Atri Sharma wrote: > >> >> >> On Sunday, September 14, 2014, Mark Kirkwood >> mailto:mark.kirkw...@catalyst.net.nz>> >> >> wrote: >> >> On 14/09/14 05:36, Rohit Goyal wrote: >> >>

Re: [HACKERS] Postgres code for a query intermediate dataset

2014-09-14 Thread Rohit Goyal
Hi Mark, On Sun, Sep 14, 2014 at 8:57 AM, Mark Kirkwood < mark.kirkw...@catalyst.net.nz> wrote: > On 14/09/14 05:36, Rohit Goyal wrote: > >> Hi All, >> >> I want to work on the code of intermediate dataset of select and update >> query. >> >> For example. >> >> Rohit's salary has been updated 4 t

Re: [HACKERS] Postgres code for a query intermediate dataset

2014-09-14 Thread Mark Kirkwood
On 14/09/14 19:25, Atri Sharma wrote: On Sunday, September 14, 2014, Mark Kirkwood mailto:mark.kirkw...@catalyst.net.nz>> wrote: On 14/09/14 05:36, Rohit Goyal wrote: Hi All, I want to work on the code of intermediate dataset of select and update query.

Re: [HACKERS] run xmllint during build (was Re: need xmllint on borka)

2014-09-14 Thread Fabien COELHO
Hello Peter, I've committed the $(missing) use separately, That was simple and is a definite improvement. Tiny detail: the new DBTOEPUB macro definition in "src/Makefile.global.in" lacks another tab to be nicely aligned with the other definitions. and rebased this patch on top of that.

Re: [HACKERS] Postgres code for a query intermediate dataset

2014-09-14 Thread Atri Sharma
On Sunday, September 14, 2014, Mark Kirkwood wrote: > On 14/09/14 05:36, Rohit Goyal wrote: > >> Hi All, >> >> I want to work on the code of intermediate dataset of select and update >> query. >> >> For example. >> >> Rohit's salary has been updated 4 times, so it has 4 different version >> of sa

Re: [HACKERS] Scaling shared buffer eviction

2014-09-14 Thread Mark Kirkwood
On 14/09/14 19:00, Amit Kapila wrote: On Fri, Sep 12, 2014 at 11:09 PM, Gregory Smith mailto:gregsmithpg...@gmail.com>> wrote: > This looks like it's squashed one of the very fundamental buffer > scaling issues though; well done Amit. Thanks. > I'll go back to my notes and try to recreate

Re: [HACKERS] Scaling shared buffer eviction

2014-09-14 Thread Amit Kapila
On Fri, Sep 12, 2014 at 11:09 PM, Gregory Smith wrote: > This looks like it's squashed one of the very fundamental buffer > scaling issues though; well done Amit. Thanks. > I'll go back to my notes and try to recreate the pathological cases > that plagued both the 8.3 BGW rewrite and the abort