Attach to shared memory after fork()

2021-04-27 Thread 邱宇航(烛远)
Fork is an expensive operation[1]. The major cost is the mm(VMA PTE...) copy. ARM is especially weak on fork, which will invalid TLB entries one by one, and this is an expensive operation[2]. We could easily got 100% CPU on ARM machine. We also meet fork problem in x86, but not as serious as arm

Re: [BUG] "FailedAssertion" reported when streaming in logical replication

2021-04-27 Thread Amit Kapila
On Tue, Apr 27, 2021 at 12:22 PM Dilip Kumar wrote: > > On Tue, Apr 27, 2021 at 12:05 PM Amit Kapila wrote: > > > > Can't we use 'txns_by_base_snapshot_lsn' list for this purpose? It is > > > > ensured in ReorderBufferSetBaseSnapshot that we always assign > > > > base_snapshot to a top-level tran

Re: ALTER TABLE .. DETACH PARTITION CONCURRENTLY

2021-04-27 Thread Amit Langote
Thanks for the updated patch. I've been reading it, but I noticed a bug in 8aba9322511f, which I thought you'd want to know to make a note of when committing this one. So we decided in 8aba9322511f that it is okay to make the memory context in which a transient partdesc is allocated a child of Po

Re: SQL-standard function body

2021-04-27 Thread Peter Eisentraut
On 18.04.21 23:33, Tom Lane wrote: ... BTW, a dependency loop is also possible without using this feature, by abusing default-value expressions: create function f1(x int, y int) returns int language sql as 'select $1 + $2'; create function f2(x int, y int default f1(1,2)) returns int language sq

Re: [PATCH] Re: pg_identify_object_as_address() doesn't support pg_event_trigger oids

2021-04-27 Thread Michael Paquier
On Tue, Apr 27, 2021 at 07:16:25AM +0200, Joel Jacobson wrote: > I've added a test at the end of event_trigger.sql, > reusing the three event triggers already in existence, > just before they are dropped. Cool, thanks. I have been looking at it and I'd still like to cross-check the output data of

Re: [HACKERS] logical decoding of two-phase transactions

2021-04-27 Thread vignesh C
On Wed, Apr 21, 2021 at 12:13 PM Peter Smith wrote: > > On Tue, Apr 20, 2021 at 3:45 PM Peter Smith wrote: > > > > Please find attached the latest patch set v73`* > > > > Differences from v72* are: > > > > * Rebased to HEAD @ today (required because v72-0001 no longer applied > > cleanly) > > >

Re: Bug fix for tab completion of ALTER TABLE ... VALIDATE CONSTRAINT ...

2021-04-27 Thread Aleksander Alekseev
Hi David, > I noticed that $subject completes with already valid constraints, > please find attached a patch that fixes it. I noticed that there are > other places constraints can be validated, but didn't check whether > similar bugs exist there yet. There was a typo in the patch ("... and and no

Re: TRUNCATE on foreign table

2021-04-27 Thread Fujii Masao
On 2021/04/27 15:02, Bharath Rupireddy wrote: On Tue, Apr 27, 2021 at 11:19 AM Fujii Masao wrote: In docs v4 patch, I think we can combine below two lines into a single line: + supported by the foreign data wrapper, see . You mean "supported by the foreign data wrapper "? I was th

CREATE COLLATION - check for duplicate options and error out if found one

2021-04-27 Thread Bharath Rupireddy
Hi, While reviewing [1], I found that the CREATE COLLATION doesn't throw an error if duplicate options are specified, see [2] for testing a few cases on HEAD. This may end up accepting some of the weird cases, see [2]. It's against other option checking code in the server where the duplicate optio

Re: Bug fix for tab completion of ALTER TABLE ... VALIDATE CONSTRAINT ...

2021-04-27 Thread Aleksander Alekseev
Hi hackers, > Otherwise the patch passes all the tests and works as expected I've noticed there is no tab completion for ALTER TABLE xxx ADD. Here is an alternative version of the patch that fixes this as well. Not sure if this should be in the same commit though. -- Best regards, Aleksander Al

Re: Better sanity checking for message length words

2021-04-27 Thread Aleksander Alekseev
Hi Tom, > ... > Given the small number of complaints to date, I'm hesitant to > back-patch this: if there's anybody out there with valid use for > long messages that I didn't think should be long, this might break > things for them. But I think it'd be reasonable to sneak it into > v14, since we'

Re: Attach to shared memory after fork()

2021-04-27 Thread Andrew Dunstan
On 4/26/21 11:56 PM, 邱宇航(烛远) wrote: > Fork is an expensive operation[1]. The major cost is the mm(VMA > PTE...) copy. > > ARM is especially weak on fork, which will invalid TLB entries one by > one, and this is an expensive operation[2]. We could easily got 100% > CPU on ARM machine. We also meet

Re: Enhanced error message to include hint messages for redundant options error

2021-04-27 Thread Bharath Rupireddy
On Tue, Apr 27, 2021 at 6:23 AM Bharath Rupireddy wrote: > > On Mon, Apr 26, 2021 at 9:10 PM Bharath Rupireddy > wrote: > > > > I found another problem with collationcmds.c is that it doesn't error > > out if some of the options are specified more than once, something > > like below. I think the

Re: [BUG] "FailedAssertion" reported when streaming in logical replication

2021-04-27 Thread Dilip Kumar
On Tue, Apr 27, 2021 at 12:55 PM Amit Kapila wrote: > > On Tue, Apr 27, 2021 at 12:22 PM Dilip Kumar wrote: > > > > On Tue, Apr 27, 2021 at 12:05 PM Amit Kapila > > wrote: > > > > > Can't we use 'txns_by_base_snapshot_lsn' list for this purpose? It is > > > > > ensured in ReorderBufferSetBaseSn

Re: Replication slot stats misgivings

2021-04-27 Thread Amit Kapila
On Tue, Apr 27, 2021 at 8:58 AM Masahiko Sawada wrote: > > On Tue, Apr 27, 2021 at 11:45 AM Amit Kapila wrote: > > > > > > Sawada-San, I would like to go ahead with your > > "Use-HTAB-for-replication-slot-statistics" unless you think otherwise? > > I agree that it's better to use the stats collec

Re: Asynchronous Append on postgres_fdw nodes.

2021-04-27 Thread Etsuro Fujita
On Mon, Apr 26, 2021 at 3:01 PM Andrey V. Lepikhov wrote: > While studying the capabilities of AsyncAppend, I noticed an > inconsistency with the cost model of the optimizer: > Here I see two problems: > 1. Cost of an AsyncAppend is the same as cost of an Append. But > execution time of the Async

Re: Asynchronous Append on postgres_fdw nodes.

2021-04-27 Thread Etsuro Fujita
On Mon, Apr 26, 2021 at 7:35 PM Andrey V. Lepikhov wrote: > Small mistake i found. If no tuple was received from a foreign > partition, explain shows that we never executed node. For example, > if we have 0 tuples in f1 and 100 tuples in f2: > > Query: > EXPLAIN (ANALYZE, VERBOSE, TIMING OFF, COST

Re: [PATCH] Re: pg_identify_object_as_address() doesn't support pg_event_trigger oids

2021-04-27 Thread Joel Jacobson
On Tue, Apr 27, 2021, at 09:48, Michael Paquier wrote: > On Tue, Apr 27, 2021 at 07:16:25AM +0200, Joel Jacobson wrote: > > I've added a test at the end of event_trigger.sql, > > reusing the three event triggers already in existence, > > just before they are dropped. > > Cool, thanks. I have been

RE: Forget close an open relation in ReorderBufferProcessTXN()

2021-04-27 Thread osumi.takami...@fujitsu.com
On Tuesday, April 20, 2021 12:07 PM Amit Langote wrote: > On Sat, Apr 17, 2021 at 1:30 PM Amit Kapila > wrote: > > On Fri, Apr 16, 2021 at 11:24 PM Andres Freund > > wrote:> > This made me take a brief look at pgoutput.c - maybe I am > > missing > > > something, but how is the following not a m

Result Cache node shows per-worker info even for workers not launched

2021-04-27 Thread Amit Khandekar
Hi, If planned parallel workers do not get launched, the Result Cache plan node shows all-0 stats for each of those workers: tpch=# set max_parallel_workers TO 0; SET tpch=# explain analyze select avg(l_discount) from orders, lineitem where l_orderkey = o_orderkey and o_orderdate < date '

Re: wal stats questions

2021-04-27 Thread Fujii Masao
On 2021/04/26 10:11, Masahiro Ikeda wrote: On 2021/04/23 16:30, Fujii Masao wrote: On 2021/04/23 10:25, Andres Freund wrote: Hi, On 2021-04-23 09:26:17 +0900, Masahiro Ikeda wrote: On 2021/04/23 0:36, Andres Freund wrote: On Thu, Apr 22, 2021, at 06:42, Fujii Masao wrote: On 2021/04/

Add reset information to pg_stat_statements_info

2021-04-27 Thread Seino Yuki
Hi. This is a proposal for a new feature in pg_stat_statements extension. I think we need to add some statistics to pg_stat_statements_info view. "pg_stat_statements_info.stats_reset" will only be logged if "pg_statements_reset()" or "pg_statements_reset(0,0,0)" is executed. How about changing

Re: Skip temporary table schema name from explain-verbose output.

2021-04-27 Thread Ashutosh Bapat
On Tue, Apr 27, 2021 at 12:23 PM Amul Sul wrote: > > > > How about using an explain filter to replace the unstable text > > pg_temp_3 to pg_temp_N instead of changing it in the core? Following > > are the existing explain filters: explain_filter, > > explain_parallel_append, explain_analyze_withou

Re: Skip temporary table schema name from explain-verbose output.

2021-04-27 Thread Bharath Rupireddy
On Tue, Apr 27, 2021 at 6:59 PM Ashutosh Bapat wrote: > > On Tue, Apr 27, 2021 at 12:23 PM Amul Sul wrote: > > > > > > How about using an explain filter to replace the unstable text > > > pg_temp_3 to pg_temp_N instead of changing it in the core? Following > > > are the existing explain filters:

Re: Performance degradation of REFRESH MATERIALIZED VIEW

2021-04-27 Thread Tomas Vondra
On 4/27/21 7:34 AM, Masahiko Sawada wrote: On Tue, Apr 27, 2021 at 8:07 AM Andres Freund wrote: Hi, On 2021-04-26 23:59:17 +0200, Tomas Vondra wrote: On 4/26/21 9:27 PM, Andres Freund wrote: On 2021-04-26 15:31:02 +0200, Tomas Vondra wrote: I'm not sure what to do about this :-( I don't

Re: Attach to shared memory after fork()

2021-04-27 Thread Tom Lane
"=?UTF-8?B?6YKx5a6H6IiqKOeDm+i/nCk=?=" writes: > Fork is an expensive operation[1]. Yeah, it's not hugely cheap. > So I propose to remove shared buffers from postmaster and shmat them > after fork. This proposal seems moderately insane. In the first place, it introduces failure modes we could

Re: Performance degradation of REFRESH MATERIALIZED VIEW

2021-04-27 Thread Bharath Rupireddy
On Tue, Apr 27, 2021 at 7:13 PM Tomas Vondra wrote: > What Andres is suggesting (I think) is to modify ExecInsert() to pass a > valid bistate to table_tuple_insert, instead of just NULL, and store the > vmbuffer in it. Not sure how to identify when inserting more than just a > single row, though .

Re: Performance degradation of REFRESH MATERIALIZED VIEW

2021-04-27 Thread Justin Pryzby
On Tue, Apr 27, 2021 at 03:43:07PM +0200, Tomas Vondra wrote: > On 4/27/21 7:34 AM, Masahiko Sawada wrote: > > On Tue, Apr 27, 2021 at 8:07 AM Andres Freund wrote: > > > On 2021-04-26 23:59:17 +0200, Tomas Vondra wrote: > > > > On 4/26/21 9:27 PM, Andres Freund wrote: > > > > > On 2021-04-26 15:31

Re: ALTER TABLE .. DETACH PARTITION CONCURRENTLY

2021-04-27 Thread Amit Langote
On Tue, Apr 27, 2021 at 4:34 PM Amit Langote wrote: > Thanks for the updated patch. I've been reading it, but I noticed a > bug in 8aba9322511f, which I thought you'd want to know to make a note > of when committing this one. > > So we decided in 8aba9322511f that it is okay to make the memory >

Should we document the behaviour of TRUNCATE skipping repeated relations?

2021-04-27 Thread Bharath Rupireddy
Hi, The TRUNCATE command currently skips processing repeated relations (see if (list_member_oid(relids, myrelid)) continue; in ExecuteTruncate) because the same relation can't be truncated more than once as it will be under "use" during the txn. For instance, in the following use cases 1) TRUNCATE

Re: Replication slot stats misgivings

2021-04-27 Thread Amit Kapila
On Tue, Apr 27, 2021 at 5:40 PM Amit Kapila wrote: > > On Tue, Apr 27, 2021 at 8:58 AM Masahiko Sawada wrote: > > I have pushed this patch and seeing one buildfarm failure: > https://buildfarm.postgresql.org/cgi-bin/show_log.pl?nm=mandrill&dt=2021-04-27%2009%3A23%3A14 > > starting permutation:

Re: Better sanity checking for message length words

2021-04-27 Thread Tom Lane
Aleksander Alekseev writes: > I'm having slight issues applying your patch to the `master` branch. > Is it the right target? [ scratches head ... ] The patch still applies perfectly cleanly for me, using either "patch" or "git apply". > Regarding the idea, I think extra checks are a good thing

Re: Replication slot stats misgivings

2021-04-27 Thread Masahiko Sawada
On Tue, Apr 27, 2021 at 11:29 PM Amit Kapila wrote: > > On Tue, Apr 27, 2021 at 5:40 PM Amit Kapila wrote: > > > > On Tue, Apr 27, 2021 at 8:58 AM Masahiko Sawada > > wrote: > > > > I have pushed this patch and seeing one buildfarm failure: > > https://buildfarm.postgresql.org/cgi-bin/show_log.

Re: Performance degradation of REFRESH MATERIALIZED VIEW

2021-04-27 Thread Masahiko Sawada
On Tue, Apr 27, 2021 at 10:43 PM Tomas Vondra wrote: > > > > On 4/27/21 7:34 AM, Masahiko Sawada wrote: > > On Tue, Apr 27, 2021 at 8:07 AM Andres Freund wrote: > >> > >> Hi, > >> > >> On 2021-04-26 23:59:17 +0200, Tomas Vondra wrote: > >>> On 4/26/21 9:27 PM, Andres Freund wrote: > On 2021-

Re: Performance degradation of REFRESH MATERIALIZED VIEW

2021-04-27 Thread Masahiko Sawada
On Wed, Apr 28, 2021 at 12:26 AM Masahiko Sawada wrote: > > On Tue, Apr 27, 2021 at 10:43 PM Tomas Vondra > wrote: > > > > > > > > On 4/27/21 7:34 AM, Masahiko Sawada wrote: > > > On Tue, Apr 27, 2021 at 8:07 AM Andres Freund wrote: > > >> > > >> Hi, > > >> > > >> On 2021-04-26 23:59:17 +0200, T

Re: ALTER TABLE .. DETACH PARTITION CONCURRENTLY

2021-04-27 Thread Alvaro Herrera
On 2021-Apr-27, Amit Langote wrote: > On Tue, Apr 27, 2021 at 4:34 PM Amit Langote wrote: > I think we may need a separate context for partdesc_nodetached, likely > with the same kludges as rd_pdcxt. Maybe the first problem will go > away with that as well. Ooh, seems I completely misunderstoo

Re: Since '2001-09-09 01:46:40'::timestamp microseconds are lost when extracting epoch

2021-04-27 Thread Tom Lane
I wrote: >> Perhaps it'd be worth documenting that you can get the standard >> astronomical definition of Julian date by transposing to time zone UTC-12 >> before converting. BTW ... I'd first thought that the way to do this was to rotate to time zone UTC+12. I convinced myself on two separate da

Re: SQL-standard function body

2021-04-27 Thread Tom Lane
Peter Eisentraut writes: > On 18.04.21 23:33, Tom Lane wrote: >> The actual use-case for that seems pretty thin, so we never bothered >> to worry about it before. But if we're going to build loop-breaking >> logic to handle function body dependencies, it should deal with this >> too. I think tha

Re: Performance degradation of REFRESH MATERIALIZED VIEW

2021-04-27 Thread Tomas Vondra
On 4/27/21 5:44 PM, Masahiko Sawada wrote: On Wed, Apr 28, 2021 at 12:26 AM Masahiko Sawada wrote: On Tue, Apr 27, 2021 at 10:43 PM Tomas Vondra wrote: On 4/27/21 7:34 AM, Masahiko Sawada wrote: On Tue, Apr 27, 2021 at 8:07 AM Andres Freund wrote: Hi, On 2021-04-26 23:59:17 +0200, To

Re: ALTER TABLE .. DETACH PARTITION CONCURRENTLY

2021-04-27 Thread Alvaro Herrera
This v3 handles things as you suggested and works correctly AFAICT. I'm going to add some more tests cases to verify the behavior in the scenarios you showed, and get them to run under cache-clobber options to make sure it's good. Thanks! -- Álvaro Herrera Valdivia, Chile >From 145ed63c43

Re: Addition of authenticated ID to pg_stat_activity

2021-04-27 Thread Stephen Frost
Greetings, * Michael Paquier (mich...@paquier.xyz) wrote: > On Mon, Apr 26, 2021 at 03:21:46PM -0400, Stephen Frost wrote: > > * Andres Freund (and...@anarazel.de) wrote: > >> I'm getting a bit worried about the incremental increase in > >> pg_stat_activity width - it's probably by far the view th

Re: Addition of authenticated ID to pg_stat_activity

2021-04-27 Thread Justin Pryzby
On Tue, Apr 27, 2021 at 09:59:18AM +0900, Michael Paquier wrote: > On Mon, Apr 26, 2021 at 03:21:46PM -0400, Stephen Frost wrote: > > * Andres Freund (and...@anarazel.de) wrote: > >> I'm getting a bit worried about the incremental increase in > >> pg_stat_activity width - it's probably by far the v

Re: Performance degradation of REFRESH MATERIALIZED VIEW

2021-04-27 Thread Andres Freund
Hi, On 2021-04-28 00:44:47 +0900, Masahiko Sawada wrote: > On Wed, Apr 28, 2021 at 12:26 AM Masahiko Sawada > wrote: > > > What Andres is suggesting (I think) is to modify ExecInsert() to pass a > > > valid bistate to table_tuple_insert, instead of just NULL, and store the > > > vmbuffer in it.

Re: Addition of authenticated ID to pg_stat_activity

2021-04-27 Thread Andres Freund
Hi, On 2021-04-27 12:40:29 -0400, Stephen Frost wrote: > So, what fields are people really looking at when querying > pg_stat_activity interactively? User, database, pid, last query, > transaction start, query start, state, wait event info, maybe backend > xmin/xid? I doubt most people looking a

Release 14 Beta 1

2021-04-27 Thread Andrew Dunstan
Greetings. The Release Management Team (Pete Geoghegan, Michael Paquier and myself) proposes that the date of the Beta 1 release will be **Thursday May 20, 2021**, which aligns with past practice. cheers andrew -- Andrew Dunstan EDB: https://www.enterprisedb.com

Re: ALTER TABLE .. DETACH PARTITION CONCURRENTLY

2021-04-27 Thread Alvaro Herrera
On 2021-Apr-27, Alvaro Herrera wrote: > This v3 handles things as you suggested and works correctly AFAICT. I'm > going to add some more tests cases to verify the behavior in the > scenarios you showed, and get them to run under cache-clobber options to > make sure it's good. Yep, it seems to wo

Re: wal stats questions

2021-04-27 Thread Masahiro Ikeda
On 2021/04/27 21:56, Fujii Masao wrote: > > > On 2021/04/26 10:11, Masahiro Ikeda wrote: >> >> First patch has only the changes for pg_stat_wal view. >> ("v6-0001-performance-improvements-of-reporting-wal-stats-without-introducing-a-new-variable.patch") >> > > +    pgWalUsage.wal_records

Re: Unresolved repliaction hang and stop problem.

2021-04-27 Thread Alvaro Herrera
On 2021-Apr-14, Amit Kapila wrote: > On Tue, Apr 13, 2021 at 1:18 PM Krzysztof Kois > wrote: > > > > Hello, > > After upgrading the cluster from 10.x to 13.1 we've started getting a > > problem describe pgsql-general: > > https://www.postgresql.org/message-id/8bf8785c-f47d-245c-b6af-80dc1eed40db

Re: Bug fix for tab completion of ALTER TABLE ... VALIDATE CONSTRAINT ...

2021-04-27 Thread David Fetter
On Tue, Apr 27, 2021 at 12:33:25PM +0300, Aleksander Alekseev wrote: > Hi David, > > > I noticed that $subject completes with already valid constraints, > > please find attached a patch that fixes it. I noticed that there are > > other places constraints can be validated, but didn't check whether

Error in libpq docs for target_session_attrs, prefer-standby mode

2021-04-27 Thread Greg Nancarrow
Hi, I spotted an error in the development version documentation for libpq's connection parameter "target_session_attrs" (34.1.2 Parameter Key Words). In the description for the "prefer-standby" mode, it says "... but if none of the listed hosts is a standby server, try again in all mode". There is

Re: Replication slot stats misgivings

2021-04-27 Thread Amit Kapila
On Tue, Apr 27, 2021 at 8:28 PM Masahiko Sawada wrote: > > On Tue, Apr 27, 2021 at 11:29 PM Amit Kapila wrote: > > > > On Tue, Apr 27, 2021 at 5:40 PM Amit Kapila wrote: > > > > > > > I am not sure if the timeout happened because the machine is slow or > > is it in any way related to code. I am

Re: Replication slot stats misgivings

2021-04-27 Thread vignesh C
On Wed, Apr 28, 2021 at 8:28 AM Amit Kapila wrote: > > On Tue, Apr 27, 2021 at 8:28 PM Masahiko Sawada wrote: > > > > On Tue, Apr 27, 2021 at 11:29 PM Amit Kapila > > wrote: > > > > > > On Tue, Apr 27, 2021 at 5:40 PM Amit Kapila > > > wrote: > > > > > > > > > > I am not sure if the timeout h

Re: [PATCH] Re: pg_identify_object_as_address() doesn't support pg_event_trigger oids

2021-04-27 Thread Michael Paquier
On Tue, Apr 27, 2021 at 02:33:36PM +0200, Joel Jacobson wrote: > I've successfully tested > fix_event_trigger_pg_identify_object_as_address3.patch. Thanks. Applied down to 9.6 then. -- Michael signature.asc Description: PGP signature

Re: Unresolved repliaction hang and stop problem.

2021-04-27 Thread Amit Kapila
On Wed, Apr 28, 2021 at 6:48 AM Alvaro Herrera wrote: > > On 2021-Apr-14, Amit Kapila wrote: > > > On Tue, Apr 13, 2021 at 1:18 PM Krzysztof Kois > > wrote: > > > > > > Hello, > > > After upgrading the cluster from 10.x to 13.1 we've started getting a > > > problem describe pgsql-general: > > >

Re: Replication slot stats misgivings

2021-04-27 Thread Amit Kapila
On Tue, Apr 27, 2021 at 11:02 AM vignesh C wrote: > > On Tue, Apr 27, 2021 at 9:48 AM vignesh C wrote: > > > > Attached patch has the changes to update statistics during > spill/stream which prevents the statistics from being lost during > interrupt. > void -UpdateDecodingStats(LogicalDecodingC

Re: Skip temporary table schema name from explain-verbose output.

2021-04-27 Thread Amul Sul
On Tue, Apr 27, 2021 at 7:08 PM Bharath Rupireddy wrote: > > On Tue, Apr 27, 2021 at 6:59 PM Ashutosh Bapat > wrote: > > > > On Tue, Apr 27, 2021 at 12:23 PM Amul Sul wrote: > > > > > > > > How about using an explain filter to replace the unstable text > > > > pg_temp_3 to pg_temp_N instead of c

Re: Replication slot stats misgivings

2021-04-27 Thread vignesh C
On Wed, Apr 28, 2021 at 8:59 AM Amit Kapila wrote: > > On Tue, Apr 27, 2021 at 11:02 AM vignesh C wrote: > > > > On Tue, Apr 27, 2021 at 9:48 AM vignesh C wrote: > > > > > > > Attached patch has the changes to update statistics during > > spill/stream which prevents the statistics from being los

Re: Replication slot stats misgivings

2021-04-27 Thread Masahiko Sawada
On Wed, Apr 28, 2021 at 12:29 PM Amit Kapila wrote: > > On Tue, Apr 27, 2021 at 11:02 AM vignesh C wrote: > > > > On Tue, Apr 27, 2021 at 9:48 AM vignesh C wrote: > > > > > > > Attached patch has the changes to update statistics during > > spill/stream which prevents the statistics from being lo

Re: Replication slot stats misgivings

2021-04-27 Thread vignesh C
On Wed, Apr 28, 2021 at 9:37 AM Masahiko Sawada wrote: > > On Wed, Apr 28, 2021 at 12:29 PM Amit Kapila wrote: > > > > On Tue, Apr 27, 2021 at 11:02 AM vignesh C wrote: > > > > > > On Tue, Apr 27, 2021 at 9:48 AM vignesh C wrote: > > > > > > > > > > Attached patch has the changes to update stat

Re: PATCH: logical_work_mem and logical streaming of large in-progress transactions

2021-04-27 Thread Amit Kapila
Tom Lane has raised a complaint on pgsql-commiters [1] about one of the commits related to this work [2]. The new member wrasse is showing Warning: "/export/home/nm/farm/studio64v12_6/HEAD/pgsql.build/../pgsql/src/backend/replication/logical/reorderbuffer.c", line 2510: Warning: Likely null pointe

Re: PATCH: logical_work_mem and logical streaming of large in-progress transactions

2021-04-27 Thread Dilip Kumar
On Wed, Apr 28, 2021 at 11:00 AM Amit Kapila wrote: > > Tom Lane has raised a complaint on pgsql-commiters [1] about one of > the commits related to this work [2]. The new member wrasse is showing > Warning: > > "/export/home/nm/farm/studio64v12_6/HEAD/pgsql.build/../pgsql/src/backend/replication/

Re: Since '2001-09-09 01:46:40'::timestamp microseconds are lost when extracting epoch

2021-04-27 Thread Thomas Munro
On Wed, Apr 28, 2021 at 3:56 AM Tom Lane wrote: > Of course Wikipedia has been known to contain errors, but now > I'm inclined to think I blew this. Anyone want to check my work? I tried a couple of examples not from Wikipedia. First, from the definition of Julian days as used by astronomers[1]

pg_hba.conf.sample wording improvement

2021-04-27 Thread Peter Eisentraut
I propose the attached patch to shake up the wording in the connection type section of pg_hba.conf.sample a bit. After the hostgssenc part was added on, the whole thing became a bit wordy, and it's also a bit inaccurate for example in that the current wording for "host" appears to say that it

Re: Replication slot stats misgivings

2021-04-27 Thread Amit Kapila
On Wed, Apr 28, 2021 at 9:37 AM Masahiko Sawada wrote: > > On Wed, Apr 28, 2021 at 12:29 PM Amit Kapila wrote: > > > > On Tue, Apr 27, 2021 at 11:02 AM vignesh C wrote: > > > > > > On Tue, Apr 27, 2021 at 9:48 AM vignesh C wrote: > > > > > > > > > > Attached patch has the changes to update stat

Re: pg_hba.conf.sample wording improvement

2021-04-27 Thread Laurenz Albe
On Wed, 2021-04-28 at 07:51 +0200, Peter Eisentraut wrote: > I propose the attached patch to shake up the wording in the connection > type section of pg_hba.conf.sample a bit. After the hostgssenc part was > added on, the whole thing became a bit wordy, and it's also a bit > inaccurate for exam

RE: [BUG] "FailedAssertion" reported when streaming in logical replication

2021-04-27 Thread tanghy.f...@fujitsu.com
> I have modified the patch based on the above comments. Thanks for your patch. I tested again after applying your patch and the problem is fixed. Regards Tang