Re: [HACKERS] Hash Indexes

2016-11-08 Thread Robert Haas
On Mon, Nov 7, 2016 at 9:51 PM, Amit Kapila wrote: >> Both the places _hash_squeezebucket() and _hash_splitbucket can use >> this optimization irrespective of rest of the patch. I will prepare a >> separate patch for these and send along with main patch after some >>

Re: [HACKERS] Improving RLS planning

2016-11-08 Thread Robert Haas
On Thu, Nov 3, 2016 at 6:23 PM, Tom Lane wrote: >> I think that ordering might be sub-optimal if you had a mix of >> leakproof quals and security quals and the cost of some security quals >> were significantly higher than the cost of some other quals. Perhaps >> all leakproof

Re: [HACKERS] Radix tree for character conversion

2016-11-08 Thread Peter Eisentraut
On 10/31/16 12:11 PM, Daniel Gustafsson wrote: > I took a small stab at doing some cleaning of the Perl scripts, mainly around > using the more modern (well, modern as in +15 years old) form for open(..), > avoiding global filehandles for passing scalar references and enforcing use > strict. Some

Re: [HACKERS] Add support for SRF and returning composites to pl/tcl

2016-11-08 Thread Tom Lane
Jim Nasby writes: > Hrm, I completely spaced on the fact that composite returns are > essentially the same thing as trigger returns. ISTM we should be able to > use the same code for both. IIRC those magic elements could end up in > any SPI result, so that handling

Re: [HACKERS] C based plugins, clocks, locks, and configuration variables

2016-11-08 Thread Jim Nasby
On 11/3/16 7:14 PM, Craig Ringer wrote: 1) getting microseconds (or nanoseconds) from UTC epoch in a plugin GetCurrentIntegerTimestamp() Since you're serializing generation anyway you might want to just forgo the timestamp completely. It's not like the values your generating are globally

Re: [HACKERS] Row level security implementation in Foreign Table in Postgres

2016-11-08 Thread Stephen Frost
Tom, all, * Tom Lane (t...@sss.pgh.pa.us) wrote: > Robert Haas writes: > > On Wed, Nov 2, 2016 at 10:46 PM, Sounak Chakraborty > > wrote: > >> But my doubt is why this feature is not enabled in case of Foreign Table. > >> (ALTER FOREIGN TABLE doesn't

[HACKERS] unchecked chdir warning

2016-11-08 Thread Jeff Janes
When compiling with --enable-profiling using: gcc version 5.4.0 20160609 (Ubuntu 5.4.0-6ubuntu1~16.04.2) I get the warning: ipc.c: In function 'proc_exit': ipc.c:137:3: warning: ignoring return value of 'chdir', declared with attribute warn_unused_result [-Wunused-result]

Re: [HACKERS] Copying Permissions

2016-11-08 Thread Stephen Frost
Corey, * Corey Huinker (corey.huin...@gmail.com) wrote: > Craig's post yesterday about exposing syntax for disabling indexes reminded > me of another feature I think we're lacking in areas where we have to do > table management. > > The issue is to create a *something* that has the exact

Re: [HACKERS] unchecked chdir warning

2016-11-08 Thread Tom Lane
Jeff Janes writes: > I get the warning: > ipc.c: In function 'proc_exit': > ipc.c:137:3: warning: ignoring return value of 'chdir', declared with > attribute warn_unused_result [-Wunused-result] >chdir(gprofDirName); >^ > I don't know if there is anything useful

Re: [HACKERS] Fix bug in handling of dropped columns in pltcl triggers

2016-11-08 Thread Tom Lane
Jim Nasby writes: > On 11/4/16 4:28 PM, Tom Lane wrote: >> It's possible that it'd make sense for pltcl_trigger_handler to ignore >> empty-string column names in the returned list, so that the behavior >> with stupid trigger functions would be a bit more forgiving; but

Re: [HACKERS] Improving RLS planning

2016-11-08 Thread Tom Lane
Stephen Frost writes: > * Tom Lane (t...@sss.pgh.pa.us) wrote: >> * Since the planner is now depending on Query.hasRowSecurity to be set >> whenever there are any securityQuals, I put in an Assert about that, >> and promptly found three places in prepjointree.c and the

Re: [HACKERS] Danger of automatic connection reset in psql

2016-11-08 Thread Oleksandr Shulgin
On Mon, Nov 7, 2016 at 9:31 PM, Jim Nasby wrote: > On 11/4/16 4:04 AM, Oleksandr Shulgin wrote: > >> The psql process even exits with an error code 2, which might be not >> that expected. We could stop reading the file and reset connection >> afterwards, but this is

Re: [HACKERS] C based plugins, clocks, locks, and configuration variables

2016-11-08 Thread Clifford Hammerschmidt
Hi Jim, The values are still globally unique. The odds of a collision are very very low. Two instances with the same node_id generating on the same millisecond (in their local view of time) have a 1:2^34 chance of collision. node_id only repeats every 256 machines in a cluster (assuming you're

Re: [HACKERS] Incorrect overflow check condition for WAL segment size

2016-11-08 Thread Robert Haas
On Tue, Nov 8, 2016 at 1:01 AM, Michael Paquier wrote: > On Tue, Nov 8, 2016 at 2:33 PM, Kuntal Ghosh > wrote: >> Either the comment is wrongly written or the check for overflow >> condition has to be fixed. Assuming the overflow check

Re: [HACKERS] Logical Replication WIP

2016-11-08 Thread Peter Eisentraut
Review of v7 0003-Add-PUBLICATION-catalogs-and-DDL.patch: This appears to address previous reviews and is looking pretty solid. I have some comments that are easily addressed: [still from previous review] The code for OCLASS_PUBLICATION_REL in getObjectIdentityParts() does not fill in objname

[HACKERS] Make pg_basebackup -x stream the default

2016-11-08 Thread Magnus Hagander
Per some discussions with a number of different people at pgconfeu, here is a patch that changes the default mode of pg_basebackup to be streaming the wal, as this is what most users would want -- and those that don't want it have to make other changes as well. Doing the "most safe" thing by

Re: [HACKERS] C based plugins, clocks, locks, and configuration variables

2016-11-08 Thread Clifford Hammerschmidt
Looking closer at the bit math, I screwed it up it should be 64 bits time, 6 bit uuid version, 8 node, 8 seq, and the rest random ... which is 42 bits of random. I'll find the code in a bit. -- Clifford Hammerschmidt, P.Eng. On Tue, Nov 8, 2016 at 9:42 AM, Clifford Hammerschmidt <

Re: [HACKERS] [PATCH] Reload SSL certificates on SIGHUP

2016-11-08 Thread Andreas Karlsson
On 11/08/2016 01:22 PM, Michael Banck wrote: Thanks! I couldn't find furhter faults in my testing. I guess the question what to do about this on Windows is possibly still open, but as I am not familiar with the Windows port at all I've marked it Ready for Committer for now. Thanks again for

Re: [HACKERS] Write Ahead Logging for Hash Indexes

2016-11-08 Thread Jeff Janes
On Sat, Sep 24, 2016 at 10:00 PM, Amit Kapila wrote: > On Fri, Sep 23, 2016 at 5:34 PM, Amit Kapila > wrote: > > > > I think here I am slightly wrong. For the full page writes, it do use > > RBM_ZERO_AND_LOCK mode to read the page and for such

Re: [HACKERS] Fix bug in handling of dropped columns in pltcl triggers

2016-11-08 Thread Tom Lane
Jim Nasby writes: > On 11/4/16 4:28 PM, Tom Lane wrote: >> My proposal therefore is for SPI_fnumber to ignore (not match to) >> dropped columns, and to remove any caller-side attisdropped tests that >> thereby become redundant. > Yeah, SPI users certainly shouldn't need

Re: [HACKERS] Logical Replication WIP

2016-11-08 Thread Peter Eisentraut
On 11/4/16 9:00 AM, Andres Freund wrote: > + > + The pg_publication_rel catalog contains > + mapping between tables and publications in the database. This is many to > + many mapping. > + > > I wonder if we shouldn't abstract this a bit away from relations to > allow other objects to be

Re: [HACKERS] WIP: About CMake v2

2016-11-08 Thread Peter Eisentraut
On 9/17/16 1:21 PM, Yury Zhuravlev wrote: > Now, I published the first version of the patch. I tried this out. Because of some file moves in initdb and pg_basebackup, the build fails: [ 74%] Linking C executable initdb Undefined symbols for architecture x86_64: "_fsync_pgdata", referenced

Re: [HACKERS] Hash Indexes

2016-11-08 Thread Robert Haas
On Mon, Nov 7, 2016 at 9:51 PM, Amit Kapila wrote: > [ new patches ] Attached is yet another incremental patch with some suggested changes. + * This expects that the caller has acquired a cleanup lock on the target + * bucket (primary page of a bucket) and it is

Re: [HACKERS] WAL logging problem in 9.4.3?

2016-11-08 Thread Michael Paquier
On Wed, Nov 9, 2016 at 5:39 AM, Robert Haas wrote: > On Thu, Feb 4, 2016 at 7:24 AM, Heikki Linnakangas wrote: >> I dropped the ball on this one back in July, so here's an attempt to revive >> this thread. >> >> I spent some time fixing the remaining

Re: [HACKERS] pg_dump, pg_dumpall and data durability

2016-11-08 Thread Michael Paquier
On Wed, Nov 9, 2016 at 8:18 AM, Tom Lane wrote: > Robert Haas writes: >> First question: Do we even want this? Generally, when a program >> writes to a file, we rely on the operating system to decide when that >> data should be written back to disk.

Re: [HACKERS] pg_dump, pg_dumpall and data durability

2016-11-08 Thread Michael Paquier
On Wed, Nov 9, 2016 at 5:48 AM, Robert Haas wrote: > Kyotaro Horiguchi set this patch to "Ready for Committer" in the > CommitFest application, but that seems entirely premature to me > considering that v2 has had no review at all, or at least not that I > see on this

Re: [HACKERS] C based plugins, clocks, locks, and configuration variables

2016-11-08 Thread Craig Ringer
On 9 Nov. 2016 02:48, "Clifford Hammerschmidt" wrote: > > Looking closer at the bit math, I screwed it up it should be 64 bits time, 6 bit uuid version, 8 node, 8 seq, and the rest random ... which is 42 bits of random. I'll find the code in a bit. Huh, so that's what

Re: [HACKERS] WIP: About CMake v2

2016-11-08 Thread Craig Ringer
On 9 Nov. 2016 06:37, "Yury Zhuravlev" wrote: > >> When I run cmake without options, it seems to do opportunistic feature >> checking. For example, it turns on OpenSSL or Python support if it can >> find it, otherwise it turns it off. We need this to be

Re: [HACKERS] SERIALIZABLE with parallel query

2016-11-08 Thread Peter Geoghegan
On Tue, Nov 8, 2016 at 1:51 PM, Thomas Munro wrote: > Currently we don't generate parallel plans in SERIALIZABLE. What > problems need to be solved to be able to do that? FWIW, parallel CREATE INDEX works at SERIALIZABLE isolation level by specially asking the

Re: [HACKERS] pg_dump, pg_dumpall and data durability

2016-11-08 Thread Tom Lane
Robert Haas writes: > First question: Do we even want this? Generally, when a program > writes to a file, we rely on the operating system to decide when that > data should be written back to disk. We have to override that > distinction for things internal to PostgreSQL

Re: [HACKERS] Patch to implement pg_current_logfile() function

2016-11-08 Thread Robert Haas
On Thu, Nov 3, 2016 at 7:34 PM, Karl O. Pinc wrote: > To me, the CURRENT_LOG_FILENAME symbol should contain the name > of the current log file. It does not. The CURRENT_LOG_FILENAME symbol > holds the name of the file which itself contains the name of > the log file(s) being

Re: [HACKERS] commitfest 2016-11 status summary

2016-11-08 Thread Michael Paquier
On Wed, Nov 9, 2016 at 10:53 AM, Robert Haas wrote: > Well, then it should be marked "Waiting on Author" or "Needs Review", > not "Ready for Committer". > > Or maybe just "Returned with Feedback", if the reporter hasn't poked > his head up for a few weeks. Since yesterday

Re: [HACKERS] Do we need use more meaningful variables to replace 0 in catalog head files?

2016-11-08 Thread Hao Lee
yes, i agree with you. These catalogs are not modified often. As your said, the pg_proc modified often, therefore, there are another issues, the dependency between these system catalogs and system views. it's hard to gain maintenance the consistency between these catalogs and views. It's need more

Re: [HACKERS] Bug in comparison of empty jsonb arrays to scalars

2016-11-08 Thread Michael Paquier
On Wed, Nov 9, 2016 at 8:31 AM, Nikita Glukhov wrote: > Hi hackers. > > While working on jsonbstatistics, I found the following bug: > an empty jsonb array is considered to be lesser than any scalar, > but it is expected that objects > arrays > scalars. Sources? Does the

Re: [HACKERS] Radix tree for character conversion

2016-11-08 Thread Daniel Gustafsson
> On 08 Nov 2016, at 17:37, Peter Eisentraut > wrote: > > On 10/31/16 12:11 PM, Daniel Gustafsson wrote: >> I took a small stab at doing some cleaning of the Perl scripts, mainly around >> using the more modern (well, modern as in +15 years old) form for

Re: [HACKERS] Minor code improvement to postgresGetForeignJoinPaths

2016-11-08 Thread Tatsuro Yamada
On 2016/11/04 0:29, Robert Haas wrote: Committed. Thanks! Tatsuro Yamada NTT Open Source Software Center -- 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] commitfest 2016-11 status summary

2016-11-08 Thread Haribabu Kommi
Hi All, The commitfest status summary after one week of progress: Needs review: 78 Waiting on author: 16 Ready for Commiter: 19 Commited: 28 Moved to next CF: 0 Rejected: 3 Returned with feedback: 3 TOTAL: 147 Overall progress of completion - 23%. week-1 progress of completion - 9%. There

Re: [HACKERS] pg_sequence catalog

2016-11-08 Thread Andreas Karlsson
Review of the pg_sequences view. This seems like a useful addition to me, making life easier for administrators and monitoring tools. While there is already a view in information_schema it is missing cache_size and last_value. = Functional review - The patch applies and passes the test

Re: [HACKERS] pgbench - allow backslash continuations in \set expressions

2016-11-08 Thread Robert Haas
On Tue, Nov 8, 2016 at 5:33 AM, Fabien COELHO wrote: > I do not think that having both inferred continuations and explicit > backslash continuations is desirable, it should be one or the other. +1. My vote is for backslash continuations. Inferred continuations require you

[HACKERS] Bug in comparison of empty jsonb arrays to scalars

2016-11-08 Thread Nikita Glukhov
Hi hackers. While working on jsonbstatistics, I found the following bug: an empty jsonb array is considered to be lesser than any scalar, but it is expected that objects > arrays > scalars. # select '[]'::jsonb < 'null'::jsonb; ?column? -- t (1 row) Attached patch contains: 1. bug

Re: [HACKERS] commitfest 2016-11 status summary

2016-11-08 Thread Robert Haas
On Sun, Nov 6, 2016 at 3:33 AM, Michael Paquier wrote: > On Fri, Nov 4, 2016 at 12:36 AM, Robert Haas wrote: >> On Tue, Nov 1, 2016 at 3:48 PM, Haribabu Kommi >> wrote: >> https://commitfest.postgresql.org/11/604/ -

Re: [HACKERS] WIP: About CMake v2

2016-11-08 Thread Craig Ringer
On 9 November 2016 at 10:12, Michael Paquier wrote: > On Wed, Nov 9, 2016 at 7:54 AM, Craig Ringer > wrote: >> On 9 Nov. 2016 06:37, "Yury Zhuravlev" wrote: >>> This approach I see only in Postgres project and

Re: [HACKERS] Do we need use more meaningful variables to replace 0 in catalog head files?

2016-11-08 Thread Craig Ringer
On 9 November 2016 at 10:20, Hao Lee wrote: > yes, i agree with you. These catalogs are not modified often. As your said, > the pg_proc modified often, therefore, there are another issues, the > dependency between these system catalogs and system views. it's hard to gain >

Re: [HACKERS] Do we need use more meaningful variables to replace 0 in catalog head files?

2016-11-08 Thread Robert Haas
On Mon, Nov 7, 2016 at 9:10 PM, Michael Paquier wrote: > On Tue, Nov 8, 2016 at 10:57 AM, Hao Lee wrote: >> It's a tedious work to figure out these numbers real meaning. for example, >> if i want to know the value of '71' represent what it is. I

Re: RV: [HACKERS] Compilation warning on 9.5

2016-11-08 Thread Robert Haas
On Mon, Nov 7, 2016 at 2:34 PM, Vicky Vergara wrote: > Hello, > > Posting an update to this issue (which by the way also shows up on 9.6) > > Maybe this information is useful for extension developers (that have all > the warnings flags on while developing using GNUC) >

Re: [HACKERS] patch proposal

2016-11-08 Thread Venkata B Nagothi
Attached is the 2nd version of the patch with some enhancements. *Scenario 2 :* > > Generates Errors, Hints when the specified recovery target is prior to the > backup's current position (xid, time and lsn). This behaviour is integrated > with the parameters

Re: [HACKERS] WIP: About CMake v2

2016-11-08 Thread Michael Paquier
On Wed, Nov 9, 2016 at 7:54 AM, Craig Ringer wrote: > On 9 Nov. 2016 06:37, "Yury Zhuravlev" wrote: >> This approach I see only in Postgres project and not fully understood. >> Can you explain me more what reasons led to this approach? >

Re: [HACKERS] Typo in event_trigger.c

2016-11-08 Thread Michael Paquier
On Wed, Nov 9, 2016 at 5:35 AM, Robert Haas wrote: > Committed. Thanks. -- Michael -- 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] [bug fix] Cascading standby cannot catch up and get stuck emitting the same message repeatedly

2016-11-08 Thread Robert Haas
On Thu, Aug 25, 2016 at 10:33 PM, Tsunakawa, Takayuki wrote: > The processing went as follows. > > 1. node1's timeline is 140. It wrote a WAL record at the end of WAL segment > 117. The WAL record didn't fit the last page, so it was split across > segments 117

Re: [HACKERS] WIP: About CMake v2

2016-11-08 Thread Yury Zhuravlev
Hello. Peter Eisentraut wrote: I tried this out. Because of some file moves in initdb and pg_basebackup, the build fails: Yes, I need rebase patch to latest master. I do it as soon as possible. Also I have some new achievements. I suggest you use git format-patch to produce patches. This

[HACKERS] Re: [HACKERS] Re: [PATCH] Tab completion for ALTER TYPE … RENAME VALUE …

2016-11-08 Thread Robert Haas
On Tue, Nov 8, 2016 at 8:53 AM, Dagfinn Ilmari Mannsåker wrote: > Thank you very much. I just looked at the patch again and realised the > completion of "TO" after RENAME VALUE can be merged with the one > for RENAME ATTRIBUTE . Attached is an updated and patch Committed.

Re: [HACKERS] Remove "Source Code" column from \df+ ?

2016-11-08 Thread Robert Haas
On Wed, Oct 12, 2016 at 1:48 PM, Peter Eisentraut wrote: > On 10/12/16 11:16 AM, Tom Lane wrote: >> I'm not sure that Peter was voting for retaining "internal name", but >> personally I prefer that to deleting prosrc entirely, so +1. > > I'm not sure what the

[HACKERS] pg_serial early wraparound

2016-11-08 Thread Thomas Munro
Hi hackers, The SLRU managed by predicate.c can wrap around and overwrite data if you have more than 1 billion active XIDs. That's because when SSI was implemented, slru.c was limited to four digit segment names, which implied a page limit that wasn't enough for pg_serial to have space for every

Re: [HACKERS] Remove "Source Code" column from \df+ ?

2016-11-08 Thread Robert Haas
On Tue, Nov 8, 2016 at 4:18 PM, Tom Lane wrote: > Robert Haas writes: >> There is still an open CommitFest entry for this patch, which is >> marked "Ready for Committer", but it looks to me like there's no >> consensus position here. Different people

Re: [HACKERS] WAL logging problem in 9.4.3?

2016-11-08 Thread Robert Haas
On Thu, Feb 4, 2016 at 7:24 AM, Heikki Linnakangas wrote: > I dropped the ball on this one back in July, so here's an attempt to revive > this thread. > > I spent some time fixing the remaining issues with the prototype patch I > posted earlier, and rebased that on top of current

Re: [HACKERS] Typo in event_trigger.c

2016-11-08 Thread Robert Haas
On Tue, Nov 8, 2016 at 8:28 AM, Michael Paquier wrote: > Hi all, > > I just bumped into the following: > --- a/src/backend/commands/event_trigger.c > +++ b/src/backend/commands/event_trigger.c > @@ -742,7 +742,7 @@ EventTriggerCommonSetup(Node *parsetree, > > /* >

Re: [HACKERS] Re: [PATCH] Tab completion for ALTER TYPE … RENAME VALUE …

2016-11-08 Thread Dagfinn Ilmari Mannsåker
Robert Haas writes: > On Tue, Nov 8, 2016 at 8:53 AM, Dagfinn Ilmari Mannsåker > wrote: >> Thank you very much. I just looked at the patch again and realised the >> completion of "TO" after RENAME VALUE can be merged with the one >> for RENAME

Re: [HACKERS] Remove "Source Code" column from \df+ ?

2016-11-08 Thread Tom Lane
Robert Haas writes: > There is still an open CommitFest entry for this patch, which is > marked "Ready for Committer", but it looks to me like there's no > consensus position here. Different people have different preferences, > and every option that is somebody's first

[HACKERS] SERIALIZABLE with parallel query

2016-11-08 Thread Thomas Munro
Hi hackers, Currently we don't generate parallel plans in SERIALIZABLE. What problems need to be solved to be able to do that? I'm probably steamrolling over a ton of subtleties and assumptions here, but it occurred to me that a first step might be something like this: 1. Hand the leader's

Re: [HACKERS] pg_dump, pg_dumpall and data durability

2016-11-08 Thread Robert Haas
On Mon, Nov 7, 2016 at 7:52 PM, Michael Paquier wrote: > On Tue, Nov 8, 2016 at 1:24 AM, Albe Laurenz wrote: >> The patch does not apply, I had to change the hunk for >> src/include/common/file_utils.h. > > Yes, the patch has rotten a bit

Re: [HACKERS] WIP: About CMake v2

2016-11-08 Thread Tom Lane
Craig Ringer writes: > On 9 Nov. 2016 06:37, "Yury Zhuravlev" wrote: >> This approach I see only in Postgres project and not fully understood. >> Can you explain me more what reasons led to this approach? > It's predictable. The default

Re: [HACKERS] Do we need use more meaningful variables to replace 0 in catalog head files?

2016-11-08 Thread Tom Lane
Robert Haas writes: > Most of these files don't have that many entries, and they're not > modified that often. The elephant in the room is pg_proc.h, which is > huge, frequently-modified, and hard to decipher. But I think that's > going to need more surgery than just

Re: [HACKERS] Password identifiers, protocol aging and SCRAM protocol

2016-11-08 Thread Victor Wagner
On Tue, 18 Oct 2016 16:35:27 +0900 Michael Paquier wrote: Hi > Attached is a rebased patch set for SCRAM, with the following things: > - 0001, moving all the SHA2 functions to src/common/ and introducing a > PG-like interface. No actual changes here. It seems, that

Re: [HACKERS] Do we need use more meaningful variables to replace 0 in catalog head files?

2016-11-08 Thread Michael Paquier
On Wed, Nov 9, 2016 at 1:44 PM, Tom Lane wrote: > I don't think we need "named constants", especially not > manually-maintained ones. The thing that would help in pg_proc.h is for > numeric type OIDs to be replaced by type names. We talked awhile back > about introducing

Re: [HACKERS] [PATCH] Reload SSL certificates on SIGHUP

2016-11-08 Thread Michael Paquier
On Wed, Nov 9, 2016 at 3:48 AM, Andreas Karlsson wrote: > On 11/08/2016 01:22 PM, Michael Banck wrote: >> >> Thanks! I couldn't find furhter faults in my testing. I guess the >> question what to do about this on Windows is possibly still open, but as >> I am not familiar with

Re: [HACKERS] Password identifiers, protocol aging and SCRAM protocol

2016-11-08 Thread Michael Paquier
On Wed, Nov 9, 2016 at 3:13 PM, Victor Wagner wrote: > On Tue, 18 Oct 2016 16:35:27 +0900 > Michael Paquier wrote: > > Hi >> Attached is a rebased patch set for SCRAM, with the following things: >> - 0001, moving all the SHA2 functions to

Re: [HACKERS] WAL logging problem in 9.4.3?

2016-11-08 Thread Michael Paquier
On Wed, Nov 9, 2016 at 9:27 AM, Michael Paquier wrote: > On Wed, Nov 9, 2016 at 5:39 AM, Robert Haas wrote: >> On Thu, Feb 4, 2016 at 7:24 AM, Heikki Linnakangas wrote: >>> I dropped the ball on this one back in July, so here's

Re: [HACKERS] Dumb mistakes in WalSndWriteData()

2016-11-08 Thread Michael Paquier
On Mon, Oct 31, 2016 at 10:54 PM, Andres Freund wrote: > On 2016-10-31 09:44:16 -0400, Robert Haas wrote: >> On Mon, Oct 31, 2016 at 4:59 AM, Andres Freund wrote: >> > I^Wsomebody appears to have made a number of dumb mistakes in >> > WalSndWriteData(),

[HACKERS] Adding in docs the meaning of pg_stat_replication.sync_state

2016-11-08 Thread Michael Paquier
Hi all, The documentation does not explain at all what means "sync" or "async" on pg_stat_replication. The paragraph "Planning for high availability" mentions "catchup" and "streaming", but it does not say that users can refer to it directly in pg_stat_replication. Thoughts about the patch

Re: [HACKERS] Password identifiers, protocol aging and SCRAM protocol

2016-11-08 Thread Victor Wagner
On Wed, 9 Nov 2016 15:23:11 +0900 Michael Paquier wrote: > > (This is about patch 0007, not 0001) > Thanks, you are right. That's not good as-is. So this basically means > that the characters here should be from 32 to 127 included. Really, most important is to

Re: [HACKERS] Improving RLS planning

2016-11-08 Thread Stephen Frost
Tom, * Tom Lane (t...@sss.pgh.pa.us) wrote: > Dean Rasheed writes: > > On 25 October 2016 at 22:58, Tom Lane wrote: > >> The alternative I'm now thinking about pursuing is to get rid of the > >> conversion of RLS quals to subqueries. Instead, we

Re: [HACKERS] Re: [COMMITTERS] pgsql: Change the way that LWLocks for extensions are allocated.

2016-11-08 Thread Ashutosh Sharma
Hi, > I had also thought about it while preparing patch, but I couldn't find > any clear use case. I think it could be useful during development of > a module, but not sure if it is worth to add a target. I think there > is no harm in adding such a target, but lets take an opinion from >

Re: [HACKERS] Specifying the log file name of pgbench -l option

2016-11-08 Thread Fabien COELHO
[ ... v4 ] I checked. It works as expected. I have no more comments. If its okay with Fabien, we can mark it ready for committer. Patch applies, compiles (including the documentation), make check ok and features works for me. Code could be a little simpler, but it is okay. I've switched

[HACKERS] A bug in UCS_to_most.pl

2016-11-08 Thread Kyotaro HORIGUCHI
Hello, I was surprised to find that src/backend/utils/mb/Unicode/Makefile got changed (3a47c70) to have download feature of character conversion authority files. It seems fine according to the previous discussion as the commnet of that is saying. So, I did 'make maintainer-clean; make' on it but

Re: [HACKERS] pgbench - allow backslash continuations in \set expressions

2016-11-08 Thread Fabien COELHO
Hello Rafia, Please keep copying to the list. Though I find the first version of this patch acceptable in terms that it would be helpful on enhancing the readability of expressions as you mentioned. However, the second version is not clear as I mentioned before also, there has to be detailed

Re: [HACKERS] Streaming basebackups vs pg_stat_tmp

2016-11-08 Thread Magnus Hagander
On Tue, Nov 8, 2016 at 1:28 PM, David Steele wrote: > Hi Magnus, > > On 11/7/16 2:07 PM, Magnus Hagander wrote: > >> On Sat, Oct 29, 2016 at 4:12 PM, Michael Paquier >> Indeed, giving the attached for REL9_6_STABLE. You could as well have >> a test for pg_stat_tmp

Re: [HACKERS] Radix tree for character conversion

2016-11-08 Thread Kyotaro HORIGUCHI
Hello, this is the revising patch applies on top of the previous patch. Differences on map files are enormous but useless for discussion so they aren't included in this. (but can be generated) This still doesn't remove three .txt/.xml files since it heavily bloats the patch. I'm planning that

Re: [HACKERS] Fix checkpoint skip logic on idle systems by tracking LSN progress

2016-11-08 Thread Kyotaro HORIGUCHI
Hello, At Tue, 8 Nov 2016 14:45:59 +0900, Michael Paquier wrote in > On Tue, Nov 1, 2016 at 8:31 PM, Kyotaro HORIGUCHI > wrote: > > Could you let me struggle a bit

Re: [HACKERS] Improving executor performance

2016-11-08 Thread Andres Freund
Hi, On 2016-11-04 15:25:58 -0700, Doug Doole wrote: > On 07/13/2016 06:18 PM, Andres Freund wrote: > > Attached (in patch 0003) is a proof-of-concept implementing an > > expression evalution framework that doesn't use recursion. Instead > > ExecInitExpr2 computes a number of 'steps' necessary to

Re: [HACKERS] PassDownLimitBound for ForeignScan/CustomScan [take-2]

2016-11-08 Thread Jeevan Chalke
Hi, I have reviewed the patch. Patch applies cleanly. make/"make install"/"make check" all are fine. I too see a good performance in execution time when LIMIT is pushed with cursor query in postgres_fdw at execution time However here are few comments on the changes: 1. ps_numTuples is

Re: [HACKERS] [PATCH] Reload SSL certificates on SIGHUP

2016-11-08 Thread Michael Banck
Hi, On Mon, Nov 07, 2016 at 02:36:00AM +0100, Andreas Karlsson wrote: > Thanks for the review! I have fixed all your feedback in the attached > patch. Thanks! I couldn't find furhter faults in my testing. I guess the question what to do about this on Windows is possibly still open, but as I am

Re: [HACKERS] Fix checkpoint skip logic on idle systems by tracking LSN progress

2016-11-08 Thread David Steele
On 10/5/16 7:18 AM, Michael Paquier wrote: Note: I am moving this patch to next CF. And I am back on it more seriously... And I am taking back what I said upthread. I looked at the v12 that Horiguchi-san has written, and that seems correct to me. So I have squashed everything into a single

Re: [HACKERS] Streaming basebackups vs pg_stat_tmp

2016-11-08 Thread David Steele
Hi Magnus, On 11/7/16 2:07 PM, Magnus Hagander wrote: On Sat, Oct 29, 2016 at 4:12 PM, Michael Paquier Indeed, giving the attached for REL9_6_STABLE. You could as well have a test for pg_stat_tmp but honestly that's not worth it. One thing I have noticed is that the patch does not

Re: [HACKERS] Re: [COMMITTERS] pgsql: Change the way that LWLocks for extensions are allocated.

2016-11-08 Thread Amit Kapila
On Tue, Nov 8, 2016 at 4:23 PM, Ashutosh Sharma wrote: > Hi, > >> I had also thought about it while preparing patch, but I couldn't find >> any clear use case. I think it could be useful during development of >> a module, but not sure if it is worth to add a target. I

Re: [HACKERS] Fwd: Re: [CORE] temporal tables (SQL2011)

2016-11-08 Thread Robert Haas
On Sun, Nov 6, 2016 at 4:08 PM, Stefan Scheid wrote: > are there plans to introduce temporal tables? > I don't know of anyone who is actually working on it, but I agree that it would probably attract some users if we did. -- Robert Haas EnterpriseDB:

Re: [HACKERS] Quorum commit for multiple synchronous replication.

2016-11-08 Thread Michael Paquier
On Tue, Nov 8, 2016 at 12:25 AM, Masahiko Sawada wrote: > On Tue, Oct 25, 2016 at 10:35 PM, Michael Paquier > wrote: >> + if (SyncRepConfig->sync_method == SYNC_REP_PRIORITY) >> + return SyncRepGetSyncStandbysPriority(am_sync); >> +

Re: [HACKERS] Fix checkpoint skip logic on idle systems by tracking LSN progress

2016-11-08 Thread Michael Paquier
On Tue, Nov 8, 2016 at 9:32 PM, David Steele wrote: > I had a bit of trouble parsing this paragraph: > > [...] > > So I did a little reworking: > > [...] > > If that still says what you think it should, then I believe it is clearer. Thanks! I have included your suggestion.

Re: [HACKERS] Re: [PATCH] Tab completion for ALTER TYPE … RENAME VALUE …

2016-11-08 Thread Dagfinn Ilmari Mannsåker
Artur Zakirov writes: > Hello, Hi Artur, > 2016-09-12 16:16 GMT+03:00 Dagfinn Ilmari Mannsåker : >> >> I've added it to the 2016-11 commit fest: >> https://commitfest.postgresql.org/11/795/ >> >> - ilmari > > I've tested your patch. [...] > It seems

Re: [HACKERS] Radix tree for character conversion

2016-11-08 Thread Daniel Gustafsson
> On 08 Nov 2016, at 12:21, Kyotaro HORIGUCHI > wrote: > > Hello, this is the revising patch applies on top of the previous > patch. > > ... > > Finally the attached patch contains most of (virtually all of) > Daniel's suggestion and some modification by

Re: [HACKERS] [PATCH] Reload SSL certificates on SIGHUP

2016-11-08 Thread Michael Paquier
On Tue, Nov 8, 2016 at 9:22 PM, Michael Banck wrote: > Thanks! I couldn't find furhter faults in my testing. I guess the > question what to do about this on Windows is possibly still open, but as > I am not familiar with the Windows port at all I've marked it Ready for

[HACKERS] Typo in event_trigger.c

2016-11-08 Thread Michael Paquier
Hi all, I just bumped into the following: --- a/src/backend/commands/event_trigger.c +++ b/src/backend/commands/event_trigger.c @@ -742,7 +742,7 @@ EventTriggerCommonSetup(Node *parsetree, /* * Filter list of event triggers by command tag, and copy them into our -* memory context.