Re: [HACKERS] Foreign join pushdown vs EvalPlanQual

2015-09-07 Thread Etsuro Fujita
On 2015/09/04 19:50, Etsuro Fujita wrote: I'm attaching an updated version of the patch. The patch is based on the SS_finalize_plan patch that has been recently committed. I'd be happy if this helps people discuss more about how to fix this issue. In the updated version, I modified

Re: [HACKERS] checkpointer continuous flushing

2015-09-07 Thread Fabien COELHO
Hello Amit, It'd not really simplify things, but it'd keep it local. How about using the value of guc (checkpoint_flush_to_disk) and AmCheckpointerProcess to identify whether to do async flush in FileWrite? ISTM that what you suggest would just replace the added function arguments with

Re: [HACKERS] Foreign join pushdown vs EvalPlanQual

2015-09-07 Thread Kyotaro HORIGUCHI
Hello, sorry in advance for possible brought up of past discussions or pointless discussion. > I'm attaching an updated version of the patch. The patch is based on > the SS_finalize_plan patch that has been recently committed. I'd be > happy if this helps people discuss more about how to fix

Re: [HACKERS] [PATCH] Refactoring of LWLock tranches

2015-09-07 Thread Ildus Kurbangaliev
On Sun, 6 Sep 2015 23:18:02 +0200 "and...@anarazel.de" wrote: > On 2015-09-06 22:57:04 +0300, Ildus Kurbangaliev wrote: > > Ok, I've kept only one tranche for individual LWLocks > > But you've added the lock names as a statically sized array to all > tranches? Why not just a

Re: [HACKERS] On-demand running query plans using auto_explain and signals

2015-09-07 Thread Shulgin, Oleksandr
On Fri, Sep 4, 2015 at 6:11 AM, Pavel Stehule wrote: > Sorry, but I still don't see how the slots help this issue - could you >> please elaborate? >> > with slot (or some similiar) there is not global locked resource. If I'll > have a time at weekend I'll try to write

Re: [HACKERS] Waits monitoring

2015-09-07 Thread Ildus Kurbangaliev
On Mon, 7 Sep 2015 08:58:15 +0530 Amit Kapila wrote: > On Sun, Sep 6, 2015 at 5:58 PM, Andres Freund > wrote: > > > > On 2015-09-04 23:44:21 +0100, Simon Riggs wrote: > > > I see the need for both current wait information and for > > > cumulative

Re: [HACKERS] about fsync in CLOG buffer write

2015-09-07 Thread 张广舟(明虚)
Andres, Thanks for the reply! I will try the ForwardFsyncRequest-like approach. 在 15-9-2 下午8:32, "Andres Freund" 写入: >On 2015-09-10 19:39:59 +0800, 张广舟(明虚) wrote: >> We found there is a fsync call when CLOG buffer >> is written out in SlruPhysicalWritePage(). It is often

Re: [HACKERS] Fwd: [Snowball-discuss] New website

2015-09-07 Thread Magnus Hagander
I assume this is to replace the old site completely? If so, I think we should just backpatch it to all supported branches -- it's basically a bugfix as I understand it. The old site is eventually going out of business or at least not being properly updated, so we'll eventually end up with broken

[HACKERS] Creating unique or "internal-use-only" column names (ColumnRef)

2015-09-07 Thread Peter Moser
Good afternoon, is it possible to create unique column names or to give column names inside the parser phase that do not interfer with the outside world, i.e. with column names from tables or aliases given by the user. Some short background: I created my own from-clause-item, that gets

[HACKERS] Re: [COMMITTERS] pgsql: Move DTK_ISODOW DTK_DOW and DTK_DOY to be type UNITS rather than

2015-09-07 Thread Greg Stark
On Sun, Sep 6, 2015 at 4:14 AM, Greg Stark wrote: >> Also, what about ecpg's copy of the code? > > That I hadn't thought of. Will look at it but it's after 4am here now > so I'll get to it tomorrow. So the only mention of these constants I can find in ECPG is the structures in

Re: [HACKERS] Creating unique or "internal-use-only" column names (ColumnRef)

2015-09-07 Thread Tom Lane
Andrew Dunstan writes: > On 09/07/2015 09:28 AM, Alvaro Herrera wrote: >> This seems pretty much the same as a junk attribute, if I understand you >> correctly. I suggest given a look at how those work. > Is that actually documented anywhere much? I don't think there's

Re: [HACKERS] Use pg_rewind when target timeline was switched

2015-09-07 Thread Alexander Korotkov
On Thu, Aug 20, 2015 at 9:57 AM, Michael Paquier wrote: > On Wed, Jul 22, 2015 at 4:28 PM, Alexander Korotkov < > a.korot...@postgrespro.ru> wrote: > >> On Wed, Jul 22, 2015 at 8:48 AM, Michael Paquier < >> michael.paqu...@gmail.com> wrote >> >>> On Mon, Jul 20, 2015

Re: [HACKERS] Freeze avoidance of very large table.

2015-09-07 Thread Masahiko Sawada
On Sat, Sep 5, 2015 at 7:35 AM, Simon Riggs wrote: > On 3 September 2015 at 18:23, Masahiko Sawada wrote: > >> >> The previous patch lacks some files for regression test. >> Attached fixed v12 patch. > > > This looks OK. You saw that I was proposing

[HACKERS] LLVM Address Sanitizer (ASAN) and valgrind support

2015-09-07 Thread Greg Stark
I feel like I remember hearing about this before but I can't find any mention of it in my mail archives. It seems pretty simple to add support for LLVM's Address Sanitizer (asan) by using the hooks we already have for valgrind. In fact I think this would actually be sufficient. I'm not sure what

Re: [HACKERS] WIP: Access method extendability

2015-09-07 Thread Petr Jelinek
On 2015-09-07 17:41, Teodor Sigaev wrote: Some notices: 1) create-am.3.patch.gz As I understand, you didn't add schema name to access method. Why? Suppose, if we implement SQL-like interface for AM screation/dropping then we should provide a schema qualification for them Why would access

Re: [HACKERS] Proposal: Implement failover on libpq connect level.

2015-09-07 Thread Daniel Verite
Victor Wagner wrote: > It would just take a bit more time for client and a bit more load for > server - to make sure that this connection is read-write by > issuing > >show transaction_read_only > > statement before considering connection useful. If the purpose of the feature is

Re: [HACKERS] WIP: Access method extendability

2015-09-07 Thread Teodor Sigaev
Some notices: 1) create-am.3.patch.gz As I understand, you didn't add schema name to access method. Why? Suppose, if we implement SQL-like interface for AM screation/dropping then we should provide a schema qualification for them 2) create-am.3.patch.gz get_object_address_am() +

Re: [HACKERS] [PATCH] Microvacuum for gist.

2015-09-07 Thread Anastasia Lubennikova
04.09.2015 15:11, Teodor Sigaev: Some notices 1 gistvacuumpage(): OffsetNumber deletable[MaxOffsetNumber]; Seems, MaxOffsetNumber is too much, MaxIndexTuplesPerPage is enough Fixed. 2 Loop in gistkillitems() for searching heap pointer. It seems to me that it could be a performance

Re: [HACKERS] Creating unique or "internal-use-only" column names (ColumnRef)

2015-09-07 Thread Andrew Dunstan
On 09/07/2015 09:28 AM, Alvaro Herrera wrote: Peter Moser wrote: Good afternoon, is it possible to create unique column names or to give column names inside the parser phase that do not interfer with the outside world, i.e. with column names from tables or aliases given by the user. Some

Re: [HACKERS] Creating unique or "internal-use-only" column names (ColumnRef)

2015-09-07 Thread Alvaro Herrera
Peter Moser wrote: > Good afternoon, > is it possible to create unique column names or to give column names inside > the parser phase that do not interfer with the outside world, i.e. with > column names from tables or aliases given by the user. > > Some short background: > I created my own

Re: [HACKERS] WIP: Access method extendability

2015-09-07 Thread Alexander Korotkov
On Tue, Sep 1, 2015 at 6:50 PM, Teodor Sigaev wrote: > In general pattern of generic WAL usage is following. >> >> 1) Start using generic WAL: specify relation >> > > M-m, what about extensions which wants to use WAL but WAL record doesn't > connected to any relation? For

Re: [HACKERS] [COMMITTERS] pgsql: Move DTK_ISODOW DTK_DOW and DTK_DOY to be type UNITS rather than

2015-09-07 Thread Tom Lane
Greg Stark writes: >>> Also, what about ecpg's copy of the code? > So the only mention of these constants I can find in ECPG is the > structures in dt_common.c. I don't see a any code using it and I'm not > clear what the purpose of having this structure is or the significance >

Re: [HACKERS] synchronous_commit = apply

2015-09-07 Thread Thomas Munro
[Combining replies to emails from different authors into one message] On Wed, Sep 2, 2015 at 2:21 PM, Jaime Casanova < jaime.casan...@2ndquadrant.com> wrote: > On 1 September 2015 at 20:25, Thomas Munro > wrote: > As a quick weekend learning exercise/hack I

Re: [HACKERS] Speed up Clog Access by increasing CLOG buffers

2015-09-07 Thread Alvaro Herrera
Andres Freund wrote: > The buffer replacement algorithm for clog is rather stupid - I do wonder > where the cutoff is that it hurts. > > Could you perhaps try to create a testcase where xids are accessed that > are so far apart on average that they're unlikely to be in memory? And > then test

Re: [HACKERS] Making tab-complete.c easier to maintain

2015-09-07 Thread Alvaro Herrera
Thomas Munro wrote: > Thanks, good point. Here's a version that uses NULL via a macro ANY. > Aside from a few corrections it also now distinguishes between > TAIL_MATCHESn (common) and MATCHESn (rarely used for now), for example: This looks pretty neat -- 100x neater than what we have, at any

Re: [HACKERS] Improving test coverage of extensions with pg_dump

2015-09-07 Thread Michael Paquier
On Thu, Sep 3, 2015 at 10:35 AM, Michael Paquier wrote: > On Thu, Sep 3, 2015 at 12:38 AM, Andres Freund wrote: >> Isn't a full test with a separate initdb, create extension etc. a really >> heavyhanded way to test this? I mean that's a test where the setup takes >> up

Re: [HACKERS] Speed up Clog Access by increasing CLOG buffers

2015-09-07 Thread Andres Freund
Hi, On 2015-09-07 10:34:10 -0300, Alvaro Herrera wrote: > I wonder if it would make sense to explore an idea that has been floated > for years now -- to have pg_clog pages be allocated as part of shared > buffers rather than have their own separate pool. That way, no separate > hardcoded

Re: [HACKERS] Separating Buffer LWlocks

2015-09-07 Thread Andres Freund
On 2015-09-06 15:28:40 +0200, Andres Freund wrote: > Hm. I found that the buffer content lwlocks can actually also be a > significant source of contention - I'm not sure reducing padding for > those is going to be particularly nice. I think we should rather move > the *content* lock inline into

Re: [HACKERS] WIP: Rework access method interface

2015-09-07 Thread Petr Jelinek
On 2015-09-04 16:26, Alexander Korotkov wrote: Attached patch is implementing this. It doesn't pretend to be fully correct implementation, but it should be enough for proof the concept. In this patch access method exposes another function: amvalidate. It takes data structure representing

Re: [HACKERS] [COMMITTERS] pgsql: contrib/sslinfo: add ssl_extension_info SRF

2015-09-07 Thread Michael Paquier
On Tue, Sep 8, 2015 at 9:24 AM, Alvaro Herrera wrote: > contrib/sslinfo: add ssl_extension_info SRF > > This new function provides information about SSL extensions present in > the X509 certificate used for the current connection. > > Extension version updated to version

Re: [HACKERS] pageinspect patch, for showing tuple data

2015-09-07 Thread Michael Paquier
On Tue, Sep 8, 2015 at 11:53 AM, Michael Paquier wrote: > Honestly, heap_page_item_attrs and heap_page_item_detoast_attrs are way too > similar to what heap_page_items does, leading to a code maze that is going > to make future extensions more difficult, which is what lead to the > refactoring

Re: [HACKERS] On-demand running query plans using auto_explain and signals

2015-09-07 Thread Pavel Stehule
2015-09-07 11:55 GMT+02:00 Shulgin, Oleksandr : > On Fri, Sep 4, 2015 at 6:11 AM, Pavel Stehule > wrote: > >> Sorry, but I still don't see how the slots help this issue - could you >>> please elaborate? >>> >> with slot (or some similiar)

Re: [HACKERS] exposing pg_controldata and pg_config as functions

2015-09-07 Thread Alvaro Herrera
Andrew Dunstan wrote: > I already gave a use case that you dismissed in favour of a vague solution > that we don't actually have. You seem to be the only person objecting to > this proposal. I think that use case would be better served by a completely different interface -- some way to query the

Re: [HACKERS] Proposal: Implement failover on libpq connect level.

2015-09-07 Thread Victor Wagner
В Mon, 07 Sep 2015 17:32:48 +0200 "Daniel Verite" пишет: > Victor Wagner wrote: > > > It would just take a bit more time for client and a bit more load > > for server - to make sure that this connection is read-write by > > issuing > > > >show

Re: [HACKERS] One question about security label command

2015-09-07 Thread Joe Conway
On 08/30/2015 11:17 AM, Joe Conway wrote: >>> 3.) Rework patch for 9.2 (Kohei) >>> 4.) Finish standing up the RHEL/CentOS 7.x buildfarm member to >>> test sepgsql on 9.2 and up. The animal (rhinoceros) is running >>> already, but still needs some custom scripting. (Joe, Andrew) >>> 5.)

Re: [HACKERS] exposing pg_controldata and pg_config as functions

2015-09-07 Thread Josh Berkus
On 09/06/2015 12:34 PM, Joe Conway wrote: > To the extent that we want specific pg_controldata output in non-text > form, we should identify which items those are and provide individual > functions for them. Well, I think it's pretty simple, let's take it down: # function

Re: [HACKERS] creating extension including dependencies

2015-09-07 Thread Michael Paquier
On Tue, Sep 8, 2015 at 10:44 AM, Michael Paquier wrote: > On Tue, Sep 8, 2015 at 6:14 AM, Petr Jelinek wrote: >> Attached patch uses just boolean in cascade DefElem and splits the >> CreateExtension into two functions, the cascade code now calls the >>

Re: [HACKERS] New functions

2015-09-07 Thread Alvaro Herrera
Michael Paquier wrote: > On Sun, Aug 23, 2015 at 10:21 PM, Michael Paquier wrote: > > By the way, perhaps it would be worth doing similar things for the > > other calls of BIO_free and BIO_new, no? I have attached a second > > patch. > > And... This second patch had a stupid mistake making for

Re: [HACKERS] pg_hba_lookup function to get all matching pg_hba.conf entries

2015-09-07 Thread Haribabu Kommi
On Mon, Sep 7, 2015 at 4:34 AM, Pavel Stehule wrote: > Hi > > >> >> postgres=# select pg_hba_lookup('postgres','all'); >> pg_hba_lookup >> --- >> (84,local,"[""all""]","[""all""]",,,trust,{}) >>

Re: [HACKERS] creating extension including dependencies

2015-09-07 Thread Michael Paquier
On Tue, Sep 8, 2015 at 6:14 AM, Petr Jelinek wrote: > Attached patch uses just boolean in cascade DefElem and splits the > CreateExtension into two functions, the cascade code now calls the > CreateExtensionInternal. One thing though - I am passing the DefElems > directly to the cascaded

Re: [HACKERS] Should TIDs be typbyval = FLOAT8PASSBYVAL to speed up CREATE INDEX CONCURRENTLY?

2015-09-07 Thread Peter Geoghegan
On Mon, Sep 7, 2015 at 9:03 PM, Tom Lane wrote: > I'm not sure that it would be just "a little work" --- I suspect that > the idea that pass-by-val types are 1, 2, 4, or 8 bytes is embedded in > a fair number of places, including alignment macros in which any added >

Re: [HACKERS] PATCH: numeric timestamp in log_line_prefix

2015-09-07 Thread Alvaro Herrera
Jeff Davis wrote: > On Mon, 2015-09-07 at 18:28 -0300, Alvaro Herrera wrote: > > I think the extra ugliness is warranted, since it's not THAT much > > additional ugliness, and not doing it could be considered a regression; > > apparently strftime can be slower even than snprintf, so doing it

Re: [HACKERS] WIP: Make timestamptz_out less slow.

2015-09-07 Thread David Rowley
On 3 September 2015 at 22:17, Andres Freund wrote: > On 2015-09-03 16:28:40 +1200, David Rowley wrote: > > > Wouldn't it be better to just normalize fsec to an integer in that > case? > > > Afaics that's the only remaining reason for the alternative path? > > > > > > A

Re: [HACKERS] Should TIDs be typbyval = FLOAT8PASSBYVAL to speed up CREATE INDEX CONCURRENTLY?

2015-09-07 Thread Tom Lane
Peter Geoghegan writes: > I noticed that the TID type is cataloged as typbyval = f, despite the > fact that it is 6 bytes, and so could be made typbyval = t on 64-bit > platforms (i.e. typbyval = FLOAT8PASSBYVAL) with a little work. I'm not sure that it would be just "a little

Re: [HACKERS] WIP: Rework access method interface

2015-09-07 Thread Alexander Korotkov
On Mon, Sep 7, 2015 at 10:02 PM, Petr Jelinek wrote: > On 2015-09-07 20:56, Alexander Korotkov wrote: > >> On Mon, Sep 7, 2015 at 9:17 PM, Petr Jelinek > >> However I don't like the naming differences between validate_opclass >> and

Re: [HACKERS] New functions

2015-09-07 Thread Alvaro Herrera
Michael Paquier wrote: > Note for committers: attached is a small script that will generate a > client certificate with extensions enabled. This is helpful when > testing this patch. Once created, then simply connect with something > like this connection string: > "host=127.0.0.1

Re: [HACKERS] [COMMITTERS] pgsql: contrib/sslinfo: add ssl_extension_info SRF

2015-09-07 Thread Alvaro Herrera
Michael Paquier wrote: > On Tue, Sep 8, 2015 at 9:24 AM, Alvaro Herrera > wrote: > > contrib/sslinfo: add ssl_extension_info SRF > > > > This new function provides information about SSL extensions present in > > the X509 certificate used for the current connection. > > >

Re: [HACKERS] One question about security label command

2015-09-07 Thread Joe Conway
On 09/07/2015 04:46 PM, Kouhei Kaigai wrote: > 3.) Rework patch for 9.2 (Kohei) >> > Could you wait for the next Monday? > I'll try to work this in the next weekend. Sure, that would be great. Joe -- Crunchy Data - http://crunchydata.com PostgreSQL Support for Secure Enterprises

[HACKERS] Should TIDs be typbyval = FLOAT8PASSBYVAL to speed up CREATE INDEX CONCURRENTLY?

2015-09-07 Thread Peter Geoghegan
I noticed that the TID type is cataloged as typbyval = f, despite the fact that it is 6 bytes, and so could be made typbyval = t on 64-bit platforms (i.e. typbyval = FLOAT8PASSBYVAL) with a little work. This matters because a major cost during CREATE INDEX CONCURRENTLY is a TID-based datum sort

Re: [HACKERS] psql tabcomplete - minor bugfix - tabcomplete for SET ROLE TO xxx

2015-09-07 Thread Pavel Stehule
2015-09-07 21:44 GMT+02:00 Andres Freund : > Hi, > > On 2015-09-02 22:58:21 +0200, Pavel Stehule wrote: > > > Won't that mean that enum variables don't complete to default anymore? > > > no, it does > > > > #define Query_for_enum \ > > " SELECT name FROM ( "\ > > " SELECT

Re: [HACKERS] Too many duplicated condition query return wrong value

2015-09-07 Thread Atsushi Yoshida
Thank you for your answer Jeff. I have fixed it. >> What type of index is it? (I'm now guessing btree, but maybe not)? Is >> there a defined time window during which you know the corruption occurred? >> If so, do you still have the server logs from that time window? The WAL >> logs? Its

[HACKERS] 答复:[HACKERS] about fsync in CLOG buffer write

2015-09-07 Thread 周正中(德歌)
>On 2015-09-10 19:39:59 +0800, 张广舟(明虚) wrote: >> We found there is a fsync call when CLOG buffer >> is written out in SlruPhysicalWritePage(). It is often called when a backend >> needs to check transaction status with SimpleLruReadPage(). >That's when there's not enough buffers available some 

Re: [HACKERS] PATCH: numeric timestamp in log_line_prefix

2015-09-07 Thread Jeff Davis
On Mon, 2015-09-07 at 18:28 -0300, Alvaro Herrera wrote: > I noticed %t, but I don't think we care since the precision is so poor. > Making m and n work in unison seems enough. I think it would be > reasonably simple to handle %t in the same way, but I'm not sure we > care. OK. > I think the

Re: [HACKERS] exposing pg_controldata and pg_config as functions

2015-09-07 Thread Andrew Dunstan
On 09/06/2015 11:17 PM, Peter Eisentraut wrote: On 9/6/15 3:34 PM, Joe Conway wrote: On 09/02/2015 02:54 PM, Alvaro Herrera wrote: Josh Berkus wrote: On 09/02/2015 02:34 PM, Alvaro Herrera wrote: I think trying to duplicate the exact strings isn't too nice an interface. Well, for

Re: [HACKERS] One question about security label command

2015-09-07 Thread Kouhei Kaigai
Hi Joe, > >>> 3.) Rework patch for 9.2 (Kohei) > Could you wait for the next Monday? I'll try to work this in the next weekend. -- NEC Business Creation Division / PG-Strom Project KaiGai Kohei > -Original Message- > From: Joe Conway [mailto:m...@joeconway.com] >

Re: [HACKERS] New functions

2015-09-07 Thread Michael Paquier
On Tue, Sep 8, 2015 at 7:31 AM, Alvaro Herrera wrote: > Michael Paquier wrote: >> On Sun, Aug 23, 2015 at 10:21 PM, Michael Paquier wrote: >> > By the way, perhaps it would be worth doing similar things for the >> > other calls of BIO_free and BIO_new, no? I have

Re: [HACKERS] pageinspect patch, for showing tuple data

2015-09-07 Thread Michael Paquier
On Sat, Sep 5, 2015 at 1:05 AM, Nikolay Shaplov wrote: > В письме от 4 сентября 2015 14:58:29 пользователь Michael Paquier написал: > > Documentation is missing, that would be good to have to understand what > > each function is intended to do. > > I were going to add documentation when this

Re: [HACKERS] PATCH: numeric timestamp in log_line_prefix

2015-09-07 Thread Alvaro Herrera
Jeff Davis wrote: > On Sun, 2015-03-22 at 19:47 +0100, Andres Freund wrote: > > On 2015-03-22 00:47:12 +0100, Tomas Vondra wrote: > > > from time to time I need to correlate PostgreSQL logs to other logs, > > > containing numeric timestamps - a prime example of that is pgbench. With > > > %t and

Re: [HACKERS] PATCH: numeric timestamp in log_line_prefix

2015-09-07 Thread Jeff Davis
On Mon, 2015-09-07 at 17:47 -0300, Alvaro Herrera wrote: > Jeff Davis wrote: > > On Sun, 2015-03-22 at 19:47 +0100, Andres Freund wrote: > > > On 2015-03-22 00:47:12 +0100, Tomas Vondra wrote: > > > > from time to time I need to correlate PostgreSQL logs to other logs, > > > > containing numeric

Re: [HACKERS] [patch] Proposal for \rotate in psql

2015-09-07 Thread David G. Johnston
On Mon, Sep 7, 2015 at 4:18 PM, Pavel Stehule wrote: > > > 2015-09-07 22:14 GMT+02:00 Greg Stark : > >> On Fri, Sep 4, 2015 at 5:08 PM, Daniel Verite >> wrote: >> > I'm not dead set on \rotate and suggested other names >> >

Re: [HACKERS] creating extension including dependencies

2015-09-07 Thread Petr Jelinek
On 2015-09-07 21:28, Petr Jelinek wrote: On 2015-09-07 21:09, Alvaro Herrera wrote: Andres Freund wrote: On 2015-09-07 20:56:50 +0200, Petr Jelinek wrote: Yes that sounds cleaner. Just as a side note, List is a Node and does have copy support (and we pass List as DefElem->arg from gram.y in

Re: [HACKERS] PATCH: numeric timestamp in log_line_prefix

2015-09-07 Thread Jeff Davis
> I wonder about this separate gettimeofday() call. We already have > formatted_log_time which is used for CSV logs and freeform log lines > (stderr/syslog); if we introduce a separate gettimeofday() call here, > and the user has %n in freeform log and CSV logging is active, the > timings will

Re: [HACKERS] PATCH: numeric timestamp in log_line_prefix

2015-09-07 Thread Alvaro Herrera
Jeff Davis wrote: > > I wonder about this separate gettimeofday() call. We already have > > formatted_log_time which is used for CSV logs and freeform log lines > > (stderr/syslog); if we introduce a separate gettimeofday() call here, > > and the user has %n in freeform log and CSV logging is

Re: [HACKERS] [patch] Proposal for \rotate in psql

2015-09-07 Thread Greg Stark
On Fri, Sep 4, 2015 at 5:08 PM, Daniel Verite wrote: > I'm not dead set on \rotate and suggested other names > previously in [1], but none of them seems decisively > superior. Fwiw I like \rotate. It's pretty clear what it means and it sounds similar to but not exactly

Re: [HACKERS] [patch] Proposal for \rotate in psql

2015-09-07 Thread Pavel Stehule
2015-09-07 22:14 GMT+02:00 Greg Stark : > On Fri, Sep 4, 2015 at 5:08 PM, Daniel Verite > wrote: > > I'm not dead set on \rotate and suggested other names > > previously in [1], but none of them seems decisively > > superior. > > > Fwiw I like \rotate.

Re: [HACKERS] Waits monitoring

2015-09-07 Thread Alexander Korotkov
On Mon, Sep 7, 2015 at 6:28 AM, Amit Kapila wrote: > On Sun, Sep 6, 2015 at 5:58 PM, Andres Freund wrote: > > > > On 2015-09-04 23:44:21 +0100, Simon Riggs wrote: > > > I see the need for both current wait information and for cumulative > > >

Re: [HACKERS] PATCH: numeric timestamp in log_line_prefix

2015-09-07 Thread Jeff Davis
On Sun, 2015-03-22 at 19:47 +0100, Andres Freund wrote: > On 2015-03-22 00:47:12 +0100, Tomas Vondra wrote: > > from time to time I need to correlate PostgreSQL logs to other logs, > > containing numeric timestamps - a prime example of that is pgbench. With > > %t and %m that's not quite trivial,

Re: [HACKERS] Horizontal scalability/sharding

2015-09-07 Thread Ahsan Hadi
I On Monday, September 7, 2015, Ashutosh Bapat < ashutosh.ba...@enterprisedb.com> wrote: > > > On Sat, Sep 5, 2015 at 4:22 AM, Ozgun Erdogan > wrote: > >> Hey Robert, >> >> Now the question is, where should the code that

Re: [HACKERS] creating extension including dependencies

2015-09-07 Thread Petr Jelinek
On 2015-09-02 17:31, Andres Freund wrote: On 2015-09-02 17:27:38 +0200, Andres Freund wrote: 1) Passing the list of parents through the cascade DefElem strikes me as incredibly ugly. For one the cascade option really should take a true/false type option on the C level (so you can do

Re: [HACKERS] Speed up Clog Access by increasing CLOG buffers

2015-09-07 Thread Alvaro Herrera
Andres Freund wrote: > On 2015-09-07 10:34:10 -0300, Alvaro Herrera wrote: > > I wonder if it would make sense to explore an idea that has been floated > > for years now -- to have pg_clog pages be allocated as part of shared > > buffers rather than have their own separate pool. That way, no

Re: [HACKERS] WIP: Rework access method interface

2015-09-07 Thread Alexander Korotkov
On Mon, Sep 7, 2015 at 9:17 PM, Petr Jelinek wrote: > On 2015-09-04 16:26, Alexander Korotkov wrote: > >> >> Attached patch is implementing this. It doesn't pretend to be fully >> correct implementation, but it should be enough for proof the concept. >> In this patch access

Re: [HACKERS] creating extension including dependencies

2015-09-07 Thread Andres Freund
On 2015-09-07 20:56:50 +0200, Petr Jelinek wrote: > Yes that sounds cleaner. Just as a side note, List is a Node and does have > copy support (and we pass List as DefElem->arg from gram.y in several > places). I know - but the list element in this case don't have copy support, no? You seem to

Re: [HACKERS] WIP: Rework access method interface

2015-09-07 Thread Petr Jelinek
On 2015-09-07 20:56, Alexander Korotkov wrote: On Mon, Sep 7, 2015 at 9:17 PM, Petr Jelinek

Re: [HACKERS] creating extension including dependencies

2015-09-07 Thread Andres Freund
On 2015-09-07 16:09:27 -0300, Alvaro Herrera wrote: > Andres Freund wrote: > > On 2015-09-07 20:56:50 +0200, Petr Jelinek wrote: > > > Yes that sounds cleaner. Just as a side note, List is a Node and does have > > > copy support (and we pass List as DefElem->arg from gram.y in several > > >

Re: [HACKERS] PATCH: numeric timestamp in log_line_prefix

2015-09-07 Thread Alvaro Herrera
> + case 'n': > + { > + struct timeval tv; > + charstrfbuf[128]; > + > + gettimeofday(, NULL); > +

Re: [HACKERS] creating extension including dependencies

2015-09-07 Thread Petr Jelinek
On 2015-09-07 21:09, Alvaro Herrera wrote: Andres Freund wrote: On 2015-09-07 20:56:50 +0200, Petr Jelinek wrote: Yes that sounds cleaner. Just as a side note, List is a Node and does have copy support (and we pass List as DefElem->arg from gram.y in several places). I know - but the list

Re: [HACKERS] creating extension including dependencies

2015-09-07 Thread Alvaro Herrera
Andres Freund wrote: > On 2015-09-07 20:56:50 +0200, Petr Jelinek wrote: > > Yes that sounds cleaner. Just as a side note, List is a Node and does have > > copy support (and we pass List as DefElem->arg from gram.y in several > > places). > > I know - but the list element in this case don't have

Re: [HACKERS] pgbench progress with timestamp

2015-09-07 Thread Jeff Janes
On Sun, Aug 23, 2015 at 4:25 AM, Fabien COELHO wrote: > > It is not easy to compare events on a pgbench runs (oops, the tps is down) > with for instance events in postgres log, so as to figure out what may have > cause a given glitch. > > This patches adds an option to

Re: [HACKERS] WIP: Access method extendability

2015-09-07 Thread Teodor Sigaev
Petr Jelinek wrote: On 2015-09-07 17:41, Teodor Sigaev wrote: Some notices: 1) create-am.3.patch.gz As I understand, you didn't add schema name to access method. Why? Suppose, if we implement SQL-like interface for AM screation/dropping then we should provide a schema qualification for

Re: [HACKERS] psql tabcomplete - minor bugfix - tabcomplete for SET ROLE TO xxx

2015-09-07 Thread Andres Freund
Hi, On 2015-09-02 22:58:21 +0200, Pavel Stehule wrote: > > Won't that mean that enum variables don't complete to default anymore? > no, it does > > #define Query_for_enum \ > " SELECT name FROM ( "\ > " SELECT unnest(enumvals) AS name "\ > "FROM pg_catalog.pg_settings "\ > " WHERE