Re: row filtering for logical replication

2021-12-02 Thread vignesh C
On Thu, Dec 2, 2021 at 9:29 AM houzj.f...@fujitsu.com wrote: > > On Thur, Dec 2, 2021 5:21 AM Peter Smith wrote: > > PSA the v44* set of patches. > > > > The following review comments are addressed: > > > > v44-0001 main patch > > - Renamed the TAP test 026->027 due to clash caused by recent comm

RE: Data is copied twice when specifying both child and parent table in publication

2021-12-02 Thread houzj.f...@fujitsu.com
On Thursday, December 2, 2021 12:50 PM Amit Kapila wrote: > On Thu, Dec 2, 2021 at 9:41 AM Greg Nancarrow > wrote: > > > > On Thu, Dec 2, 2021 at 1:48 PM Greg Nancarrow > wrote: > > > > > > If you updated my original description to say "(instead of just the > > > individual partitions)", it wou

Re: Non-superuser subscription owners

2021-12-02 Thread Amit Kapila
On Thu, Dec 2, 2021 at 12:51 AM Mark Dilger wrote: > > > > On Dec 1, 2021, at 5:36 AM, Amit Kapila wrote: > > > > On Wed, Dec 1, 2021 at 2:12 AM Jeff Davis wrote: > >> > >> On Tue, 2021-11-30 at 17:25 +0530, Amit Kapila wrote: > >>> I think it would be better to do it before we allow subscriptio

Re: Is ssl_crl_file "SSL server cert revocation list"?

2021-12-02 Thread Daniel Gustafsson
> On 2 Dec 2021, at 06:07, Kyotaro Horiguchi wrote: > > At Thu, 02 Dec 2021 13:54:41 +0900 (JST), Kyotaro Horiguchi > wrote in >> As discussed in the thread [1], I find the wording "SSL server >> certificate revocation list" as misleading or plain wrong. > > FWIW, I'm convinced that that's pl

Re: pgcrypto: Remove explicit hex encoding/decoding from tests

2021-12-02 Thread Daniel Gustafsson
> On 2 Dec 2021, at 10:22, Peter Eisentraut > wrote: > pgcrypto tests use encode() and decode() calls to convert to/from hex > encoding. This was from before the hex format was available in bytea. Now we > can remove the extra explicit encoding/decoding calls and rely on the default > output

Re: pg_dump versus ancient server versions

2021-12-02 Thread Peter Eisentraut
I was thinking a bit about formulating a policy for pg_dump backward compatibility, based on the discussions in this thread. Premises and preparatory thoughts: - Users (and developers) want pg_dump to support server versions that are much older than non-EOL versions. - Less critically, much-l

Re: Lowering the ever-growing heap->pd_lower

2021-12-02 Thread Daniel Gustafsson
This thread has stalled, and the request for benchmark/test has gone unanswered so I'm marking this patch Returned with Feedback. Please feel free to resubmit this patch if it is picked up again. -- Daniel Gustafsson https://vmware.com/

Re: Iterating on IndexTuple attributes and nbtree page-level dynamic prefix truncation

2021-12-02 Thread Daniel Gustafsson
> On 24 Jun 2021, at 18:21, Matthias van de Meent > wrote: > > On Thu, 17 Jun 2021 at 17:14, Matthias van de Meent > wrote: >> >> I'll try to >> benchmark the patches in this patchset (both 0001, and 0001+0002) in >> the upcoming weekend. > > Somewhat delayed, benchmark results are attached.

Re: An out-of-date comment in nodeIndexonlyscan.c

2021-12-02 Thread Daniel Gustafsson
> On 9 Nov 2021, at 15:28, Daniel Gustafsson wrote: > > This patch now fails to apply, probably due to a mostly trivial collision with > fdd88571454e2b00dbe446e8609c6e4294ca89ae in the test files. Can you submit a > rebased version? I've marked this Returned with Feedback, please feel free to r

Re: error_severity of brin work item

2021-12-02 Thread Daniel Gustafsson
This thread has stalled, and from the discussions there isn't consencus on how to proceed (if at all?), so I'm marking this Returned with Feedback. If the discussion and work picks up again then it can be resubmitted. -- Daniel Gustafsson https://vmware.com/

Re: Commitfest 2021-11 Patch Triage - Part 1

2021-12-02 Thread Daniel Gustafsson
> On 6 Nov 2021, at 17:20, Tomas Vondra wrote: > > On 11/5/21 22:15, Daniel Gustafsson wrote: >> ... >> 1651: GROUP BY optimization >> === >> This is IMO a desired optimization, and after all the heavy lifting by Tomas >> the patch seems to be in pretty good shape. > > I

Re: [PATCH] Automatic HASH and LIST partition creation

2021-12-02 Thread Daniel Gustafsson
This thread has stalled since July with review comments unanswered, I'm marking the patch Returned with Feedback. Please feel free to resubmit when/if a new patch is available. -- Daniel Gustafsson https://vmware.com/

Re: preserve timestamps when installing headers

2021-12-02 Thread Aleksander Alekseev
The following review has been posted through the commitfest application: make installcheck-world: tested, passed Implements feature: tested, passed Spec compliant: tested, passed Documentation:tested, passed Personally, I don't often encounter the problem that Alexande

Re: pg_dump versus ancient server versions

2021-12-02 Thread Robert Haas
On Thu, Dec 2, 2021 at 5:01 AM Peter Eisentraut wrote: > * pg_dump and psql will maintain compatibility with servers at least >ten major releases back. > > * We keep old major release branches buildable as long as a new major >release that has support for that old release is under support.

Re: pgbench logging broken by time logic changes

2021-12-02 Thread Daniel Gustafsson
> On 4 Nov 2021, at 13:38, Daniel Gustafsson wrote: > >> On 11 Jul 2021, at 15:07, Fabien COELHO wrote: > >> Attached the fully "ignored" version of the time features test as a patch. > > This version of the patch is failing to apply on top of HEAD, can you please > submit a rebased version?

Re: pg_get_publication_tables() output duplicate relid

2021-12-02 Thread Amit Langote
On Thu, Dec 2, 2021 at 2:27 PM Amit Kapila wrote: > On Thu, Dec 2, 2021 at 8:42 AM Amit Langote wrote: > > Reading Alvaro's email at the top again gave me a pause to reconsider > > what I had said in reply. It might indeed have been nice if the > > publication DDL itself had prevented the cases

Re: [Proposal] Fully WAL logged CREATE DATABASE - No Checkpoints

2021-12-02 Thread Dilip Kumar
On Wed, Dec 1, 2021 at 6:04 PM Dilip Kumar wrote: > Thanks a lot for testing this. From the error, it seems like some of > the old buffer w.r.t. the previous tablespace is not dropped after the > movedb. Actually, we are calling DropDatabaseBuffers() after copying > to a new tablespace and dropp

Re: row filtering for logical replication

2021-12-02 Thread Euler Taveira
On Thu, Dec 2, 2021, at 4:18 AM, Peter Smith wrote: > PSA a new v44* patch set. > > It includes a new patch 0006 which implements the idea above. > > ExprState cache logic is basically all the same as before (including > all the OR combining), but there are now 4x ExprState caches keyed and > sep

Re: allow partial union-all and improve parallel subquery costing

2021-12-02 Thread Daniel Gustafsson
With the thread stalled and requests for a test (documentation really?) not responded to I'm marking this patch Returned with Feedback. -- Daniel Gustafsson https://vmware.com/

Re: Column Filtering in Logical Replication

2021-12-02 Thread Alvaro Herrera
On 2021-Dec-01, Alvaro Herrera wrote: > Hi > > I took the latest posted patch, rebased on current sources, fixed the > conflicts, and pgindented. No further changes. Here's the result. All > tests are passing for me. Some review comments that were posted have > not been addressed yet; I'll lo

Re: PATCH: generate fractional cheapest paths in generate_orderedappend_path

2021-12-02 Thread Arne Roland
Afaiac we should add a simple testcase here, like I suggested in 477344d5f17c4a8e95d3a5bb6642718a. Apart from that I am not sure there is work to be done here. Am I wrong? Regards Arne ___

Re: Is ssl_crl_file "SSL server cert revocation list"?

2021-12-02 Thread Peter Eisentraut
On 02.12.21 10:42, Daniel Gustafsson wrote: On 2 Dec 2021, at 06:07, Kyotaro Horiguchi wrote: At Thu, 02 Dec 2021 13:54:41 +0900 (JST), Kyotaro Horiguchi wrote in As discussed in the thread [1], I find the wording "SSL server certificate revocation list" as misleading or plain wrong. FWIW,

Re: Skipping logical replication transactions on subscriber side

2021-12-02 Thread Peter Eisentraut
On 02.12.21 07:48, Amit Kapila wrote: a. ALTER SUBSCRIPTION ... [SET|RESET] SKIP TRANSACTION xxx; b. Alter Subscription SET ( subscription_parameter [=value] [, ... ] ); c. Alter Subscription On Error ( subscription_parameter [=value] [, ... ] ); d. Alter Subscription SKIP ( subscription_par

Re: Can I assume relation would not be invalid during from ExecutorRun to ExecutorEnd

2021-12-02 Thread Robert Haas
On Wed, Dec 1, 2021 at 10:58 PM Andy Fan wrote: > Thanks! I clearly understand what's wrong in my previous knowledge. Cool, glad it helped. -- Robert Haas EDB: http://www.enterprisedb.com

Re: Some RELKIND macro refactoring

2021-12-02 Thread Peter Eisentraut
On 24.11.21 05:20, Michael Paquier wrote: On Mon, Nov 22, 2021 at 11:21:52AM +0100, Peter Eisentraut wrote: On 19.11.21 08:31, Michael Paquier wrote: Regarding 0001, I find the existing code a bit more self-documenting if we keep those checks flagInhAttrs() and guessConstraintInheritance(). So

Re: Postgres restart in the middle of exclusive backup and the presence of backup_label file

2021-12-02 Thread Andrew Dunstan
On 12/1/21 19:30, Bossart, Nathan wrote: > On 12/1/21, 10:37 AM, "Bossart, Nathan" wrote: >> On 12/1/21, 8:27 AM, "David Steele" wrote: >>> On 11/30/21 18:31, Bossart, Nathan wrote: Do you think it's still worth trying to make it safe, or do you think we should just remove exclusive m

Re: pg_dump versus ancient server versions

2021-12-02 Thread Tom Lane
Peter Eisentraut writes: > Proposal: > * pg_dump and psql will maintain compatibility with servers at least >ten major releases back. > * We keep old major release branches buildable as long as a new major >release that has support for that old release is under support. > This assumes a

Re: Postgres restart in the middle of exclusive backup and the presence of backup_label file

2021-12-02 Thread David Steele
On 12/2/21 11:00, Andrew Dunstan wrote: On 12/1/21 19:30, Bossart, Nathan wrote: On 12/1/21, 10:37 AM, "Bossart, Nathan" wrote: On 12/1/21, 8:27 AM, "David Steele" wrote: On 11/30/21 18:31, Bossart, Nathan wrote: Do you think it's still worth trying to make it safe, or do you think we shou

Re: Postgres restart in the middle of exclusive backup and the presence of backup_label file

2021-12-02 Thread David Steele
On 12/2/21 12:38, David Steele wrote: On 12/2/21 11:00, Andrew Dunstan wrote: Should we really be getting rid of PostgreSQL::Test::Cluster::backup_fs_hot() ? Agreed, it would be better to update backup_fs_hot() to use exclusive mode and save out backup_label instead. Oops, of course I mean

Re: Replace uses of deprecated Python module distutils.sysconfig

2021-12-02 Thread Tom Lane
Peter Eisentraut writes: > With Python 3.10, configure spits out warnings about the module > distutils.sysconfig being deprecated and scheduled for removal in Python > 3.12: Bleah. > This patch changes the uses in configure to use the module sysconfig > instead. The logic stays the same. (I

Re: pgcrypto: Remove explicit hex encoding/decoding from tests

2021-12-02 Thread Tom Lane
Peter Eisentraut writes: > pgcrypto tests use encode() and decode() calls to convert to/from hex > encoding. This was from before the hex format was available in bytea. > Now we can remove the extra explicit encoding/decoding calls and rely on > the default output format. Generally +1, but I

Re: Windows: Wrong error message at connection termination

2021-12-02 Thread Alexander Lakhin
Hello Tom, 29.11.2021 22:16, Tom Lane wrote: > Hm, yeah, that discussion seems to have slipped through the cracks. > Not sure why it didn't end up in pushing something. > > After re-reading that thread and re-studying relevant Windows > documentation [1][2], I think the main open question is whethe

Re: Column Filtering in Logical Replication

2021-12-02 Thread Alvaro Herrera
On 2021-Sep-16, Peter Smith wrote: > I noticed that the latest v5 no longer includes the TAP test which was > in the v4 patch. > > (src/test/subscription/t/021_column_filter.pl) > > Was that omission deliberate? Somehow I not only failed to notice the omission, but also your email where you tol

Re: Windows: Wrong error message at connection termination

2021-12-02 Thread Tom Lane
Alexander Lakhin writes: > 29.11.2021 22:16, Tom Lane wrote: >> After re-reading that thread and re-studying relevant Windows >> documentation [1][2], I think the main open question is whether >> we need to issue shutdown() or not, and if so, whether to use >> SD_BOTH or just SD_SEND. I'm incline

Re: PATCH: generate fractional cheapest paths in generate_orderedappend_path

2021-12-02 Thread Tomas Vondra
Hi, On 12/2/21 15:58, Arne Roland wrote: Afaiac we should add a simple testcase here, like I suggested in 477344d5f17c4a8e95d3a5bb6642718a . Apart from that I am not sure there is work to be done here. Well,

Re: Commitfest 2021-11 Patch Triage - Part 1

2021-12-02 Thread Tomas Vondra
On 12/2/21 12:06, Daniel Gustafsson wrote: On 6 Nov 2021, at 17:20, Tomas Vondra wrote: On 11/5/21 22:15, Daniel Gustafsson wrote: ... 1651: GROUP BY optimization === This is IMO a desired optimization, and after all the heavy lifting by Tomas the patch seems to be i

Re: pg_dump versus ancient server versions

2021-12-02 Thread Andrew Dunstan
On 12/2/21 12:30, Tom Lane wrote: > >> In practice, the effort can focus on keeping the most recent cutoff >> release buildable. So in the above example, we really only need to >> keep PG >=9.2 buildable to support ongoing development. The chances >> that some needs to touch code pertaining to

Re: O(n) tasks cause lengthy startups and checkpoints

2021-12-02 Thread Bossart, Nathan
On 12/1/21, 6:06 PM, "Euler Taveira" wrote: > Saying that a certain task is O(n) doesn't mean it needs a separate process to > handle it. Did you have a use case or even better numbers (% of checkpoint / > startup time) that makes your proposal worthwhile? I don't have specific numbers on hand, b

Dubious usage of TYPCATEGORY_STRING

2021-12-02 Thread Tom Lane
The parser's type-coercion heuristics include some special rules for types belonging to the STRING category, which are predicated on the assumption that such types are reasonably general-purpose string types. This assumption has been violated by a few types, one error being ancient and the rest no

Re: O(n) tasks cause lengthy startups and checkpoints

2021-12-02 Thread Bossart, Nathan
On 12/1/21, 6:48 PM, "Bharath Rupireddy" wrote: > +1 for the overall idea of making the checkpoint faster. In fact, we > here at our team have been thinking about this problem for a while. If > there are a lot of files that checkpoint has to loop over and remove, > IMO, that task can be delegated

Re: Postgres restart in the middle of exclusive backup and the presence of backup_label file

2021-12-02 Thread Bossart, Nathan
On 12/2/21, 9:50 AM, "David Steele" wrote: > On 12/2/21 12:38, David Steele wrote: >> On 12/2/21 11:00, Andrew Dunstan wrote: >>> >>> Should we really be getting rid of >>> PostgreSQL::Test::Cluster::backup_fs_hot() ? >> >> Agreed, it would be better to update backup_fs_hot() to use exclusive >> m

Re: pg_dump versus ancient server versions

2021-12-02 Thread Andres Freund
Hi, On 2021-12-02 11:01:47 +0100, Peter Eisentraut wrote: > - The policy for other client-side tools (list at [0]) is less clear > and arguably less important. I suggest we focus on pg_dump and psql > first, and then we can decide for the rest whether they want to > match a longer window, a

Re: Skip vacuum log report code in lazy_scan_heap() if possible

2021-12-02 Thread Bossart, Nathan
On 10/29/21, 10:49 AM, "Bossart, Nathan" wrote: > On 10/29/21, 3:54 AM, "Greg Nancarrow" wrote: >> When recently debugging a vacuum-related issue, I noticed that there >> is some log-report processing/formatting code at the end of >> lazy_scan_heap() that, unless the vacuum VERBOSE option is spec

Re: row filtering for logical replication

2021-12-02 Thread Peter Smith
On Fri, Dec 3, 2021 at 12:59 AM Euler Taveira wrote: > > On Thu, Dec 2, 2021, at 4:18 AM, Peter Smith wrote: > > PSA a new v44* patch set. > > It includes a new patch 0006 which implements the idea above. > > ExprState cache logic is basically all the same as before (including > all the OR combini

Re: should we document an example to set multiple libraries in shared_preload_libraries?

2021-12-02 Thread Bossart, Nathan
On 12/1/21, 5:59 AM, "Bharath Rupireddy" wrote: > On Wed, Dec 1, 2021 at 6:45 PM Tom Lane wrote: >> Considering the vanishingly small number of actual complaints we've >> seen about this, that sounds ridiculously over-engineered. >> A documentation example should be sufficient. > > Thanks. Here'

Re: Skip vacuum log report code in lazy_scan_heap() if possible

2021-12-02 Thread Michael Paquier
On Thu, Dec 02, 2021 at 10:22:25PM +, Bossart, Nathan wrote: > Since I have no further comments, I went ahead and marked this once as > ready-for-committer. Well, as you say, lazy_scan_heap() is only run once per relation, so that's not a hot code path. Looking at the callers of message_level

Re: should we document an example to set multiple libraries in shared_preload_libraries?

2021-12-02 Thread Michael Paquier
On Fri, Dec 03, 2021 at 12:45:56AM +, Bossart, Nathan wrote: > I think the problems you noted upthread are shared for all GUCs with > type GUC_LIST_QUOTE (e.g., search_path, temp_tablespaces). Perhaps > the documentation for each of these GUCs should contain a short blurb > about how to proper

Re: GUC flags

2021-12-02 Thread Michael Paquier
On Wed, Dec 01, 2021 at 11:17:34PM -0600, Justin Pryzby wrote: > I find it easier to read "wait before authentication ..." than "wait ... > before > authentication". I have a hard time seeing a strong difference here. At the end, I have used what you suggested, adjusted the rest based on your se

Re: Temporary tables versus wraparound... again

2021-12-02 Thread Bossart, Nathan
On 10/12/21, 3:07 PM, "Greg Stark" wrote: > Here's an updated patch. I added some warning messages to autovacuum. I think this is useful optimization, and I intend to review the patch more closely soon. It looks reasonable to me after a quick glance. > One thing I learned trying to debug this s

Re: Skip vacuum log report code in lazy_scan_heap() if possible

2021-12-02 Thread Andres Freund
Hi, On 2021-12-03 09:53:22 +0900, Michael Paquier wrote: > On Thu, Dec 02, 2021 at 10:22:25PM +, Bossart, Nathan wrote: > > Since I have no further comments, I went ahead and marked this once as > > ready-for-committer. > > Well, as you say, lazy_scan_heap() is only run once per relation, so >

Re: CLUSTER on partitioned index

2021-12-02 Thread Michael Paquier
On Thu, Sep 23, 2021 at 06:56:26PM -0500, Justin Pryzby wrote: > On Thu, Sep 23, 2021 at 08:18:41PM +0200, Matthias van de Meent wrote: >> Note: The following review is based on the assumption that this v11 >> revision was meant to contain only one patch. I put this up as a note, >> because it seem

Re: Tab completion for CREATE SCHEMAAUTHORIZATION

2021-12-02 Thread Michael Paquier
On Wed, Aug 11, 2021 at 10:16:15AM +0900, Michael Paquier wrote: > + else if (Matches("CREATE", "SCHEMA", "AUTHORIZATION")) > + COMPLETE_WITH_QUERY(Query_for_list_of_owner_roles); > + else if (Matches("CREATE", "SCHEMA", MatchAny, "AUTHORIZATION")) > + COMPLE

keepliaves etc. as environment variables

2021-12-02 Thread Tatsuo Ishii
It seems there are no environment variables corresponding to keepalives etc. connection parameters in libpq. Is there any reason for this? Best reagards, -- Tatsuo Ishii SRA OSS, Inc. Japan English: http://www.sraoss.co.jp/index_en.php Japanese:http://www.sraoss.co.jp

Re: keepliaves etc. as environment variables

2021-12-02 Thread Andres Freund
Hi, On 2021-12-03 10:28:34 +0900, Tatsuo Ishii wrote: > It seems there are no environment variables corresponding to keepalives > etc. connection parameters in libpq. Is there any reason for this? PGOPTIONS='-c tcp_keepalive_*=foo' should work. Greetings, Andres Freund

Re: keepliaves etc. as environment variables

2021-12-02 Thread Tatsuo Ishii
> Hi, > > On 2021-12-03 10:28:34 +0900, Tatsuo Ishii wrote: >> It seems there are no environment variables corresponding to keepalives >> etc. connection parameters in libpq. Is there any reason for this? > > PGOPTIONS='-c tcp_keepalive_*=foo' should work. Sorry I was not clear. I wanted to know

Re: row filtering for logical replication

2021-12-02 Thread Peter Smith
On Thu, Dec 2, 2021 at 2:32 PM tanghy.f...@fujitsu.com wrote: > > On Thursday, December 2, 2021 5:21 AM Peter Smith > wrote: > > > > PSA the v44* set of patches. > > > > Thanks for the new patch. Few comments: > > 1. This is an example in publication doc, but in fact it's not allowed. > Should

Re: Skipping logical replication transactions on subscriber side

2021-12-02 Thread Amit Kapila
On Thu, Dec 2, 2021 at 8:38 PM Peter Eisentraut wrote: > > On 02.12.21 07:48, Amit Kapila wrote: > > a. ALTER SUBSCRIPTION ... [SET|RESET] SKIP TRANSACTION xxx; > > b. Alter Subscription SET ( subscription_parameter [=value] > > [, ... ] ); > > c. Alter Subscription On Error ( subscription_param

Re: More time spending with "delete pending"

2021-12-02 Thread Alexander Lakhin
Hello Daniel and Michael, 02.12.2021 08:03, Michael Paquier wrote: > On Wed, Dec 01, 2021 at 11:51:58AM +0100, Daniel Gustafsson wrote: >> Michael, have you had a chance to look at the updated patch here? I'm moving >> this patch entry from Waiting on Author to Needs Review. > No, I haven't. Befo

Alter all tables in schema owner fix

2021-12-02 Thread vignesh C
Hi, Currently while changing the owner of ALL TABLES IN SCHEMA publication, it is not checked if the new owner has superuser permission or not. Added a check to throw an error if the new owner does not have superuser permission. Attached patch has the changes for the same. Thoughts? Regards, Vign

Re: pg_get_publication_tables() output duplicate relid

2021-12-02 Thread Amit Kapila
On Thu, Dec 2, 2021 at 7:18 PM Amit Langote wrote: > > On Thu, Dec 2, 2021 at 2:27 PM Amit Kapila wrote: > > On Thu, Dec 2, 2021 at 8:42 AM Amit Langote wrote: > > > Reading Alvaro's email at the top again gave me a pause to reconsider > > > what I had said in reply. It might indeed have been n

Re: Alter all tables in schema owner fix

2021-12-02 Thread Greg Nancarrow
On Fri, Dec 3, 2021 at 2:06 PM vignesh C wrote: > > Currently while changing the owner of ALL TABLES IN SCHEMA > publication, it is not checked if the new owner has superuser > permission or not. Added a check to throw an error if the new owner > does not have superuser permission. > Attached patc

Re: Alter all tables in schema owner fix

2021-12-02 Thread Bossart, Nathan
On 12/2/21, 7:07 PM, "vignesh C" wrote: > Currently while changing the owner of ALL TABLES IN SCHEMA > publication, it is not checked if the new owner has superuser > permission or not. Added a check to throw an error if the new owner > does not have superuser permission. > Attached patch has the

Re: Alter all tables in schema owner fix

2021-12-02 Thread vignesh C
On Fri, Dec 3, 2021 at 9:58 AM Bossart, Nathan wrote: > > On 12/2/21, 7:07 PM, "vignesh C" wrote: > > Currently while changing the owner of ALL TABLES IN SCHEMA > > publication, it is not checked if the new owner has superuser > > permission or not. Added a check to throw an error if the new owne

Re: extended stats on partitioned tables

2021-12-02 Thread Justin Pryzby
On Thu, Nov 04, 2021 at 12:44:45AM +0100, Tomas Vondra wrote: > >> And I'm not sure we do the right thing after removing children, for example > >> (that should drop the inheritance stats, I guess). > > Do you mean for inheritance only ? Or partitions too ? > > I think for partitions, the stats s

Re: Alter all tables in schema owner fix

2021-12-02 Thread vignesh C
On Fri, Dec 3, 2021 at 9:53 AM Greg Nancarrow wrote: > > On Fri, Dec 3, 2021 at 2:06 PM vignesh C wrote: > > > > Currently while changing the owner of ALL TABLES IN SCHEMA > > publication, it is not checked if the new owner has superuser > > permission or not. Added a check to throw an error if t

RE: Data is copied twice when specifying both child and parent table in publication

2021-12-02 Thread houzj.f...@fujitsu.com
On Thursday, December 2, 2021 4:54 PM houzj.f...@fujitsu.com wrote: > On Thursday, December 2, 2021 12:50 PM Amit Kapila > wrote: > > On Thu, Dec 2, 2021 at 9:41 AM Greg Nancarrow > > wrote: > > > > > > On Thu, Dec 2, 2021 at 1:48 PM Greg Nancarrow > > wrote: > > > > > > > > If you updated my

Re: Failed transaction statistics to measure the logical replication progress

2021-12-02 Thread vignesh C
On Wed, Dec 1, 2021 at 3:04 PM osumi.takami...@fujitsu.com wrote: > > On Friday, November 19, 2021 11:11 PM Masahiko Sawada > wrote: > > Besides that, I’m not sure how useful commit_bytes, abort_bytes, and > > error_bytes are. I originally thought these statistics track the size of > > received

Re: [PATCH] support tab-completion for single quote input with equal sign

2021-12-02 Thread Michael Paquier
On Fri, Sep 17, 2021 at 02:45:57AM +0900, Kyotaro Horiguchi wrote: > This test fails for the same reason, but after fixing it the result > contains \a (BEL) in the output on my CentOS8. I'm not sure what is > happening here.. The patch is still failing under the CF bot, and this last update was tw

Re: suboverflowed subtransactions concurrency performance optimize

2021-12-02 Thread Dilip Kumar
On Tue, Nov 30, 2021 at 5:49 PM Simon Riggs wrote: > transam.c uses a single item cache to prevent thrashing from repeated > lookups, which reduces problems with shared access to SLRUs. > multitrans.c also has similar. > > I notice that subtrans. doesn't have this, but could easily do so. > Patch

Re: Skipping logical replication transactions on subscriber side

2021-12-02 Thread Masahiko Sawada
On Fri, Dec 3, 2021 at 11:53 AM Amit Kapila wrote: > > On Thu, Dec 2, 2021 at 8:38 PM Peter Eisentraut > wrote: > > > > On 02.12.21 07:48, Amit Kapila wrote: > > > a. ALTER SUBSCRIPTION ... [SET|RESET] SKIP TRANSACTION xxx; > > > b. Alter Subscription SET ( subscription_parameter [=value] > > >

Re: Commitfest 2021-11 Patch Triage - Part 1

2021-12-02 Thread Yugo NAGATA
On Wed, 1 Dec 2021 09:14:31 -0300 Marcos Pegoraro wrote: > > > > I think the reason why we can't update a materialized view directly is > > because > > it is basically a "view" and it should not contains any data irrelevant to > > its > > definition and underlying tables. If we would have a featu

Re: Use simplehash.h instead of dynahash in SMgr

2021-12-02 Thread Michael Paquier
On Tue, Oct 05, 2021 at 11:07:48AM +1300, David Rowley wrote: > I think I'd much rather talk about the concerns here than just > withdraw this. Even if what I have today just serves as something to > aid discussion. Hmm. This last update was two months ago, and the patch does not apply anymore.

Do sys logger and stats collector need wait events WAIT_EVENT_SYSLOGGER_MAIN/_PGSTAT_MAIN?

2021-12-02 Thread Bharath Rupireddy
Hi, Although the pg_stat_activity has no entry for the sys logger and stats collector (because of no shared memory access), the wait events WAIT_EVENT_SYSLOGGER_MAIN and WAIT_EVENT_PGSTAT_MAIN are defined. They seem to be unnecessary. Passing 0 or some other undefined wait event value to the exist

Re: row filtering for logical replication

2021-12-02 Thread Greg Nancarrow
On Thu, Dec 2, 2021 at 6:18 PM Peter Smith wrote: > > PSA a new v44* patch set. > Some initial comments: 0001 src/backend/replication/logical/tablesync.c (1) In fetch_remote_table_info update, "list_free(*qual);" should be "list_free_deep(*qual);" doc/src/sgml/ref/create_subscription.sgml (2)

Re: libpq compression

2021-12-02 Thread Michael Paquier
On Fri, Oct 01, 2021 at 11:20:09PM +0200, Daniel Gustafsson wrote: > To keep this thread from stalling, attached is a rebased patchset with the > above mentioned fix to try and get this working on Windows. This patch has been waiting on author for two months now, so I have marked it as RwF in the

Re: Parallelize correlated subqueries that execute within each worker

2021-12-02 Thread Michael Paquier
On Mon, Nov 15, 2021 at 10:01:37AM -0500, Robert Haas wrote: > On Wed, Nov 3, 2021 at 1:34 PM James Coleman wrote: >> As I understand the current code, parallel plans are largely chosen >> based not on where it's safe to insert a Gather node but rather by >> determining if a given path is parallel

Re: Speed up transaction completion faster after many relations are accessed in a transaction

2021-12-02 Thread Michael Paquier
On Fri, Oct 01, 2021 at 04:03:09PM +0900, Michael Paquier wrote: > This last update was two months ago, and the patch has not moved > since: > https://commitfest.postgresql.org/34/3220/ > > Do you have plans to work more on that or perhaps the CF entry should > be withdrawn or RwF'd? Two months l

Re: [PROPOSAL] new diagnostic items for the dynamic sql

2021-12-02 Thread Michael Paquier
On Wed, Nov 10, 2021 at 01:58:58PM +0530, Dinesh Chemuduru wrote: > The proposed statements are much clear, but will wait for other’s > suggestion, and will fix it accordingly. This update was three weeks ago, and no new version has been provided, so I am marking this as returned with feedback in

Re: Add missing function abs (interval)

2021-12-02 Thread Michael Paquier
On Fri, Nov 05, 2021 at 12:06:05AM -0400, Isaac Morland wrote: > Not yet, but thanks for the reminder. I will try to get this done on the > weekend. Seeing no updates, this has been switched to returned with feedback in the CF app. -- Michael signature.asc Description: PGP signature

Re: Logical replication - schema change not invalidating the relation cache

2021-12-02 Thread Michael Paquier
On Thu, Aug 26, 2021 at 09:00:39PM +0530, vignesh C wrote: > The previous patch was failing because of the recent test changes made > by commit 201a76183e2 which unified new and get_new_node, attached > patch has the changes to handle the changes accordingly. Please note that the CF app is complai

Re: PoC: using sampling to estimate joins / complex conditions

2021-12-02 Thread Michael Paquier
On Sun, Jun 27, 2021 at 07:55:24PM +0200, Tomas Vondra wrote: > estimating joins is one of the significant gaps related to extended > statistics, and I've been regularly asked about what we might do about > that. This is an early experimental patch that I think might help us > with improving this,

RE: Alter all tables in schema owner fix

2021-12-02 Thread tanghy.f...@fujitsu.com
On Friday, December 3, 2021 1:31 PM vignesh C wrote: > > On Fri, Dec 3, 2021 at 9:53 AM Greg Nancarrow wrote: > > > > On Fri, Dec 3, 2021 at 2:06 PM vignesh C wrote: > > > > > > Currently while changing the owner of ALL TABLES IN SCHEMA > > > publication, it is not checked if the new owner has

Remove extra Logging_collector check before calling SysLogger_Start()

2021-12-02 Thread Bharath Rupireddy
Hi, It seems like there's an extra Logging_collector check before calling SysLogger_Start(). Note that the SysLogger_Start() has a check to return 0 if Logging_collector is off. This change is consistent with the other usage of SysLogger_Start(). /* If we have lost the log collect