Re: pg_checksums --help synopsis is quite long

2019-08-23 Thread Magnus Hagander
On Fri, Aug 23, 2019 at 8:49 AM Fabien COELHO wrote: > > Hello Peter, > > > With the additional functionality, the --help synopsis of pg_checksums > > has gotten quite long: > > > > pg_checksums enables, disables, or verifies data checksums in a > > PostgreSQL database cluster. > > > > Can we

Statement timeout in pg_rewind

2019-08-23 Thread Alexander Kukushkin
Hi, It is quite common to set a global statement_timeout to a few seconds (or minutes) in postgresql.conf in order to avoid hitting a production server with slow/bad queries. This value is applied to all connections in the system unless it is redefined per database, user, or explicitly changed in

Re: Allow to_date() and to_timestamp() to accept localized names

2019-08-23 Thread Juan José Santamaría Flecha
On Thu, Aug 22, 2019 at 9:38 PM Juan José Santamaría Flecha wrote: > > > > > Going through the current items in the wiki's todo list, I have been > > looking into: "Allow to_date () and to_timestamp () to accept > > localized month names". > > > > I have gone through a second take on this, trying

Re: (select query)/relation as first class citizen

2019-08-23 Thread Dent John
On 19 Aug 2019, at 15:16, Roman Pekar wrote:Hi, John,I think you've outlined the problem and possible solutions quite well. It's great to see that the goal might be not that far from implementing. Thanks for the prompt, Roman. I meant to have a bit of a play, and your message

Re: Why overhead of SPI is so large?

2019-08-23 Thread Konstantin Knizhnik
On 22.08.2019 18:56, Pavel Stehule wrote: čt 22. 8. 2019 v 17:51 odesílatel Konstantin Knizhnik mailto:k.knizh...@postgrespro.ru>> napsal: Some more information... First of all I found out that marking PL/pgSQL function as immutable significantly increase speed of its execution

Re: Comment in ginpostinglist.c doesn't match code

2019-08-23 Thread Masahiko Sawada
On Fri, Aug 23, 2019 at 7:05 AM Ashwin Agrawal wrote: > > On Thu, Aug 22, 2019 at 1:14 AM Heikki Linnakangas wrote: >> >> >> The patch also includes a little unit test module to test this without >> creating a 16 TB table. A whole new test module seems a bit like >> overkill just for this, but cl

Re: pg_checksums --help synopsis is quite long

2019-08-23 Thread Michael Paquier
On Fri, Aug 23, 2019 at 09:59:25AM +0200, Magnus Hagander wrote: > I think trigger is a bad word to use there, but I was already thinking to > suggest something like "pg_checksums manages or verifies checksums in a > PostgreSQL cluster", if that doesn't end up being too long? Doesn't "manage" some

Re: Why overhead of SPI is so large?

2019-08-23 Thread Pavel Stehule
pá 23. 8. 2019 v 11:05 odesílatel Konstantin Knizhnik < k.knizh...@postgrespro.ru> napsal: > > > On 22.08.2019 18:56, Pavel Stehule wrote: > > > > čt 22. 8. 2019 v 17:51 odesílatel Konstantin Knizhnik < > k.knizh...@postgrespro.ru> napsal: > >> Some more information... >> First of all I found out

backward compatibility of GSSENCRequest

2019-08-23 Thread Peter Eisentraut
As of PostgreSQL, an appropriately built client will initiate TCP/IP connections with these packets: 1. GSSENCRequest 2. SSLRequest 3. StartupMessage Older servers will respond to the first one with: FATAL: unsupported frontend protocol 1234.5680: server supports 2.0 to 3.0 libpq will then try

Re: WIP/PoC for parallel backup

2019-08-23 Thread Asim R P
Hi Asif Interesting proposal. Bulk of the work in a backup is transferring files from source data directory to destination. Your patch is breaking this task down in multiple sets of files and transferring each set in parallel. This seems correct, however, your patch is also creating a new proces

Re: io_uring support

2019-08-23 Thread Dmitry Dolgov
> On Mon, Aug 19, 2019 at 10:21 PM Andres Freund wrote: > > > For us the important part is probably that it's an asynchronious IO, that > > can > > work not only with O_DIRECT, but with also with buffered access. > > Note that while the buffered access does allow for some acceleration, it > curre

Re: Why overhead of SPI is so large?

2019-08-23 Thread Konstantin Knizhnik
On 23.08.2019 12:10, Pavel Stehule wrote: pá 23. 8. 2019 v 11:05 odesílatel Konstantin Knizhnik mailto:k.knizh...@postgrespro.ru>> napsal: On 22.08.2019 18:56, Pavel Stehule wrote: čt 22. 8. 2019 v 17:51 odesílatel Konstantin Knizhnik mailto:k.knizh...@postgrespro.ru>>

Re: [Proposal] Table-level Transparent Data Encryption (TDE) and Key Management Service (KMS)

2019-08-23 Thread Bruce Momjian
On Sat, Aug 17, 2019 at 01:52:17PM -0400, Stephen Frost wrote: > Being PostgreSQL, I would expect us to shoot for as much flexibility as > we possible, similar to what we've done for our ACL system where we > support down to a column-level (and row level with RLS). > > That's our target end-goal.

Re: Optimization of vacuum for logical replication

2019-08-23 Thread Konstantin Knizhnik
On 22.08.2019 6:13, Kyotaro Horiguchi wrote: Hello. At Wed, 21 Aug 2019 18:06:52 +0300, Konstantin Knizhnik wrote in <968fc591-51d3-fd74-8a55-40aa770ba...@postgrespro.ru> Ok, you convinced me that there are cases when people want to combine logical replication with streaming replication wit

Re: [HACKERS] [PATCH] pageinspect function to decode infomasks

2019-08-23 Thread Michael Paquier
On Fri, Aug 23, 2019 at 03:35:01PM +0900, Masahiko Sawada wrote: > Good idea. I've updated the doc update patch. Thanks. I have removed the output part as I am not sure that it is that helpful for the reader, and applied it down to v10 where the sections for function types have been introduced (s

Re: [Proposal] Table-level Transparent Data Encryption (TDE) and Key Management Service (KMS)

2019-08-23 Thread Stephen Frost
Greetings, * Bruce Momjian (br...@momjian.us) wrote: > On Sat, Aug 17, 2019 at 01:52:17PM -0400, Stephen Frost wrote: > > Being PostgreSQL, I would expect us to shoot for as much flexibility as > > we possible, similar to what we've done for our ACL system where we > > support down to a column-lev

Re: [HACKERS] [WIP] Effective storage of duplicates in B-tree index.

2019-08-23 Thread Anastasia Lubennikova
23.08.2019 7:33, Peter Geoghegan wrote: On Wed, Aug 21, 2019 at 10:19 AM Anastasia Lubennikova wrote: I'm going to look through the patch once more to update nbtxlog comments, where needed and answer to your remarks that are still left in the comments. Have you been using amcheck's rootdescend

Re: Why overhead of SPI is so large?

2019-08-23 Thread Pavel Stehule
pá 23. 8. 2019 v 13:21 odesílatel Konstantin Knizhnik < k.knizh...@postgrespro.ru> napsal: > > > On 23.08.2019 12:10, Pavel Stehule wrote: > > > > pá 23. 8. 2019 v 11:05 odesílatel Konstantin Knizhnik < > k.knizh...@postgrespro.ru> napsal: > >> >> >> On 22.08.2019 18:56, Pavel Stehule wrote: >> >>

Re: Cleanup isolation specs from unused steps

2019-08-23 Thread Asim R P
On Thu, Aug 22, 2019 at 12:47 AM Alvaro Herrera wrote: > > On 2019-Aug-21, Melanie Plageman wrote: > > > In Greenplum, we mainly add new tests to a separate isolation > > framework (called isolation2) which uses a completely different > > syntax. It doesn't use isolationtester at all. So, I haven'

Re: mingw32 floating point diff

2019-08-23 Thread Andrew Dunstan
On 8/20/19 8:59 AM, Peter Eisentraut wrote: > Running the regression tests on mingw32, I get the following diff in > circle.out: > > @@ -111,8 +111,8 @@ >WHERE (c1.f1 < c2.f1) AND ((c1.f1 <-> c2.f1) > 0) >ORDER BY distance, area(c1.f1), area(c2.f1); > five | one | two

Explain: Duplicate key "Workers" in JSON format

2019-08-23 Thread Pierre Giraud
Hi, I'm currently working on a tool to visualize an execution plan [1]. For those who know PEV, it's actually a fork of this great tool since it hasn't been active for more than 2 years. Among other things, I'd like to show information for the parallel queries. First of which is information about

Re: "ago" times on buildfarm status page

2019-08-23 Thread Andrew Dunstan
On 8/21/19 4:16 PM, Tom Lane wrote: > Andrew Dunstan writes: >> What I have done quickly is to store a measure of the clock skew. We >> already calculated it but we didn't store it. Initial indications are >> that only a few have significant skew. > Oh, I didn't know that the server had the abil

Re: [Proposal] Table-level Transparent Data Encryption (TDE) and Key Management Service (KMS)

2019-08-23 Thread Bruce Momjian
On Fri, Aug 23, 2019 at 07:45:22AM -0400, Stephen Frost wrote: > Greetings, > > * Bruce Momjian (br...@momjian.us) wrote: > > On Sat, Aug 17, 2019 at 01:52:17PM -0400, Stephen Frost wrote: > > > Being PostgreSQL, I would expect us to shoot for as much flexibility as > > > we possible, similar to w

Re: WIP/PoC for parallel backup

2019-08-23 Thread Ibrar Ahmed
On Fri, Aug 23, 2019 at 3:18 PM Asim R P wrote: > Hi Asif > > Interesting proposal. Bulk of the work in a backup is transferring files > from source data directory to destination. Your patch is breaking this > task down in multiple sets of files and transferring each set in parallel. > This see

Re: Explain: Duplicate key "Workers" in JSON format

2019-08-23 Thread Andrew Dunstan
On 8/23/19 8:47 AM, Pierre Giraud wrote: > "Plans": [ > { > "Node Type": "Sort", > "Parent Relationship": "Outer", > "Parallel Aware": false, > "Actual Startup Time": 1558.638, > "Actual Total Time": 2127.522, > "Actual Row

Re: mingw32 floating point diff

2019-08-23 Thread Tom Lane
Peter Eisentraut writes: > The circle.sql file already has SET extra_float_digits TO 0, and a few > other files have other settings with different values. Are we content > to use various numbers until it works in each case, or should we try to > use some consistency? The one in rules.sql doesn't

Hstore OID bigger than an integer

2019-08-23 Thread Roberto Mireles
Hello team, This is the first time I post here, if you can provide some help, would be much appreciated. I have an application that can not access the database due to OID value for hstore extension is bigger than an integer value. Application uses a NpgSql driver that only supports integer types

Re: Why overhead of SPI is so large?

2019-08-23 Thread Konstantin Knizhnik
On 23.08.2019 14:42, Pavel Stehule wrote: In reality it is not IMMUTABLE function. On second hand, there are lot of application that depends on this behave. It is well know trick how to reduce estimation errors related to JOINs. When immutable function has constant parameters, then it is

Re: [Proposal] Table-level Transparent Data Encryption (TDE) and Key Management Service (KMS)

2019-08-23 Thread Stephen Frost
Greetings, * Bruce Momjian (br...@momjian.us) wrote: > On Fri, Aug 23, 2019 at 07:45:22AM -0400, Stephen Frost wrote: > > Having listed out the feature set of each of the other major databases > > when it comes to TDE is exactly how we objectively look at what is being > > done in the industry, an

Re: XPRS

2019-08-23 Thread Tomas Vondra
On Thu, Aug 22, 2019 at 11:41:45AM +1200, Thomas Munro wrote: Hello, After rereading some old papers recently, I wanted to share some thoughts about XPRS and modern PostgreSQL. XPRS stood for "eXtended Postgres on RAID and Sprite", and was a research project done nearly three decades ago at Ber

Re: Hstore OID bigger than an integer

2019-08-23 Thread Alvaro Herrera
On 2019-Aug-23, Roberto Mireles wrote: > I have an application that can not access the database due to OID value for > hstore extension is bigger than an integer value. Application uses a NpgSql > driver that only supports integer types for OIDs. That's a bug in Npgsql. OIDs are unsigned. > I h

Re: WIP/PoC for parallel backup

2019-08-23 Thread Asif Rehman
On Fri, Aug 23, 2019 at 3:18 PM Asim R P wrote: > Hi Asif > > Interesting proposal. Bulk of the work in a backup is transferring files > from source data directory to destination. Your patch is breaking this > task down in multiple sets of files and transferring each set in parallel. > This see

Re: Hstore OID bigger than an integer

2019-08-23 Thread Tomas Vondra
On Fri, Aug 23, 2019 at 08:58:50AM -0500, Roberto Mireles wrote: Hello team, This is the first time I post here, if you can provide some help, would be much appreciated. I have an application that can not access the database due to OID value for hstore extension is bigger than an integer value.

Re: Cleanup isolation specs from unused steps

2019-08-23 Thread Alvaro Herrera
On 2019-Aug-23, Asim R P wrote: > As part of the fault injector patch set [1], I added a new "blocking" > keyword to isolation grammar so that a step can be declared as blocking. > See patch 0002-Add-syntax-to-declare-a-step-that-is-expected-to-block. One point to that implementation is that in t

Re: Optimize single tuple fetch from nbtree index

2019-08-23 Thread Anastasia Lubennikova
05.08.2019 14:34, Floris Van Nee wrote: I have one further question about these index offsets. There are several comments in master that indicate that it's impossible that an item moves 'left' on a page, if we continuously hold a pin on the page. For example, _bt_killitems has a comment like t

Re: pg_checksums --help synopsis is quite long

2019-08-23 Thread Fabien COELHO
Bonjour Michaël, It would like to keep "data checksums" in the output, You can do as you feel. I have decided that PostgreSQL is a mouthful, thus I'm rather using "Postgres". Changing that in one tool and not everything would of course be really silly. And if you want to bring up the ren

Re: WIP/PoC for parallel backup

2019-08-23 Thread Stephen Frost
Greetings, * Asif Rehman (asifr.reh...@gmail.com) wrote: > On Fri, Aug 23, 2019 at 3:18 PM Asim R P wrote: > > Interesting proposal. Bulk of the work in a backup is transferring files > > from source data directory to destination. Your patch is breaking this > > task down in multiple sets of fi

Re: WIP/PoC for parallel backup

2019-08-23 Thread Ibrar Ahmed
On Fri, Aug 23, 2019 at 10:26 PM Stephen Frost wrote: > Greetings, > > * Asif Rehman (asifr.reh...@gmail.com) wrote: > > On Fri, Aug 23, 2019 at 3:18 PM Asim R P wrote: > > > Interesting proposal. Bulk of the work in a backup is transferring > files > > > from source data directory to destinati

Re: obsoleting plpython2u and defaulting plpythonu to plpython3u

2019-08-23 Thread Tom Lane
Pavel Raiskup writes: > On Wednesday, April 25, 2018 12:17:05 AM CEST Peter Eisentraut wrote: >> On 4/24/18 07:13, Pavel Raiskup wrote: >>> What's the expected future migration path from plpython2 to plpython3 in >>> such cases? I'm thinking about rewrite of the docs and creating some >>> scripti

Re: Hstore OID bigger than an integer

2019-08-23 Thread Merlin Moncure
On Fri, Aug 23, 2019 at 9:26 AM Roberto Mireles wrote: > > Hello team, > > This is the first time I post here, if you can provide some help, would be > much appreciated. > > I have an application that can not access the database due to OID value for > hstore extension is bigger than an integer v

Re: Email to hackers for test coverage

2019-08-23 Thread Ahsan Hadi
The subject of the email may be bit misleading however this is really good exercise to analyse the current code of Postgres regression suite using GCOV and then adding test cases incrementally to increase the test coverage. On Thu, 22 Aug 2019 at 2:46 PM, movead...@highgo.ca wrote: > Hello hacke

Re: WIP/PoC for parallel backup

2019-08-23 Thread Ahsan Hadi
On Fri, 23 Aug 2019 at 10:26 PM, Stephen Frost wrote: > Greetings, > > * Asif Rehman (asifr.reh...@gmail.com) wrote: > > On Fri, Aug 23, 2019 at 3:18 PM Asim R P wrote: > > > Interesting proposal. Bulk of the work in a backup is transferring > files > > > from source data directory to destinati

Re: WIP/PoC for parallel backup

2019-08-23 Thread Stephen Frost
Greetings, * Ahsan Hadi (ahsan.h...@gmail.com) wrote: > On Fri, 23 Aug 2019 at 10:26 PM, Stephen Frost wrote: > > I would expect you to quickly want to support compression on the server > > side, before the data is sent across the network, and possibly > > encryption, and so it'd likely make sens

Re: Email to hackers for test coverage

2019-08-23 Thread Ibrar Ahmed
On Thu, Aug 22, 2019 at 2:46 PM movead...@highgo.ca wrote: > Hello hackers, > > One of the area that didn't get much attention in the community > recently is analysing and increasing the code coverage of > PostgreSQL regession test suite. I have started working on the > code coverage by running t

Re: Optimize single tuple fetch from nbtree index

2019-08-23 Thread Peter Geoghegan
On Fri, Aug 23, 2019 at 10:14 AM Anastasia Lubennikova wrote: > Though, I got interested in the comment inconsistency you have found. > I added debug message into this code branch of the patch and was able to > see it in regression.diffs after 'make check': > Speaking of your patch, it seems that

Re: Asymmetric partition-wise JOIN

2019-08-23 Thread Thomas Munro
On Fri, Aug 23, 2019 at 4:05 AM Kohei KaiGai wrote: > We can consider the table join ptable X t1 above is equivalent to: > (ptable_p0 + ptable_p1 + ptable_p2) X t1 > = (ptable_p0 X t1) + (ptable_p1 X t1) + (ptable_p2 X t1) > It returns an equivalent result, however, rows are already reduced by H

Re: [Proposal] Table-level Transparent Data Encryption (TDE) and Key Management Service (KMS)

2019-08-23 Thread Bruce Momjian
On Fri, Aug 23, 2019 at 10:35:17AM -0400, Stephen Frost wrote: > > Agreed. The features of other databases are a clear source for what we > > should consider and run through the useful/reasonable filter. > > Following on from that- when other databases don't have something that > we're thinking a

Re: Comment in ginpostinglist.c doesn't match code

2019-08-23 Thread Alexander Korotkov
On Thu, Aug 22, 2019 at 11:14 AM Heikki Linnakangas wrote: > While merging Greenplum with 9.4, we ran into problems with the GIN > posting list encoding, because Greenplum sometimes uses ItemPointers > with offset numbers up to 32768. The GIN posting list code was written > with the assumption tha

Re: [Proposal] Table-level Transparent Data Encryption (TDE) and Key Management Service (KMS)

2019-08-23 Thread Stephen Frost
Greetings, * Bruce Momjian (br...@momjian.us) wrote: > On Fri, Aug 23, 2019 at 10:35:17AM -0400, Stephen Frost wrote: > > Following on from that- when other databases don't have something that > > we're thinking about implementing, maybe we should be contemplating if > > it really makes sense as a

Re: Does TupleQueueReaderNext() really need to copy its result?

2019-08-23 Thread Thomas Munro
On Thu, Aug 22, 2019 at 12:08 PM Thomas Munro wrote: > Given that shm_mq.c proudly documents that it avoids copying the data > on the receiving side (unless it has to reconstruct a message that was > split up), and given that it promises that the pointed-to data remains > valid until your next cal

pg_basebackup is taking an unusually long time with Postgres 11.3

2019-08-23 Thread andy andy
Hi Folks, I am having trouble setting up replication with Postgres 11.3. pg_basebackup is taking an unusually long time for an small Postgres database. Anything wrong in my configuration or anything I could do to speed up pg_basebackup? I recently upgraded form Postgres 9.2.1. Using a similar p

Re: Cleanup isolation specs from unused steps

2019-08-23 Thread Michael Paquier
(Re-adding pgsql-hackers) On Fri, Aug 23, 2019 at 05:28:35PM +0530, Asim R P wrote: > Both the patches look good to me, thank you. +1 to removing dry-run and > tracking unused steps. Thanks, both have been committed. There have been issues with the isolation tests of logical decoding I have tak