Re: tablecmds.c/MergeAttributes() cleanup

2023-08-29 Thread Nathan Bossart
On Tue, Aug 29, 2023 at 08:44:02PM +0200, Alvaro Herrera wrote: > On 2023-Aug-29, Nathan Bossart wrote: >> My compiler is complaining about 1fa9241b: >> >> ../postgresql/src/backend/commands/sequence.c: In function ‘DefineSequence’: >> ../postgresql/src/backend/comman

Re: Wrong usage of pqMsg_Close message code?

2023-08-29 Thread Nathan Bossart
On Tue, Aug 29, 2023 at 09:15:55AM -0700, Nathan Bossart wrote: > Thanks for the report. I'll get this fixed up. My guess is that this was > leftover from an earlier version of the patch that used the same macro for > identical protocol characters. I plan to commit the attached

Re: Is pg_regress --use-existing used by anyone or is it broken?

2023-08-29 Thread Nathan Bossart
re use it? I don't think I've ever used it. AFAICT it was added with hot standby mode (efc16ea) to support 'make standbycheck', which was removed last year (4483b2cf). Unless someone claims to be using it, it's probably fine to just remove it. -- Nathan Bossart Amazon Web Services: https://aws.amazon.com

Re: should frontend tools use syncfs() ?

2023-08-29 Thread Nathan Bossart
methods should cause compiler warnings until they are implemented. -- Nathan Bossart Amazon Web Services: https://aws.amazon.com >From f5ecb3c8b5d397c94a9f8ab9a053b3a0cfd7f854 Mon Sep 17 00:00:00 2001 From: Nathan Bossart Date: Mon, 21 Aug 2023 19:05:14 -0700 Subject: [PATCH v7 1/2] mov

Re: Wrong usage of pqMsg_Close message code?

2023-08-29 Thread Nathan Bossart
On Wed, Aug 30, 2023 at 07:56:33AM +0900, Michael Paquier wrote: > On Tue, Aug 29, 2023 at 02:11:06PM -0700, Nathan Bossart wrote: >> I plan to commit the attached patch shortly. > > WFM. Committed. -- Nathan Bossart Amazon Web Services: https://aws.amazon.com

Re: pg_stat_get_backend_subxact() and backend IDs?

2023-08-29 Thread Nathan Bossart
On Wed, Aug 30, 2023 at 08:22:27AM +0900, Michael Paquier wrote: > On Tue, Aug 29, 2023 at 09:46:55AM -0700, Nathan Bossart wrote: >> This was my first reaction [0]. I was concerned about renaming the >> exported functions so close to release, so I was suggesting that we hold >

Re: pg_stat_get_backend_subxact() and backend IDs?

2023-08-30 Thread Nathan Bossart
plicitly, I don't have any comments on the proposed patches. I'm about to spend way too much time writing the commit message for 0002, but I plan to commit both patches sometime today. -- Nathan Bossart Amazon Web Services: https://aws.amazon.com

Re: pg_stat_get_backend_subxact() and backend IDs?

2023-08-30 Thread Nathan Bossart
On Wed, Aug 30, 2023 at 10:56:22AM -0400, Robert Haas wrote: > On Wed, Aug 30, 2023 at 10:27 AM Nathan Bossart > wrote: >> I'm about to spend way too much time writing the commit message for 0002, >> but I plan to commit both patches sometime today. > > Thanks!

Re: should frontend tools use syncfs() ?

2023-08-31 Thread Nathan Bossart
aDirSyncMethod and uses it for recovery_init_sync_method. The second adds syncfs() support in file_utils.c. And the third adds the ability to specify syncfs in the frontend utilities. WDYT? -- Nathan Bossart Amazon Web Services: https://aws.amazon.com >From e627b8ea4dcc01ac9e2fe3a21e3b3cc109b815e4 Mon Sep 17 0

Re: should frontend tools use syncfs() ?

2023-08-31 Thread Nathan Bossart
hat's worth worrying about. > +command_ok([ 'initdb', '-S', $datadir, '--sync-method', 'fsync' ], > + 'sync method fsync'); > > Removing this one may be fine, actually, because we test the sync > paths on other places like pg_

Re: Adding a pg_get_owned_sequence function?

2023-09-01 Thread Nathan Bossart
't use it. But I suppose it wouldn't be too much trouble to keep it around for anyone who happens to need it. -- Nathan Bossart Amazon Web Services: https://aws.amazon.com

Re: Inefficiency in parallel pg_restore with many tables

2023-09-01 Thread Nathan Bossart
On Tue, Jul 25, 2023 at 11:53:36AM -0700, Nathan Bossart wrote: > Here is a polished patch set for this approach. I've also added a 0004 > that replaces the open-coded heap in pg_dump_sort.c with a binaryheap. > IMHO these patches are in decent shape. I'm hoping to commit th

Re: Inefficiency in parallel pg_restore with many tables

2023-09-01 Thread Nathan Bossart
On Fri, Sep 01, 2023 at 01:41:41PM -0400, Tom Lane wrote: > I've not actually looked at any of these patchsets after the first one. > I have added myself as a reviewer and will hopefully get to it within > a week or so. Thanks! -- Nathan Bossart Amazon Web Services: https://aws.amazon.com

Re: Adding a pg_get_owned_sequence function?

2023-09-01 Thread Nathan Bossart
On Fri, Sep 01, 2023 at 01:31:43PM -0400, Tom Lane wrote: > Nathan Bossart writes: >> I wonder if it'd be possible to just remove pg_get_serial_sequence(). > > A quick search at http://codesearch.debian.net/ finds uses of it > in packages like gdal, qgis, rails, ... We

Re: should frontend tools use syncfs() ?

2023-09-01 Thread Nathan Bossart
inct error when syncfs is not supported > than when it's truely recognized. Later versions of the patch should have this. > The patch should handle pg_dumpall, too. It looks like pg_dumpall only ever fsyncs a single file, so I don't think it is really needed there. -- Nathan Bossart Amazon Web Services: https://aws.amazon.com

Re: should frontend tools use syncfs() ?

2023-09-01 Thread Nathan Bossart
On Fri, Sep 01, 2023 at 01:19:13PM -0500, Justin Pryzby wrote: > What about (per git grep no-sync doc) pg_receivewal? I don't think it's applicable there, either. IIUC that option specifies whether to sync the data as it is streamed over. -- Nathan Bossart Amazon Web Se

Re: Replace known_assigned_xids_lck by memory barrier

2023-09-01 Thread Nathan Bossart
On Wed, Aug 16, 2023 at 01:07:15PM -0700, Nathan Bossart wrote: > Ah, that explains it. v5 of the patch is attached. Barring additional feedback, I plan to commit this patch in the current commitfest. -- Nathan Bossart Amazon Web Services: https://aws.amazon.com

Re: Add 'worker_type' to pg_stat_subscription

2023-09-01 Thread Nathan Bossart
r apply workers". Would those show up as parallel apply workers in the view? Can we add another worker type for those? -- Nathan Bossart Amazon Web Services: https://aws.amazon.com

Re: Inefficiency in parallel pg_restore with many tables

2023-09-01 Thread Nathan Bossart
egers are already stored directly in the array thanks to the use of Datum. However, it _would_ allow us to abandon this frontend/backend void */Datum kludge, which is something. -- Nathan Bossart Amazon Web Services: https://aws.amazon.com

Re: Inefficiency in parallel pg_restore with many tables

2023-09-02 Thread Nathan Bossart
On Fri, Sep 01, 2023 at 01:52:48PM -0700, Nathan Bossart wrote: > On Fri, Sep 01, 2023 at 04:00:44PM -0400, Robert Haas wrote: >> In hindsight, I think that making binaryheap depend on Datum was a bad >> idea. I think that was my idea, and I think it wasn't very smart. >&g

Re: Inefficiency in parallel pg_restore with many tables

2023-09-03 Thread Nathan Bossart
On Sun, Sep 03, 2023 at 12:04:00PM +0200, Alvaro Herrera wrote: > On 2023-Sep-02, Nathan Bossart wrote: >> I ended up hacking together a (nowhere near committable) patch to see how >> hard it would be to allow using any type with binaryheap. It doesn't seem >> too

Re: Inefficiency in parallel pg_restore with many tables

2023-09-04 Thread Nathan Bossart
On Sat, Sep 02, 2023 at 11:55:21AM -0700, Nathan Bossart wrote: > I ended up hacking together a (nowhere near committable) patch to see how > hard it would be to allow using any type with binaryheap. It doesn't seem > too bad. I spent some more time on this patch and mad

Re: Replace known_assigned_xids_lck by memory barrier

2023-09-05 Thread Nathan Bossart
On Fri, Sep 01, 2023 at 03:53:54PM -0400, Robert Haas wrote: > I'm not an expert on this code but I looked at this patch briefly and > it seems OK to me. Thanks for taking a look. Committed. -- Nathan Bossart Amazon Web Services: https://aws.amazon.com

Re: Add 'worker_type' to pg_stat_subscription

2023-09-05 Thread Nathan Bossart
On Wed, Sep 06, 2023 at 09:02:21AM +1200, Peter Smith wrote: > On Sat, Sep 2, 2023 at 7:41 AM Nathan Bossart > wrote: >> I see that the table refers to "leader apply workers". Would those show up >> as parallel apply workers in the view? Can we add anot

Re: should frontend tools use syncfs() ?

2023-09-05 Thread Nathan Bossart
I've committed 0001 for now. I plan to commit the rest in the next couple of days. -- Nathan Bossart Amazon Web Services: https://aws.amazon.com

Re: should frontend tools use syncfs() ?

2023-09-06 Thread Nathan Bossart
On Tue, Sep 05, 2023 at 05:08:53PM -0700, Nathan Bossart wrote: > I've committed 0001 for now. I plan to commit the rest in the next couple > of days. Committed. -- Nathan Bossart Amazon Web Services: https://aws.amazon.com

Re: Document that server will start even if it's unable to open some TCP/IP ports

2023-09-07 Thread Nathan Bossart
ten_addresses is not empty, the server will start only if it can listen on at least one of the specified addresses. A warning will be emitted for any addresses that the server cannot listen on. -- Nathan Bossart Amazon Web Services: https://aws.amazon.com

Re: Add 'worker_type' to pg_stat_subscription

2023-09-07 Thread Nathan Bossart
see a worker with this type, perhaps it would be better to actually list it as "unknown". Thoughts? -- Nathan Bossart Amazon Web Services: https://aws.amazon.com >From 85b826752b1b10176809918975ce7b495dadd3db Mon Sep 17 00:00:00 2001 From: Nathan Bossart Date: Thu, 7 Sep 2023 15:24:

Re: Document that server will start even if it's unable to open some TCP/IP ports

2023-09-07 Thread Nathan Bossart
On Thu, Sep 07, 2023 at 07:13:44PM -0400, Bruce Momjian wrote: > On Thu, Sep 7, 2023 at 02:54:13PM -0700, Nathan Bossart wrote: >> IMO the phrase "open a port" is kind of nonstandard. I think we should say >> something along the lines of >> >> If list

Re: Adding a pg_get_owned_sequence function?

2023-09-08 Thread Nathan Bossart
't do anything > until it's actually gone (and maybe not even then). There really isn't > a serious middle-ground where deprecation is helpful given our yearly > release cycle and long major version support period. Fair point. -- Nathan Bossart Amazon Web Services: https://aws.amazon.com

Re: Document that server will start even if it's unable to open some TCP/IP ports

2023-09-08 Thread Nathan Bossart
On Fri, Sep 08, 2023 at 10:52:10AM -0400, Bruce Momjian wrote: > On Thu, Sep 7, 2023 at 09:21:07PM -0700, Nathan Bossart wrote: >> On Thu, Sep 07, 2023 at 07:13:44PM -0400, Bruce Momjian wrote: >> > On Thu, Sep 7, 2023 at 02:54:13PM -0700, Nathan Bossart wrote: >> >&g

Re: Add 'worker_type' to pg_stat_subscription

2023-09-13 Thread Nathan Bossart
the code accordingly. If we just rely on an ERROR in the default section, we might miss it if there isn't a relevant test. > So, should we mark this thread as RfC? I've done so. Barring additional feedback, I intend to commit this in the next few days. -- Nathan Bossart Amazon Web Services: https://aws.amazon.com

Re: Add 'worker_type' to pg_stat_subscription

2023-09-13 Thread Nathan Bossart
On Wed, Sep 13, 2023 at 09:59:04AM -0700, Nathan Bossart wrote: > On Wed, Sep 13, 2023 at 05:06:28PM +0300, Maxim Orlov wrote: >> So, should we mark this thread as RfC? > > I've done so. Barring additional feedback, I intend to commit this in the > next few days. Not

Re: Inefficiency in parallel pg_restore with many tables

2023-09-13 Thread Nathan Bossart
j = (int) (intptr_t) binaryheap_remove_first(pendingHeap); > > otherwise some compilers might complain about the result possibly > not fitting in "j". Sure. IMO it's a tad more readable, too. > Other than those nitpicks, I like v6. I'll mark this RfC. Grea

Re: Inefficiency in parallel pg_restore with many tables

2023-09-13 Thread Nathan Bossart
On Wed, Sep 13, 2023 at 11:34:50AM -0700, Nathan Bossart wrote: > On Sun, Sep 10, 2023 at 12:35:10PM -0400, Tom Lane wrote: >> Other than those nitpicks, I like v6. I'll mark this RfC. > > Great. I've posted a v8 with your comments addressed in order to get one >

Re: Inefficiency in parallel pg_restore with many tables

2023-09-13 Thread Nathan Bossart
On Wed, Sep 13, 2023 at 08:01:39PM -0400, Tom Lane wrote: > Nathan Bossart writes: >> Upon closer inspection, I found a rather nasty problem. The qsort >> comparator expects a TocEntry **, but the binaryheap comparator expects a >> TocEntry *, and we simply pass the arg

Re: bug fix and documentation improvement about vacuumdb

2023-09-14 Thread Nathan Bossart
nothing >> about >> tables not in the specified schema. > > Maybe, but the point of vacuumdb is to analyze a database so I'm not sure who > would expect anything else than vacuuming everything but the excluded schema > when specifying -N. What else could &quo

Re: Add 'worker_type' to pg_stat_subscription

2023-09-14 Thread Nathan Bossart
On Wed, Sep 13, 2023 at 09:59:04AM -0700, Nathan Bossart wrote: > On Wed, Sep 13, 2023 at 05:06:28PM +0300, Maxim Orlov wrote: >> So, should we mark this thread as RfC? > > I've done so. Barring additional feedback, I intend to commit this in the > next few days. I did so

Re: Improve the log message output of basic_archive when basic_archive.archive_directory parameter is not set

2023-09-15 Thread Nathan Bossart
ented in archive-modules.sgml, so >> that needs to be updated as well. This also means you can't backpatch >> this change, or you risk breaking external software that implements this >> interface. > > Absolutely, this is master only for v17. +1 -- Nathan Bossart Amazon Web Services: https://aws.amazon.com

Re: bug fix and documentation improvement about vacuumdb

2023-09-15 Thread Nathan Bossart
C code relatively readable. These sorts of things bug me, too (see 2af3336). -- Nathan Bossart Amazon Web Services: https://aws.amazon.com

Re: Add 'worker_type' to pg_stat_subscription

2023-09-15 Thread Nathan Bossart
On Thu, Sep 14, 2023 at 03:04:19PM -0700, Nathan Bossart wrote: > The only reason I didn't apply this already is because IMHO we should > adjust the worker types and the documentation for the view to be > consistent. For example, the docs say "leader apply worker" but th

Re: SET ROLE documentation improvement

2023-09-15 Thread Nathan Bossart
n user is a superuser, any role can be selected.) But I don't see a big issue with clarifying things further as you propose. I think another issue is that the aforementioned note doesn't mention the new SET option added in 3d14e17. -- Nathan Bossart Amazon Web Services: https://aws.amazon.com

Re: ALTER ROLE documentation improvement

2023-09-15 Thread Nathan Bossart
quot;. Perhaps we should standardize on one name. [0] https://www.postgresql.org/docs/devel/glossary.html -- Nathan Bossart Amazon Web Services: https://aws.amazon.com

Re: Add 'worker_type' to pg_stat_subscription

2023-09-16 Thread Nathan Bossart
r". This still leaves the possibility for confusion with the documentation's use of "leader apply worker", but I haven't touched that for now. -- Nathan Bossart Amazon Web Services: https://aws.amazon.com >From 42c7b1910af29a8543ed65b2150e5eedae34a594 M

Re: Add 'worker_type' to pg_stat_subscription

2023-09-18 Thread Nathan Bossart
;%s\" has started" that perhaps should > say "logical replication leader apply worker for subscription \"%s\" > has started". Such changes don't belong in this stats patch. +1 [0] https://postgr.es/m/attachment/150345/v7-0001-Add-worker-type-to-pg_stat_subscription.patch -- Nathan Bossart Amazon Web Services: https://aws.amazon.com

Re: Inefficiency in parallel pg_restore with many tables

2023-09-18 Thread Nathan Bossart
For now, I've committed 0001 and 0002. I intend to commit the others soon. -- Nathan Bossart Amazon Web Services: https://aws.amazon.com

Re: Improvements in pg_dump/pg_restore toc format and performances

2023-09-18 Thread Nathan Bossart
#3 (no strtoul) 202M22.8s 0.94s > #4 (string list) 181M23.1s 0.87s At a glance, the size improvements in 0004 look the most interesting to me. -- Nathan Bossart Amazon Web Services: https://aws.amazon.com

Re: Improvements in pg_dump/pg_restore toc format and performances

2023-09-18 Thread Nathan Bossart
On Mon, Sep 18, 2023 at 02:52:47PM -0700, Nathan Bossart wrote: > On Thu, Jul 27, 2023 at 10:51:11AM +0200, Pierre Ducroquet wrote: >> I ended up writing several patches that shaved some time for pg_restore -l, >> and reduced the toc.dat size. > > I've only just star

Re: Inefficiency in parallel pg_restore with many tables

2023-09-18 Thread Nathan Bossart
On Mon, Sep 18, 2023 at 09:23:20PM -0400, Tom Lane wrote: > Nathan Bossart writes: >> For now, I've committed 0001 and 0002. I intend to commit the others soon. > > bowerbird is unhappy with this. I suppose you missed out updating > the src/tools/msvc/ scripts. (Weren&#

Re: Inefficiency in parallel pg_restore with many tables

2023-09-18 Thread Nathan Bossart
nt. I won't have much time for this for the next few weeks, so if someone else wants to pick it up, please feel free. [0] https://postgr.es/m/20230408191007.7lysd42euafwl74f%40awork3.anarazel.de [1] https://github.com/anarazel/postgres/commits/drop-homegrown-msvc -- Nathan Bossart Amazon W

Re: Inefficiency in parallel pg_restore with many tables

2023-09-19 Thread Nathan Bossart
On Mon, Sep 18, 2023 at 02:22:32PM -0700, Nathan Bossart wrote: > For now, I've committed 0001 and 0002. I intend to commit the others soon. I've committed the rest of the patches. -- Nathan Bossart Amazon Web Services: https://aws.amazon.com

Re: should frontend tools use syncfs() ?

2023-09-20 Thread Nathan Bossart
me for a variable in xlog module. +1 I think we should also consider renaming things like SYNC_METHOD_FSYNC to WAL_SYNC_METHOD_FSYNC, and sync_method_options to wal_sync_method_options. -- Nathan Bossart Amazon Web Services: https://aws.amazon.com

Re: Add 'worker_type' to pg_stat_subscription

2023-09-20 Thread Nathan Bossart
y. For reference, > I checked pg_stat_activity.backend_type, there is nothing called main > or leader backend even when the backend is involved in parallel query. Okay. Here is v9 of the patch with this change. -- Nathan Bossart Amazon Web Services: https://aws.amazon.com >From b8268a4c95ff217742bc2e

Re: Improvements in pg_dump/pg_restore toc format and performances

2023-09-20 Thread Nathan Bossart
depSize); } deps[depIdx] = depId; Also, can we make depId more locally scoped? I have yet to look into 0004 still. -- Nathan Bossart Amazon Web Services: https://aws.amazon.com

Re: Add 'worker_type' to pg_stat_subscription

2023-09-20 Thread Nathan Bossart
posted. Right, I'll take care of it before committing. I'm trying to make sure I don't forget. :) -- Nathan Bossart Amazon Web Services: https://aws.amazon.com

Re: bug fix and documentation improvement about vacuumdb

2023-09-23 Thread Nathan Bossart
I propose we > commit > to fix this, with a backpatch to v16 where it was introduced. LGTM -- Nathan Bossart Amazon Web Services: https://aws.amazon.com

Re: Add 'worker_type' to pg_stat_subscription

2023-09-25 Thread Nathan Bossart
On Thu, Sep 21, 2023 at 04:01:20PM +0530, Amit Kapila wrote: > The changes looks good to me, though I haven't tested it. But feel > free to commit if you are fine with this patch. Committed. -- Nathan Bossart Amazon Web Services: https://aws.amazon.com

Re: SET ROLE documentation improvement

2023-09-25 Thread Nathan Bossart
On Fri, Sep 15, 2023 at 02:36:16PM -0700, Yurii Rashkovskii wrote: > On Fri, Sep 15, 2023 at 1:47 PM Nathan Bossart > wrote: >> I think another issue is that the aforementioned note doesn't mention the >> new SET option added in 3d14e17. > > How do you think we s

Re: Improve the log message output of basic_archive when basic_archive.archive_directory parameter is not set

2023-09-25 Thread Nathan Bossart
th v16? -- Nathan Bossart Amazon Web Services: https://aws.amazon.com

Re: ALTER ROLE documentation improvement

2023-09-25 Thread Nathan Bossart
have the %s attribute." msgstr "Der Bootstrap-Benutzer muss das %s-Attribut haben." No need to update the translation files. Those are updated separately in the pgtranslation repo. -- Nathan Bossart Amazon Web Services: https://aws.amazon.com

Re: stopgap fix for signal handling during restore_command

2023-10-04 Thread Nathan Bossart
On Sun, Oct 01, 2023 at 08:50:15PM +0200, Peter Eisentraut wrote: > Is this still being contemplated? What is the status of this? I'll plan on committing this in the next couple of days. -- Nathan Bossart Amazon Web Services: https://aws.amazon.com

Re: --sync-method isn't documented to take an argument

2023-10-04 Thread Nathan Bossart
ke this: > > --pgdata=directory > --filenode=filenode > > etc. > > This one should be something like this: > > --sync-method=method Whoops. Thanks for pointing this out. I'll get this fixed. -- Nathan Bossart Amazon Web Services: https://aws.amazon.com

Re: should frontend tools use syncfs() ?

2023-10-04 Thread Nathan Bossart
ion 19.2. Maybe it could be put there? I will give this a try. -- Nathan Bossart Amazon Web Services: https://aws.amazon.com

Re: --sync-method isn't documented to take an argument

2023-10-04 Thread Nathan Bossart
I didn't address the class="parameter" stuff at all. I figured it would be best to handle that separately. -- Nathan Bossart Amazon Web Services: https://aws.amazon.com diff --git a/doc/src/sgml/ref/initdb.sgml b/doc/src/sgml/ref/initdb.sgml index 8a09c5c438..d43c91575c 100644 --- a

Re: --sync-method isn't documented to take an argument

2023-10-04 Thread Nathan Bossart
On Wed, Oct 04, 2023 at 11:51:32AM -0400, Robert Haas wrote: > On Wed, Oct 4, 2023 at 11:27 AM Nathan Bossart > wrote: >> Here's a patch. I didn't address the class="parameter" stuff at all. I >> figured it would be best to handle that separately. >

Re: --sync-method isn't documented to take an argument

2023-10-04 Thread Nathan Bossart
not sweating too much otherwise. I matched the adjacent options as you suggested. Perhaps unsurprisingly, the inclusion of class="parameter" is not the only inconsistency. I also found that pg_upgrade adds the before the argument name! -- Nathan Bossart Amazon Web Services: https://aws.amazon.com

Re: Add a new BGWORKER_BYPASS_ROLELOGINCHECK flag

2023-10-05 Thread Nathan Bossart
This avoids the new code being in the old format and > changing things right after it commits. +1 -- Nathan Bossart Amazon Web Services: https://aws.amazon.com

Re: [PoC/RFC] Multiple passwords, interval expirations

2023-10-05 Thread Nathan Bossart
t; -- user to completely lose the ability to use passwords for login after this > -- command. To get the old behavior, the user must now use the ALL PASSWORD > -- NULL incantation; see below. > -- Issuing this command one more time will remove even the restored password, > -- hence leaving the user with no passwords. Is it possible to remove the oldest password added without removing the latest password added? -- Nathan Bossart Amazon Web Services: https://aws.amazon.com

Re: [PoC/RFC] Multiple passwords, interval expirations

2023-10-06 Thread Nathan Bossart
On Thu, Oct 05, 2023 at 01:09:36PM -0700, Jeff Davis wrote: > On Thu, 2023-10-05 at 14:04 -0500, Nathan Bossart wrote: >> That way, we needn't restrict this feature to 2 passwords for >> everyone.  Perhaps 2 should be the default, but in any case, IMO we >> shouldn&

Re: should frontend tools use syncfs() ?

2023-10-06 Thread Nathan Bossart
t so that it doesn't get lost? I will aim to take a closer look at it next week. -- Nathan Bossart Amazon Web Services: https://aws.amazon.com

Re: Microoptimization of Bitmapset usage in postgres_fdw

2018-06-14 Thread Nathan Bossart
The following review has been posted through the commitfest application: make installcheck-world: not tested Implements feature: not tested Spec compliant: not tested Documentation:not tested Hello, The v2 patches look good to me. However, I found a couple other plac

Re: Make description of heap records more talkative for flags

2018-06-15 Thread Nathan Bossart
The following review has been posted through the commitfest application: make installcheck-world: not tested Implements feature: not tested Spec compliant: not tested Documentation:not tested - appendStringInfo(buf, "off %u", xlrec->offnum); +

Re: Use durable_unlink for .ready and .done files for WAL segment removal

2018-11-02 Thread Nathan Bossart
One argument for instead checking WAL file existence before calling archive_command might be to avoid the increased startup time. Granted, any added delay from this patch is unlikely to be noticeable unless your archiver is way behind and archive_status has a huge number of files. However, I have

Re: predefined role(s) for VACUUM and ANALYZE

2022-11-16 Thread Nathan Bossart
y remaining concerns. > If so I'm intending to > commit at least the first two of these patches fairly soon. Thanks! -- Nathan Bossart Amazon Web Services: https://aws.amazon.com

Re: predefined role(s) for VACUUM and ANALYZE

2022-11-18 Thread Nathan Bossart
rebased -- Nathan Bossart Amazon Web Services: https://aws.amazon.com >From 0643a4dbc9f36d9fd383ef0cfebef13875237718 Mon Sep 17 00:00:00 2001 From: Nathan Bossart Date: Wed, 7 Sep 2022 22:25:29 -0700 Subject: [PATCH v10 1/4] Change AclMode from a uint32 to a uint64. --- src/backend/no

Re: predefined role(s) for VACUUM and ANALYZE

2022-11-19 Thread Nathan Bossart
On Fri, Nov 18, 2022 at 09:05:04AM -0800, Nathan Bossart wrote: > rebased another rebase -- Nathan Bossart Amazon Web Services: https://aws.amazon.com >From 6e2001411107790991037e91f8d2f9411e2f4fa6 Mon Sep 17 00:00:00 2001 From: Nathan Bossart Date: Wed, 7 Sep 2022 22:25:29 -0700 S

Re: predefined role(s) for VACUUM and ANALYZE

2022-11-20 Thread Nathan Bossart
On Sat, Nov 19, 2022 at 10:50:04AM -0800, Nathan Bossart wrote: > another rebase Another rebase for cfbot. -- Nathan Bossart Amazon Web Services: https://aws.amazon.com >From 5f716f33e93187491686381b2180894ab2b1b92c Mon Sep 17 00:00:00 2001 From: Nathan Bossart Date: Wed, 7 Sep 2022 22

Re: Reducing power consumption on idle servers

2022-11-20 Thread Nathan Bossart
ear future. [0] https://postgr.es/m/20221113222644.GA1269110%40nathanxps13 -- Nathan Bossart Amazon Web Services: https://aws.amazon.com

wake up logical workers after ALTER SUBSCRIPTION

2022-11-21 Thread Nathan Bossart
Thoughts? -- Nathan Bossart Amazon Web Services: https://aws.amazon.com >From 80452ebbadfe80f237ebf5c7cdf8fa5eb2a61e35 Mon Sep 17 00:00:00 2001 From: Nathan Bossart Date: Mon, 21 Nov 2022 16:01:01 -0800 Subject: [PATCH v1 1/1] wake up logical workers after ALTER SUBSCRIPTION --- src/backend/a

Re: wake up logical workers after ALTER SUBSCRIPTION

2022-11-21 Thread Nathan Bossart
o a single variable might not be enough. Perhaps we can put a list in TopTransactionContext. I'll do some more investigation and report back. -- Nathan Bossart Amazon Web Services: https://aws.amazon.com

Re: wake up logical workers after ALTER SUBSCRIPTION

2022-11-21 Thread Nathan Bossart
e bulk of the logic to logical/worker.c. -- Nathan Bossart Amazon Web Services: https://aws.amazon.com >From 57bbd9e8d9da72c50d9a41704f3f42b37aba33ab Mon Sep 17 00:00:00 2001 From: Nathan Bossart Date: Mon, 21 Nov 2022 16:01:01 -0800 Subject: [PATCH v2 1/1] wake up logical workers after ALTER SUB

Re: wake up logical workers after ALTER SUBSCRIPTION

2022-11-23 Thread Nathan Bossart
subid >> will >> be recorded twice. >> I'm not sure whether it may be caused some issued, but list_member_oid() can >> be used to avoid that. > > +1, list_append_unique_oid might be better. Done in v3. -- Nathan Bossart Amazon Web Services: https://aws.amazon

Re: wake up logical workers after ALTER SUBSCRIPTION

2022-11-23 Thread Nathan Bossart
On Tue, Nov 22, 2022 at 04:59:28PM +0530, Amit Kapila wrote: > On Tue, Nov 22, 2022 at 6:11 AM Nathan Bossart > wrote: >> While working on avoiding unnecessary wakeups in logical/worker.c (as was >> done for walreceiver.c in 05a7be9), I noticed that the tests began taking >

Re: predefined role(s) for VACUUM and ANALYZE

2022-11-23 Thread Nathan Bossart
case I think this comment would be better English with "might" > instead of "may": > > /* user may have the ANALYZE privilege */ I've attempted to address all your feedback in v13. Please let me know if anything needs further reworking. --

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

2022-11-23 Thread Nathan Bossart
On Sun, Nov 06, 2022 at 02:38:42PM -0800, Nathan Bossart wrote: > rebased another rebase for cfbot -- Nathan Bossart Amazon Web Services: https://aws.amazon.com >From b2c36a6d0d8ca5cde374b1c8b34aafaabbd7f6c2 Mon Sep 17 00:00:00 2001 From: Nathan Bossart Date: Wed, 5 Jan 2022 19:24:22

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

2022-11-27 Thread Nathan Bossart
the others in a later CF/separate thread? That seems like a good idea since those are all relatively self-contained. I removed 0002-0004 in v14. [0] https://postgr.es/m/20220217065938.x2esfdppzypegn5j%40alap3.anarazel.de -- Nathan Bossart Amazon Web Services: https://aws.amazon.com >From 4

Re: wake up logical workers after ALTER SUBSCRIPTION

2022-11-27 Thread Nathan Bossart
On Thu, Nov 24, 2022 at 05:26:27AM +, Hayato Kuroda (Fujitsu) wrote: > I have no comments for the v3 patch. Thanks for reviewing! Does anyone else have thoughts on the patch? -- Nathan Bossart Amazon Web Services: https://aws.amazon.com

Re: predefined role(s) for VACUUM and ANALYZE

2022-11-28 Thread Nathan Bossart
On Mon, Nov 28, 2022 at 12:13:13PM -0500, Andrew Dunstan wrote: > pushed. Thanks! -- Nathan Bossart Amazon Web Services: https://aws.amazon.com

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

2022-11-28 Thread Nathan Bossart
Nov 28, 2022 at 1:31 PM Andres Freund wrote: >> On 2022-11-28 13:08:57 +, Simon Riggs wrote: >> > On Sun, 27 Nov 2022 at 23:34, Nathan Bossart >> > wrote: >> > > > Rather than explicitly use DEBUG1 everywhere I would have an >> > > > #defin

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

2022-11-29 Thread Nathan Bossart
odule. Of course. I found some existing tests for the test_decoding plugin that appear to reliably generate the files we want the custodian to clean up, so I added them there. -- Nathan Bossart Amazon Web Services: https://aws.amazon.com >From d8342d121d39d04e995986b4244abf369b833730 Mon Sep 1

Re: wake up logical workers after ALTER SUBSCRIPTION

2022-11-29 Thread Nathan Bossart
se changes are worthwhile. I think there's a good chance it would become a game of whac-a-mole. -- Nathan Bossart Amazon Web Services: https://aws.amazon.com

Re: wake up logical workers after ALTER SUBSCRIPTION

2022-11-29 Thread Nathan Bossart
On Wed, Nov 30, 2022 at 05:27:40PM +1300, Thomas Munro wrote: > On Wed, Nov 30, 2022 at 5:23 PM Thomas Munro wrote: >> On Wed, Nov 30, 2022 at 5:10 PM Nathan Bossart >> wrote: >> > I spent some more time on the prevent-unnecessary-wakeups patch for >> > logical

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

2022-11-29 Thread Nathan Bossart
On Tue, Nov 29, 2022 at 07:56:53PM -0800, Nathan Bossart wrote: > On Tue, Nov 29, 2022 at 12:02:44PM +, Simon Riggs wrote: >> The last important point for me is tests, in src/test/modules >> probably. It might be possible to reuse the final state of other >> modules'

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

2022-12-01 Thread Nathan Bossart
dback. I intend to pick that up in a new thread. I haven't thought too much about the others yet. > Another comment: > IIUC, there's no custodian_delay GUC as we want to avoid unnecessary > wakeups for power savings (being discussed in the other thread). > However, can it h

Re: wake up logical workers after ALTER SUBSCRIPTION

2022-12-01 Thread Nathan Bossart
On Tue, Nov 29, 2022 at 09:04:41PM -0800, Nathan Bossart wrote: > I don't mind fixing it! There are a couple more I'd like to track down > before posting another revision. Okay, here is a new version of the patch. This seems to clear up everything that I could find via the t

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

2022-12-02 Thread Nathan Bossart
On Fri, Dec 02, 2022 at 12:11:35PM +0530, Bharath Rupireddy wrote: > On Fri, Dec 2, 2022 at 3:10 AM Nathan Bossart > wrote: >> The test appears to reliably create snapshot and mapping files, so if the >> directories are empty at some point after the checkpoint at the end, we ca

Re: wake up logical workers after ALTER SUBSCRIPTION

2022-12-02 Thread Nathan Bossart
On Thu, Dec 01, 2022 at 04:21:30PM -0800, Nathan Bossart wrote: > Okay, here is a new version of the patch. This seems to clear up > everything that I could find via the tests. I cleaned up the patch a bit. -- Nathan Bossart Amazon Web Services: https://aws.amazon.com

suppressing useless wakeups in logical/worker.c

2022-12-02 Thread Nathan Bossart
ached patch applied, those periodic wakeups are gone, so we need to make sure we wake up the logical workers as needed. [0] https://postgr.es/m/CA%2BhUKGJGhX4r2LPUE3Oy9BX71Eum6PBcS8L3sJpScR9oKaTVaA%40mail.gmail.com [1] https://postgr.es/m/20221122004119.GA132961%40nathanxps13 -- Nathan Bossart A

Re: WAL Insertion Lock Improvements (was: Re: Avoid LWLockWaitForVar() for currently held WAL insertion lock in WaitXLogInsertionsToFinish())

2022-12-02 Thread Nathan Bossart
oducing memory ordering bugs. Perhaps I am missing something obvious. -- Nathan Bossart Amazon Web Services: https://aws.amazon.com

Re: Generate pg_stat_get_* functions with Macros

2022-12-02 Thread Nathan Bossart
les_returned */ > +PGSTAT_DEFINE_REL_INT64_FIELD_ACCESSOR(pg_stat_get_, tuples_returned); > + > +/* pg_stat_get_tuples_fetched */ > +PGSTAT_DEFINE_REL_INT64_FIELD_ACCESSOR(pg_stat_get_, tuples_fetched); Can we hard-code the prefix in the macro? It looks like all of these use the same one. -- N

<    4   5   6   7   8   9   10   11   12   13   >