Re: Speeding up INSERTs and UPDATEs to partitioned tables

2018-11-21 Thread David Rowley
On Sat, 17 Nov 2018 at 04:14, Alvaro Herrera wrote: > I'll now see about the commit message and push shortly. Many thanks for making the required adjustments and pushing this. If I wasn't on leave late last week and early this week then the only thing I'd have mentioned was the lack of empty com

Re: New GUC to sample log queries

2018-11-21 Thread Adrien Nayrat
On 11/19/18 2:52 PM, Dmitry Dolgov wrote: >> On Mon, Nov 19, 2018 at 2:40 PM Tomas Vondra >> wrote: >> >> On 11/19/18 2:57 AM, Michael Paquier wrote: >>> On Sun, Nov 18, 2018 at 12:18:33PM +0100, Dmitry Dolgov wrote: Since it's hard to come up with a concise name that will mention sampling

Re: pgsql: Remove WITH OIDS support, change oid catalog column visibility.

2018-11-21 Thread Christoph Berg
Re: Andres Freund 2018-11-21 > The biggest user of WITH OID columns was postgres' catalog. This > commit changes all 'magic' oid columns to be columns that are normally > declared and stored. postgres=# \d+ pg_class [...] Indexe: "pg_class_oid_index" UNIQUE, btree (oid) Now that oid is a pro

Re: pgsql: Remove WITH OIDS support, change oid catalog column visibility.

2018-11-21 Thread Gavin Flower
On 21/11/2018 21:20, Christoph Berg wrote: Re: Andres Freund 2018-11-21 The biggest user of WITH OID columns was postgres' catalog. This commit changes all 'magic' oid columns to be columns that are normally declared and stored. postgres=# \d+ pg_class [...] Indexe: "pg_class_oid_index" U

Re: pgsql: Remove WITH OIDS support, change oid catalog column visibility.

2018-11-21 Thread Christoph Berg
Re: Gavin Flower 2018-11-21 > Curious, is there a reason 'Index' is spelt with a trailing 'e'? LANG=de_DE.UTF-8 Christoph

RE: Shared Memory: How to use SYSV rather than MMAP ?

2018-11-21 Thread REIX, Tony
Hi Thomas, Andres, I still have to reread/study in depth the discussion in this thread in order to understand all these information. However, we've already got a very good performance improvement of pgbench on AIX 7.2 / Power9 with that change: + ~38% in best case. See below for the details.

RE: libpq debug log

2018-11-21 Thread Iwata, Aya
Hi Hari san, Thank you for your comment! And sorry my late reply… >I have some comments related to the trace output that is getting >printed. The amount of log it is generating may not be understood >to many of the application developers. IMO, this should print >only the necessary information tha

RE: libpq debug log

2018-11-21 Thread Iwata, Aya
Hi Jacob san, Thank you for your comment! And sorry for late reply... > Couple additional thoughts from a read-through of the patch: > > - PQtrace() and the new trace-logging machinery overlap in some places but > not others -- and if both are set, PQtrace() will take precedence. > It seems lik

Re: pgsql: Remove WITH OIDS support, change oid catalog column visibility.

2018-11-21 Thread Peter Eisentraut
On 21/11/2018 09:20, Christoph Berg wrote: > Re: Andres Freund 2018-11-21 >> The biggest user of WITH OID columns was postgres' catalog. This >> commit changes all 'magic' oid columns to be columns that are normally >> declared and stored. > > postgres=# \d+ pg_class > [...] > Indexe: > "pg_c

Re: Continue work on changes to recovery.conf API

2018-11-21 Thread Peter Eisentraut
On 21/11/2018 07:00, Michael Paquier wrote: > What's bad in keeping standby_mode and just rely on recovery.signal to > enforce recovery to happen? When the startup process starts all the > parameters should be loaded. That would also need less work from users > to switch to the new APIs. I think

Re: Online verification of checksums

2018-11-21 Thread Michael Banck
Hi, On Tue, Oct 30, 2018 at 06:22:52PM +0100, Fabien COELHO wrote: > >I am not convinced we need to differentiate further between online and > >offline operation, can you explain in more detail which other > >differences are ok in online mode and why? > > For instance the "file/directory was remo

Re: Removing unneeded self joins

2018-11-21 Thread Alexander Kuzmenkov
El 08/11/18 a las 08:59, David Rowley escribió: On 19 October 2018 at 01:47, Alexander Kuzmenkov wrote: Here is a version that compiles. I had a quick read through this and I think its missing about a 1-page comment section detailing when we can and when we cannot remove these self joins, and

Re: [HACKERS] PoC: full merge join on comparison clause

2018-11-21 Thread Alexander Kuzmenkov
On 11/19/18 04:46, Tom Lane wrote: In short, proceeding like the above when we can't find another plan type for a full join seems like it fixes a far wider variety of cases. The possibility that maybe we could do some of those cases a bit faster isn't sufficiently attractive to me to justify also

Re: [PATCH] Pass COPT and PROFILE to CXXFLAGS as well

2018-11-21 Thread Christoph Berg
(Sorry for the delayed response here.) Re: Andres Freund 2018-11-13 <20181113223330.2ql7tg33hhh6h...@alap3.anarazel.de> > > >> While working on making extension modules built reproducibly, I > > >> noticed that extra flags passed via COPT (notably -ffile-prefix-map) > > >> do not get added to CXXF

Re: Libpq support to connect to standby server as priority

2018-11-21 Thread Robert Haas
On Fri, Nov 16, 2018 at 11:35 AM Tom Lane wrote: > Oh! The reason I assumed it wasn't doing that is that such a behavior > seems completely insane. If the point is to keep down the load on your > master server, then connecting only to immediately disconnect is not > a friendly way to do that ---

Re: Small performance tweak to run-time partition pruning

2018-11-21 Thread David Rowley
On Fri, 16 Nov 2018 at 07:50, Tom Lane wrote: > I pushed this with a bit of extra tweaking --- notably, I added an > Assert to ExecFindMatchingSubPlans to guard against the possibility > that someone calls it when the remapping hasn't been done. Thanks for pushing. > I am not really convinced th

Re: Libpq support to connect to standby server as priority

2018-11-21 Thread Dave Cramer
On Wed, 21 Nov 2018 at 09:05, Robert Haas wrote: > On Fri, Nov 16, 2018 at 11:35 AM Tom Lane wrote: > > Oh! The reason I assumed it wasn't doing that is that such a behavior > > seems completely insane. If the point is to keep down the load on your > > master server, then connecting only to im

Re: incorrect xlog.c coverage report

2018-11-21 Thread Alvaro Herrera
On 2018-Nov-21, Masahiko Sawada wrote: > I've looked into this issue and this happens on my environment (CentOS > 6.9 and gcob 4.4.7) as well. ISTM the cause would related to the > immediate shutdown mode we're using in test_recovery_standby. > Interestingly in my environment with the attached one

[PATCH] Log PostgreSQL version number on startup

2018-11-21 Thread Christoph Berg
Hi, it has bugged me for a long time that there's no clear "PostgreSQL is starting" message in the server log file. I'd like to change that for two reasons: * when reading a long log file, it's not entirely clear where a new server startup begins. It was worse in the past (first message was

Re: Control your disk usage in PG: Introduction to Disk Quota Extension

2018-11-21 Thread Robert Haas
On Tue, Nov 20, 2018 at 2:20 AM Haozhou Wang wrote: > We prepared a patch that includes the hook points. And such hook points are > needed for disk quota extension. > There are two hooks. > One is SmgrStat_hook. It's used to perform ad-hoc logic in storage when doing > smgr create/extend/truncat

Re: [PATCH] Opclass parameters

2018-11-21 Thread Robert Haas
On Wed, Feb 28, 2018 at 9:46 AM Nikolay Shaplov wrote: > 1. I've seen you've added a new attribute into pg_index. Why??!! > As far as I can get, if have index built on several columns (A1, A2, A3) you > can set, own opclass for each column. And set individual options for each > opclass if we are s

Re: Too many logs are written on Windows (LOG: could not reserve shared memory region (addr=%p) for child %p:)

2018-11-21 Thread Robert Haas
On Tue, Nov 20, 2018 at 1:21 AM Takahashi, Ryohei wrote: > My customer uses PostgreSQL on Windows and hits the problem that following > log is written to the server logs too frequently (250 thousand times per day). > "LOG: could not reserve shared memory region (addr=%p) for child %p:" > > This

Re: [RFC] Removing "magic" oids

2018-11-21 Thread Andreas Karlsson
On 11/21/18 1:07 AM, Andres Freund wrote: Let's see what I broke :/ There is a small typo in the old release notes. Andreas diff --git a/doc/src/sgml/release-9.1.sgml b/doc/src/sgml/release-9.1.sgml index 3407d8ad739..a522e7e0225 100644 --- a/doc/src/sgml/release-9.1.sgml +++ b/doc/src/sgml/re

Re: ToDo: show size of partitioned table

2018-11-21 Thread Pavel Stehule
út 20. 11. 2018 v 9:14 odesílatel Amit Langote < langote_amit...@lab.ntt.co.jp> napsal: > On 2018/11/20 16:50, Michael Paquier wrote: > > Testing the feature, \dP shows all partitioned relations, still does not > > show the relationship when multiple levels are used. Could it make > > sense to al

Re: Index Skip Scan

2018-11-21 Thread Alexander Kuzmenkov
On 11/18/18 02:27, Dmitry Dolgov wrote: [0001-Index-skip-scan-v4.patch] I ran a couple of tests on this, please see the cases below. As before, I'm setting total_cost = 1 for index skip scan so that it is chosen. Case 1 breaks because we determine the high key incorrectly, it is the second

Re: Need of maintaining unsupported release notes in HEAD?

2018-11-21 Thread Andreas Karlsson
On 11/21/18 2:51 AM, Haribabu Kommi wrote:> Attached patch removes all the older release notes sgml files from HEAD. And also going forward, how about removing one major version file whenever that is unsupported from HEAD? comments? I have found these old notes useful multiple times in the pa

Re: ToDo: show size of partitioned table

2018-11-21 Thread Pavel Stehule
út 20. 11. 2018 v 8:50 odesílatel Michael Paquier napsal: > On Mon, Nov 05, 2018 at 11:43:16AM +0100, Pavel Stehule wrote: > > should be fixed now. > > Here are some notes on the last version. > > + " FROM pg_inherits i\n" > Missing schema qualification. > > fixed > + c

Re: ToDo: show size of partitioned table

2018-11-21 Thread Alvaro Herrera
Hmm, these tests are not going to work, because they have "pavel" in the expected output. -- Álvaro Herrerahttps://www.2ndQuadrant.com/ PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services

Re: [PATCH] Log PostgreSQL version number on startup

2018-11-21 Thread Stephen Frost
Greetings, * Christoph Berg (christoph.b...@credativ.de) wrote: > it has bugged me for a long time that there's no clear "PostgreSQL is > starting" message in the server log file. I'd like to change that for > two reasons: +1 > * when reading a long log file, it's not entirely clear where a new

Re: ToDo: show size of partitioned table

2018-11-21 Thread Pavel Stehule
st 21. 11. 2018 v 17:21 odesílatel Alvaro Herrera napsal: > Hmm, these tests are not going to work, because they have "pavel" in the > expected output. > I was blind, thank you for check fixed Regards Pavel > > -- > Álvaro Herrerahttps://www.2ndQuadrant.com/ > PostgreSQL Dev

Re: Need of maintaining unsupported release notes in HEAD?

2018-11-21 Thread Tom Lane
Andreas Karlsson writes: > On 11/21/18 2:51 AM, Haribabu Kommi wrote:> Attached patch removes all > the older release notes sgml files from HEAD. >> And also going forward, how about removing one major version file >> whenever that is unsupported from HEAD? > I have found these old notes useful

Re: Speeding up INSERTs and UPDATEs to partitioned tables

2018-11-21 Thread Alvaro Herrera
On 2018-Nov-21, David Rowley wrote: > If I wasn't on leave late last week and early this week then the only > thing I'd have mentioned was the lack of empty comment line in the > header comment for PartitionDispatchData. It looks a bit messy > without. Absolutely. Pushed a few newlines -- I hope

Re: pgbench - doCustom cleanup

2018-11-21 Thread Alvaro Herrera
On 2018-Nov-20, Fabien COELHO wrote: > > On INSTR_TIME_SET_CURRENT_LAZY(), you cannot just put an "if" inside a > > macro -- consider this: > > if (foo) > > INSTR_TIME_SET_CURRENT_LAZY(bar); > > else > > something_else(); > > Which "if" is the else now attached to?

Re: pgsql: instr_time.h: add INSTR_TIME_SET_CURRENT_LAZY

2018-11-21 Thread Stephen Frost
Greetings, * Alvaro Herrera (alvhe...@alvh.no-ip.org) wrote: > instr_time.h: add INSTR_TIME_SET_CURRENT_LAZY > > Sets the timestamp to current if not already set. Will acquire more > callers momentarily. > > Author: Fabien Coelho > Discussion: https://postgr.es/m/alpine.DEB.2.21.180804320.1

Re: [RFC] Removing "magic" oids

2018-11-21 Thread Andrew Dunstan
On 11/20/18 7:07 PM, Andres Freund wrote: Let's see what I broke :/ pg_upgrade against old versions, by the look of it. Even after I drop oids from user tables, I get errors like this when running pg_dumpall against a pg_upgraded REL_9_4_STABLE datadir: 2018-11-21 13:01:58.582 EST [1

Re: incorrect xlog.c coverage report

2018-11-21 Thread Tom Lane
Alvaro Herrera writes: > On 2018-Nov-21, Masahiko Sawada wrote: >> I've looked into this issue and this happens on my environment (CentOS >> 6.9 and gcob 4.4.7) as well. ISTM the cause would related to the >> immediate shutdown mode we're using in test_recovery_standby. Doh, of course. > I think

Re: pgsql: instr_time.h: add INSTR_TIME_SET_CURRENT_LAZY

2018-11-21 Thread Alvaro Herrera
On 2018-Nov-21, Stephen Frost wrote: > Greetings, > > * Alvaro Herrera (alvhe...@alvh.no-ip.org) wrote: > > instr_time.h: add INSTR_TIME_SET_CURRENT_LAZY > > > > Sets the timestamp to current if not already set. Will acquire more > > callers momentarily. > > > > Author: Fabien Coelho > > Discu

Re: [RFC] Removing "magic" oids

2018-11-21 Thread Andres Freund
On November 21, 2018 10:17:57 AM PST, Andrew Dunstan wrote: > >On 11/20/18 7:07 PM, Andres Freund wrote: >> >> >> Let's see what I broke :/ >> > > >pg_upgrade against old versions, by the look of it. Even after I drop >oids from user tables, I get errors like this when running pg_dumpall >ag

Re: ATTACH/DETACH PARTITION CONCURRENTLY

2018-11-21 Thread Robert Haas
On Wed, Nov 14, 2018 at 9:03 PM Amit Langote wrote: > On 2018/11/15 4:27, Robert Haas wrote: > > RelationBuildPartitionDesc doesn't lock the children > > whose relpartbounds it is fetching (!), so unless we're guaranteed to > > have already locked them children earlier for some other reason, we >

Re: pgsql: instr_time.h: add INSTR_TIME_SET_CURRENT_LAZY

2018-11-21 Thread Stephen Frost
Greetings, * Alvaro Herrera (alvhe...@2ndquadrant.com) wrote: > On 2018-Nov-21, Stephen Frost wrote: > > * Alvaro Herrera (alvhe...@alvh.no-ip.org) wrote: > > > instr_time.h: add INSTR_TIME_SET_CURRENT_LAZY > > > > > > Sets the timestamp to current if not already set. Will acquire more > > > cal

Re: pgsql: instr_time.h: add INSTR_TIME_SET_CURRENT_LAZY

2018-11-21 Thread Alvaro Herrera
On 2018-Nov-21, Stephen Frost wrote: > Greetings, > > * Alvaro Herrera (alvhe...@2ndquadrant.com) wrote: > > Yeah, looking into this mess already. > > Much better now, thanks! Yay :-) -- Álvaro Herrerahttps://www.2ndQuadrant.com/ PostgreSQL Development, 24x7 Support, Remote D

Re: pgbench - doCustom cleanup

2018-11-21 Thread Alvaro Herrera
I just pushed this. I hope not to have upset you too much with the subroutine thing. Thanks for the submission and Kirk for the review. -- Álvaro Herrerahttps://www.2ndQuadrant.com/ PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services

Re: [HACKERS] pgbench - allow to store select results into variables

2018-11-21 Thread Alvaro Herrera
On 2018-Nov-18, Fabien COELHO wrote: > Attached a v23 with PQExpBuffer for managing lines. > > I've also added a function to compute the summary first line, which handles > carriage-return. Thanks. Please when you rebase, consider these (minor) changes. -- Álvaro Herrerahttps:

Re: Index Skip Scan

2018-11-21 Thread Dmitry Dolgov
> On Wed, Nov 21, 2018 at 4:38 PM Alexander Kuzmenkov > wrote: > > On 11/18/18 02:27, Dmitry Dolgov wrote: > > > > [0001-Index-skip-scan-v4.patch] > > I ran a couple of tests on this, please see the cases below. As before, > I'm setting total_cost = 1 for index skip scan so that it is chosen. > C

Re: [Proposal] Add accumulated statistics

2018-11-21 Thread Bruce Momjian
On Tue, Nov 6, 2018 at 04:26:03AM +, Yotsunaga, Naoki wrote: > On Sat, Nov 3, 2018 at 1:28 AM, Phil Florent wrote: > > > > >2) it consumes system resources > > While the system is running, you are always sampling system information, do > not > you? Like Oracle ASH. > > If so, does sampl

Re: Speeding up INSERTs and UPDATEs to partitioned tables

2018-11-21 Thread David Rowley
On Thu, 22 Nov 2018 at 07:06, Alvaro Herrera wrote: > On 2018-Nov-21, David Rowley wrote: > > If I wasn't on leave late last week and early this week then the only > > thing I'd have mentioned was the lack of empty comment line in the > > header comment for PartitionDispatchData. It looks a bit me

pg_upgrade supported versions policy

2018-11-21 Thread Andres Freund
Hi, I feel like we ought to trim the support for a few old versions from pg_upgrade. In my particular case I don't really think it's reasonable to test < 9.0 versions for pg_largeobject_metadata migrations. But I think we should create a policy that's the default, leaving individual cases aside.

reg* checks in pg_upgrade are out of date

2018-11-21 Thread Andres Freund
Hi, It seems the list of reg* types and the check for them in pg_upgrade have gone out of sync. We have the following reg* types: SELECT typname FROM pg_type WHERE typname LIKE 'reg%' order by typname; ┌───┐ │typname│ ├───┤ │ regclass │ │ regconfig │ │ re

Re: [RFC] Removing "magic" oids

2018-11-21 Thread Andres Freund
Hi, On 2018-11-21 10:36:42 -0800, Andres Freund wrote: > >pg_upgrade against old versions, by the look of it. Even after I drop > >oids from user tables, I get errors like this when running pg_dumpall > >against a pg_upgraded REL_9_4_STABLE datadir: Not pg_upgrade in general, I did test that. "

Re: pg_upgrade supported versions policy

2018-11-21 Thread Stephen Frost
Greetings, * Andres Freund (and...@anarazel.de) wrote: > I feel like we ought to trim the support for a few old versions from > pg_upgrade. In my particular case I don't really think it's reasonable > to test < 9.0 versions for pg_largeobject_metadata migrations. But I > think we should create a

Re: pg_upgrade supported versions policy

2018-11-21 Thread Andres Freund
Hi, On 2018-11-21 19:25:45 -0500, Stephen Frost wrote: > * Andres Freund (and...@anarazel.de) wrote: > > I feel like we ought to trim the support for a few old versions from > > pg_upgrade. In my particular case I don't really think it's reasonable > > to test < 9.0 versions for pg_largeobject_me

Re: ToDo: show size of partitioned table

2018-11-21 Thread Michael Paquier
On Wed, Nov 21, 2018 at 05:37:33PM +0100, Pavel Stehule wrote: > st 21. 11. 2018 v 17:21 odesílatel Alvaro Herrera > napsal: >> Hmm, these tests are not going to work, because they have "pavel" in the >> expected output. > > I was blind, thank you for check +create table testtable_apple(logdate

Re: Continue work on changes to recovery.conf API

2018-11-21 Thread Michael Paquier
On Wed, Nov 21, 2018 at 12:58:19PM +0100, Peter Eisentraut wrote: > This wasn't my idea, so this is just my interpretation. The scenario > I'm wondering about is: You have a standby. So (under your system) you > set standby_mode=on and create recovery.trigger. Then you promote that > standby, s

Re: Online verification of checksums

2018-11-21 Thread Stephen Frost
Greetings, * Michael Banck (michael.ba...@credativ.de) wrote: > On Tue, Oct 30, 2018 at 06:22:52PM +0100, Fabien COELHO wrote: > > The "check if page was modified since checkpoint" does not look useful when > > offline. Maybe it lacks a comment to say that this cannot (should not ?) > > happen whe

Re: incorrect xlog.c coverage report

2018-11-21 Thread Michael Paquier
On Wed, Nov 21, 2018 at 01:20:48PM -0500, Tom Lane wrote: > Alvaro Herrera writes: >> I think we should change all calls of ->teardown_node to ->stop(), >> except the one in the END block, and look for places which are currently >> relying too much on END (i.e. add more ->stop() calls where needed

Re: incorrect xlog.c coverage report

2018-11-21 Thread Thomas Munro
On Thu, Nov 22, 2018 at 2:22 PM Michael Paquier wrote: > On Wed, Nov 21, 2018 at 01:20:48PM -0500, Tom Lane wrote: > > Alvaro Herrera writes: > >> I think we should change all calls of ->teardown_node to ->stop(), > >> except the one in the END block, and look for places which are currently > >>

Re: incorrect xlog.c coverage report

2018-11-21 Thread Masahiko Sawada
On Thu, Nov 22, 2018 at 10:43 AM Thomas Munro wrote: > > On Thu, Nov 22, 2018 at 2:22 PM Michael Paquier wrote: > > On Wed, Nov 21, 2018 at 01:20:48PM -0500, Tom Lane wrote: > > > Alvaro Herrera writes: > > >> I think we should change all calls of ->teardown_node to ->stop(), > > >> except the o

Re: Pluggable Storage - Andres's take

2018-11-21 Thread Asim R P
Ashwin (copied) and I got a chance to go through the latest code from Andres' github repository. We would like to share some comments/quesitons: The TupleTableSlot argument is well suited for row-oriented storage. For a column-oriented storage engine, a projection list indicating the columns to b

Re: incorrect xlog.c coverage report

2018-11-21 Thread Michael Paquier
On Thu, Nov 22, 2018 at 10:56:39AM +0900, Masahiko Sawada wrote: > On Thu, Nov 22, 2018 at 10:43 AM Thomas Munro > wrote: >> Presumably you could add your own call to __gcov_flush() in >> quickdie(), so that we get GCOV data but no other atexit()-like stuff. >> I see that some people advocate doi

Re: Speeding up INSERTs and UPDATEs to partitioned tables

2018-11-21 Thread Amit Langote
Hi, On Thu, Nov 22, 2018 at 7:25 AM David Rowley wrote: > > On Thu, 22 Nov 2018 at 07:06, Alvaro Herrera wrote: > > On 2018-Nov-21, David Rowley wrote: > > > If I wasn't on leave late last week and early this week then the only > > > thing I'd have mentioned was the lack of empty comment line in

Re: incorrect xlog.c coverage report

2018-11-21 Thread Alvaro Herrera
On 2018-Nov-22, Michael Paquier wrote: > On Thu, Nov 22, 2018 at 10:56:39AM +0900, Masahiko Sawada wrote: > > On Thu, Nov 22, 2018 at 10:43 AM Thomas Munro > > wrote: > >> Presumably you could add your own call to __gcov_flush() in > >> quickdie(), so that we get GCOV data but no other atexit()-

Re: New function pg_stat_statements_reset_query() to reset statistics of a specific query

2018-11-21 Thread Amit Kapila
On Mon, Nov 19, 2018 at 10:48 AM Haribabu Kommi wrote: > > On Mon, Nov 19, 2018 at 1:37 PM Alvaro Herrera > wrote: >> >> On 2018-Nov-19, Michael Paquier wrote: >> >> > On Mon, Nov 19, 2018 at 10:41:22AM +1100, Haribabu Kommi wrote: >> > > So 6 new functions needs to be added to cover all the abo

Re: incorrect xlog.c coverage report

2018-11-21 Thread Andres Freund
On 2018-11-21 23:45:01 -0300, Alvaro Herrera wrote: > On 2018-Nov-22, Michael Paquier wrote: > > > On Thu, Nov 22, 2018 at 10:56:39AM +0900, Masahiko Sawada wrote: > > > On Thu, Nov 22, 2018 at 10:43 AM Thomas Munro > > > wrote: > > >> Presumably you could add your own call to __gcov_flush() in

Re: zheap: a new storage format for PostgreSQL

2018-11-21 Thread Amit Kapila
On Tue, Nov 20, 2018 at 12:53 PM Darafei "Komяpa" Praliaskouski wrote: >> >> > In PostGIS workloads, UPDATE table SET geom = ST_CostyFunction(geom, >> > magicnumber); is one of biggest time-eaters that happen upon initial load >> > and clean up of your data. It is commonly followed by CLUSTER ta

Re: Use durable_unlink for .ready and .done files for WAL segment removal

2018-11-21 Thread Michael Paquier
On Thu, Nov 15, 2018 at 07:39:27PM +0900, Kyotaro HORIGUCHI wrote: > At Fri, 02 Nov 2018 14:47:08 +, Nathan Bossart > wrote in > <154117002849.5569.14588306221618961668.p...@coridan.postgresql.org>: >> One argument for instead checking WAL file existence before calling >> archive_command might

Re: Speeding up INSERTs and UPDATEs to partitioned tables

2018-11-21 Thread Michael Paquier
On Thu, Nov 22, 2018 at 11:32:04AM +0900, Amit Langote wrote: > I noticed that there's a "be" missing in the comment above > ExecFindPartition. Fixed in the attached. Thanks Amit, I have committed this one. -- Michael signature.asc Description: PGP signature

Re: [RFC] Removing "magic" oids

2018-11-21 Thread Andrew Dunstan
On 11/21/18 7:14 PM, Andres Freund wrote: Could you check whether you still encounter the issue after applying the attached fix? This has largely fixed the problem, so I think this should be applied. With some adjustments to the tests to remove problematic cases (e.g. postgres_fdw's ft_

Re: A WalSnd issue related to state WALSNDSTATE_STOPPING

2018-11-21 Thread Michael Paquier
On Wed, Nov 21, 2018 at 04:09:41PM +0900, Michael Paquier wrote: > The checkpointer initializes a shutdown checkpoint where it tells to all > the WAL senders to stop once all the children processes are gone, so it > seems to me that there is little point in processing > SyncRepReleaseWaiters() when

Re: performance statistics monitoring without spamming logs

2018-11-21 Thread Justin Pryzby
Hi, I'm replying to an old thread from -performance: https://www.postgresql.org/message-id/flat/7ffb9dbe-c76f-8ca3-12ee-7914ede872e6%40stormcloud9.net I was looking at: https://commitfest.postgresql.org/20/1691/ "New GUC to sample log queries" On Tue, Jul 10, 2018 at 01:54:12PM -0400, Patrick He

Re: MERGE SQL statement for PG12

2018-11-21 Thread Pavan Deolasee
Hi Tomas, Sorry for a delayed response. On Mon, Oct 29, 2018 at 4:59 PM Tomas Vondra wrote: > Hi Pavan, > > On 10/29/2018 10:23 AM, Pavan Deolasee wrote: > > > > ... > > > > Thanks for keeping an eye on the patch. I've rebased the patch > > against the current master. A new version is attached.

Re: Tid scan improvements

2018-11-21 Thread David Rowley
On Mon, 12 Nov 2018 at 17:35, Edmund Horner wrote: > Hi, here's the new patch(s). > > Mostly the same, but trying to address your comments from earlier as > well as clean up a few other things I noticed. Thanks for making those changes. I've now had a look over the latest patches and I've found

Re: [Todo item] Add entry creation timestamp column to pg_stat_replication

2018-11-21 Thread Michael Paquier
On Thu, Nov 15, 2018 at 05:33:26PM +0900, Masahiko Sawada wrote: > Yeah, I also agree with 'reply_time'. But please also note that we had > the discussion when there is not the similar system catalogs and > fields. Now that we have them it might be worth to consider to follow > the existing name fo