On Sat, Feb 18, 2023 at 09:31:30AM +0530, Amit Kapila wrote:
> On Fri, Feb 17, 2023 at 9:05 PM Julien Rouhaud wrote:
> >
> > I'm concerned about people not coming from physical replication. If you
> > just
> > had some "normal" logical replication, you can't assume that you already
> > have
> >
On Fri, Feb 17, 2023 at 12:14 PM Hayato Kuroda (Fujitsu)
wrote:
>
> Thank you for replying! This direction seems OK, so I started to revise the
> patch.
> PSA new version.
>
Few comments:
=
1.
+
+ The minimum delay for publisher sends data, in milliseconds
+
+
On Fri, Feb 17, 2023 at 10:44:49PM +0100, Daniel Gustafsson wrote:
> When adding a check to pg_upgrade a while back I noticed in a profile that the
> cluster compatibility check phase spend a lot of time in connectToServer.
> Some
> of this can be attributed to data type checks which each run ser
pá 17. 2. 2023 v 21:43 odesílatel Jeff Davis napsal:
> On Fri, 2023-02-17 at 18:27 +0100, Pavel Stehule wrote:
> > Today I tested icu for Czech sorting. It is a little bit slower, but
> > not too much, but it produces partially different results.
>
> Thank you for trying it.
>
> If it's a signifi
Hi
so 18. 2. 2023 v 1:37 odesílatel Amin napsal:
> Hi,
>
> I am looking for a way to define a global variable in CustomScan plugin
> that is shared between different psql backends. Is it possible without
> using shared memory? Does postgresql implement any function that
> facilitates this?
>
N
On Fri, Feb 17, 2023 at 9:05 PM Julien Rouhaud wrote:
>
> On Fri, Feb 17, 2023 at 04:12:54PM +0530, Amit Kapila wrote:
> > On Fri, Feb 17, 2023 at 1:24 PM Julien Rouhaud wrote:
> > >
> > > An easy workaround that I tried is to allow something like
> > >
> > > ALTER SUBSCRIPTION ... ENABLE WITH (
On Fri, Feb 17, 2023 at 9:43 AM Andres Freund wrote:
>
> On 2023-02-17 08:30:09 +0530, Amit Kapila wrote:
> > Thanks, I was not completely sure about whether we need to bump
> > XLOG_PAGE_MAGIC for this patch as this makes the additional space just
> > by changing the datatype of one of the member
Thanks for the review!
>+
>+ ParallelVacuumFinish
>+ Waiting for parallel vacuum workers to finish index
>vacuum.
>+
>This change is out-of-date.
That was an oversight. Thanks for catching.
>Total number of indexes that will be vacuumed or cleaned
Hi,
On 2023-02-18 13:27:04 +1300, Thomas Munro wrote:
> I still have no theory for how this condition was reached despite a
> lot of time thinking about it and searching for more clues. As far as
> I can tell, the recent improvements to postmaster's signal and event
> handling shouldn't be relate
Hi,
While trying to add additional File* functions (FileZero, FileFallocat) I went
back and forth about the argument order between "amount" and "offset".
We have:
extern int FilePrefetch(File file, off_t offset, off_t amount, uint32
wait_event_info);
extern int FileRead(File file, void *buffer,
Hi,
I am looking for a way to define a global variable in CustomScan plugin
that is shared between different psql backends. Is it possible without
using shared memory? Does postgresql implement any function that
facilitates this?
Thank you,
Amin
I still have no theory for how this condition was reached despite a
lot of time thinking about it and searching for more clues. As far as
I can tell, the recent improvements to postmaster's signal and event
handling shouldn't be related: the state management and logic was
unchanged.
While failing
On Thu, Feb 02, 2023 at 09:48:08PM -0800, Nathan Bossart wrote:
> rebased for cfbot
another rebase for cfbot
--
Nathan Bossart
Amazon Web Services: https://aws.amazon.com
>From 1c9b95cae7adcc57b7544a44ff16a26e71c6c736 Mon Sep 17 00:00:00 2001
From: Nathan Bossart
Date: Wed, 5 Jan 2022 19:24:22
On Thu, 2023-02-16 at 18:00 +0530, Bharath Rupireddy wrote:
> I'm attaching the patches here. For HEAD, I'd
> want to be a bit defensive and use the temporary memory context for
> pg_get_wal_fpi_info() too.
I don't see why we shouldn't backpatch that, too?
Also, it seems like we should do the sam
On Fri, 2023-02-17 at 12:50 -0800, Andres Freund wrote:
> I think we just drop/recreate template1 and postgres during
> pg_upgrade.
Thank you, that makes much more sense now.
I was confused because pg_upgrade loops through to check compatibility
with all the databases, which makes zero sense if i
On Fri, Feb 17, 2023 at 10:44:49PM +0100, Daniel Gustafsson wrote:
> In the trivial case, a single database, I don't see a reduction of performance
> over the current approach. In a cluster with 100 (empty) databases there is a
> ~15% reduction in time to run a --check pass. While it won't move t
Here is a new revision of the restore modules patch set. In this patch
set, the interface looks similar to the recent archive modules redesign,
and there are separate callbacks for retrieving different types of files.
I've attempted to address all the feedback I've received, but there was a
lot sc
On Fri, Feb 17, 2023 at 03:13:32PM +0100, Peter Eisentraut wrote:
> On 16.02.23 22:29, Andres Freund wrote:
>> What's the story behind 100_bugs.pl? This name clearly is copied from
>> src/test/subscription/t/100_bugs.pl - but I've never understood why that is
>> outside of the normal numbering spac
On Fri, Feb 17, 2023 at 05:01:47PM +0900, Michael Paquier wrote:
> All that had better
> be put into their own threads, IMO, to bring more visibility on these
> subjects.
I created a new thread for these [0].
> Saying that, I have spent more time on the revamped version of the
> archive modules a
On Fri, Feb 17, 2023 at 1:14 AM Jim Jones wrote:
> After your comment I'm studying the possibility to extend the existing
> xmlserialize function to add the indentation feature. If so, how do you
> think it should look like? An extra parameter? e.g.
>
> SELECT xmlserialize(DOCUMENT '42'::XML AS t
Andres recently reminded me of some loose ends in archive modules [0], so
I'm starting a dedicated thread to address his feedback.
The first one is the requirement that archive module authors create their
own exception handlers if they want to make use of ERROR. Ideally, there
would be a handler
When adding a check to pg_upgrade a while back I noticed in a profile that the
cluster compatibility check phase spend a lot of time in connectToServer. Some
of this can be attributed to data type checks which each run serially in turn
connecting to each database to run the check, and this seemed
Hi,
On 2023-02-17 12:36:05 -0800, Jeff Davis wrote:
> > > There's already a check that the new cluster is empty, so I think
> > > it's
> > > safe to hack the pg_database locale fields.
> >
> > I don't think we need to, we do issue the CREATE DATABASEs. So we
> > just need to
> > make sure that in
"Jonathan S. Katz" writes:
> On 2/17/23 1:18 PM, Tom Lane wrote:
>> It can be reproduced with INSERT too, on the same principle as the others:
>> put the DML command inside a WITH, and give it an alias conflicting with
>> the outer query.
> Ah, I see based on your example below. I did not alias t
On Fri, 2023-02-17 at 18:27 +0100, Pavel Stehule wrote:
> Today I tested icu for Czech sorting. It is a little bit slower, but
> not too much, but it produces partially different results.
Thank you for trying it.
If it's a significant slowdown, can you please send more information?
ICU version, l
Floris Van Nee writes:
> This is as far as I can see the same case as what I reported a few years ago
> here:
> https://www.postgresql.org/message-id/flat/1574068566573.13088%40Optiver.com#488bd647ce6f5d2c92764673a7c58289
> There was a discussion with some options, but no fix back then.
Hmm, s
On Fri, 2023-02-17 at 10:09 -0800, Andres Freund wrote:
> -1. That's just going to cause pain one major version upgrade further
> down the
> line. Why would we want to incur that pain?
OK, we can just always do the fixup as long as the old one is libc and
the new one is ICU. I'm just trying to avo
On 2023-Feb-13, Andres Freund wrote:
> There's something wrong with the patch, it reliably fails with core dumps:
> https://cirrus-ci.com/github/postgresql-cfbot/postgresql/commitfest%2F42%2F3260
I think this would happen on machines where sizeof(bool) is not 1 (which
mine is evidently not). Fix
Hi,
On 2023-02-17 11:48:14 +0900, Michael Paquier wrote:
> On Thu, Feb 16, 2023 at 01:35:54PM -0800, Andres Freund wrote:
> > But why do we need it? Most SQL callable functions don't need to be careful
> > about not leaking O(1) memory, the exception being functions backing btree
> > opclasses.
>
Richard Guo writes:
> It occurs to me that we can leverage JoinDomain to tell if we are below
> the nullable side of a higher-level outer join if the clause is not an
> outer-join clause. If we are belew outer join, the current JoinDomain
> is supposed to be a proper subset of top JoinDomain. Ot
Hi,
On 2023-02-16 13:58:10 -0800, Nathan Bossart wrote:
> On Thu, Feb 16, 2023 at 01:17:54PM -0800, Andres Freund wrote:
> > I'm quite baffled by:
> > /* Close any files left open by copy_file() or compare_files()
> > */
> > AtEOSubXact_Files(false, InvalidSubTransactionId
> Kirill Reshke writes:
> > As you can see, after drop role there is invalid records in
> > pg_init_privs system relation. After this, pg_dump generate sql
> > statements, some of which are based on content of pg_init_privs, resulting
> in invalid dump.
>
This is as far as I can see the same cas
On 17.02.23 01:08, Andrey Borodin wrote:
On Thu, Feb 16, 2023 at 2:12 PM Jim Jones wrote:
I've looked into the patch. The code looks to conform to usual
expectations.
One nit: this comment should have just one asterisk.
+ /**
Thanks for reviewing! Asterisk removed in v14.
And I have a dumb
On 2/17/23 1:18 PM, Tom Lane wrote:
It can be reproduced with INSERT too, on the same principle as the others:
put the DML command inside a WITH, and give it an alias conflicting with
the outer query.
Ah, I see based on your example below. I did not alias the INSERT
statement in the way (and
Kirill Reshke writes:
> As you can see, after drop role there is invalid records in pg_init_privs
> system relation. After this, pg_dump generate sql statements, some of which
> are based on content of pg_init_privs, resulting in invalid dump.
Ugh.
> PFA fix.
I don't think this is anywhere near
On Fri, Feb 17, 2023 at 09:01:54AM -0800, Jeff Davis wrote:
> On Fri, 2023-02-17 at 00:06 -0800, Jeff Davis wrote:
> > On Tue, 2023-02-14 at 09:59 -0800, Andres Freund wrote:
> > > I am saying that pg_upgrade should be able to deal with the
> > > difference. The
> > > details of how to implement th
"Jonathan S. Katz" writes:
> I spoke too soon -- I was looking at the wrong logs. I did reproduce it
> with UPDATE, but not INSERT.
It can be reproduced with INSERT too, on the same principle as the others:
put the DML command inside a WITH, and give it an alias conflicting with
the outer query.
Hi,
On 2023-02-17 10:00:41 -0800, Jeff Davis wrote:
> I guess I'm fine hacking pg_upgrade, but I think I'd like to make it
> conditional on this specific case: only perform the fixup if the old
> cluster is 15 or earlier and using libc and the newer cluster is 16 or
> later and using icu.
-1. Tha
On Fri, 2023-02-17 at 09:05 -0800, Andres Freund wrote:
> > Thinking about this more, it's not clear to me if this would be in
> > scope for pg_upgrade or not.
>
> I don't think we should consider changing the default collation
> provider
> without making this more seamless, one way or another.
I
Hi,
On 2023-02-17 17:26:20 +1300, David Rowley wrote:
> I didn't hear it mentioned explicitly here, but I suspect it's faster
> when increasing the initial size due to the memory context caching
> code that reuses aset MemoryContexts (see context_freelists[] in
> aset.c). Since we reset the contex
Hi,
On 2023-02-17 16:19:46 +0900, Michael Paquier wrote:
> But it looks like I misunderstood what this quote meant compared to
> what v3 does. It is true that v3 sets iov_len and iov_base more than
> needed when writing sizes larger than BLCKSZ.
I don't think it does for writes larger than BLCKS
pá 17. 2. 2023 v 18:02 odesílatel Jeff Davis napsal:
> On Fri, 2023-02-17 at 00:06 -0800, Jeff Davis wrote:
> > On Tue, 2023-02-14 at 09:59 -0800, Andres Freund wrote:
> > > I am saying that pg_upgrade should be able to deal with the
> > > difference. The
> > > details of how to implement that, d
Hi,
On 2023-02-17 09:01:54 -0800, Jeff Davis wrote:
> On Fri, 2023-02-17 at 00:06 -0800, Jeff Davis wrote:
> > On Tue, 2023-02-14 at 09:59 -0800, Andres Freund wrote:
> > > I am saying that pg_upgrade should be able to deal with the
> > > difference. The
> > > details of how to implement that, don
On Fri, 2023-02-17 at 00:06 -0800, Jeff Davis wrote:
> On Tue, 2023-02-14 at 09:59 -0800, Andres Freund wrote:
> > I am saying that pg_upgrade should be able to deal with the
> > difference. The
> > details of how to implement that, don't matter that much.
>
> To clarify, you're saying that pg_upg
On Thu, Feb 16, 2023 at 10:59 PM Michael Paquier wrote:
> I am adding Stephen Frost
> in CC to see if he has any comments about all this part of the logic
> with gssencmode.
Sounds good.
> I agree that
> PQconnectPoll() has grown beyond the point of making it easy to
> maintain. I am wondering
On Fri, Feb 17, 2023 at 4:02 AM Pavel Luzanov
wrote:
>List of roles
> Role name | Attributes |
> Member of
>
> ---++---
> admin | C
On Fri, Feb 17, 2023 at 12:03 AM David Rowley wrote:
> On Fri, 17 Feb 2023 at 17:40, Jonah H. Harris
> wrote:
> > Yeah. There’s definitely a smarter and more reusable approach than I was
> proposing. A lot of that code is fairly mature and I figured more people
> wouldn’t want to alter it in suc
Hi hackers!
Recently we faced a problem with one of our production clusters. Problem
was with pg_upgrade,
the reason was an invalid pg_dump of cluster schema. in pg_dump sql there
was strange records like
REVOKE SELECT,INSERT,DELETE,UPDATE ON TABLE *relation* FROM "144841";
but there is no role
On 2/17/23 11:19 AM, Jonathan S. Katz wrote:
On 2/17/23 10:09 AM, Tom Lane wrote:
Agreed on that -- while it's harder to set up, I do prefer the original
example[1] to demonstrate this, as it shows the issue given it does not
have those multiple occurrences, at least not within the same conte
On 2/17/23 10:09 AM, Tom Lane wrote:
"Jonathan S. Katz" writes:
Good catch. Do you have thoughts on how we can adjust the naming logic
to handle cases like this?
I think it's perfectly fine that ruleutils decided to use different
aliases for the two different occurrences of "t1": the statemen
Thank you, I moved comment changes to 0001 and rewrote the fix through Min().
> The first hunk in 0001 doesn't seem quite right yet:
>
> * old allocation.
> */
> #ifdef USE_VALGRIND
> -if (oldsize > chunk->requested_size)
> +if (size > chunk->requested_size &&
> On Thu, Feb 09, 2023 at 08:43:29PM +0100, Dmitry Dolgov wrote:
> > On Thu, Feb 09, 2023 at 06:26:51PM +0100, Alvaro Herrera wrote:
> > On 2023-Feb-09, Dmitry Dolgov wrote:
> >
> > > > On Thu, Feb 09, 2023 at 02:30:34PM +0100, Peter Eisentraut wrote:
> >
> > > > What is the point of making this a
> On Wed, Feb 15, 2023 at 08:51:56AM +0100, David Geier wrote:
> Hi,
>
> On 2/11/23 13:08, Dmitry Dolgov wrote:
> > > On Sat, Feb 11, 2023 at 11:47:07AM +0100, Dmitry Dolgov wrote:
> > >
> > > The original version of the patch was doing all of this, i.e. handling
> > > numerics, Param nodes, RTE_VA
Hi,
On Fri, Feb 17, 2023 at 04:12:54PM +0530, Amit Kapila wrote:
> On Fri, Feb 17, 2023 at 1:24 PM Julien Rouhaud wrote:
> >
> > An easy workaround that I tried is to allow something like
> >
> > ALTER SUBSCRIPTION ... ENABLE WITH (refresh = true, copy_data = false)
> >
> > so that the refresh i
"Jonathan S. Katz" writes:
> Good catch. Do you have thoughts on how we can adjust the naming logic
> to handle cases like this?
I think it's perfectly fine that ruleutils decided to use different
aliases for the two different occurrences of "t1": the statement is
quite confusing as written. Th
Hi,
On 2/16/23 1:26 PM, Drouvot, Bertrand wrote:
Hi,
On 2/16/23 12:00 PM, Amit Kapila wrote:
BTW, feel free to create the second patch
(to align the types for variables/arguments) as that would be really
helpful after we commit this one.
Please find attached a patch proposal to do so.
It l
On 16.02.23 22:29, Andres Freund wrote:
What's the story behind 100_bugs.pl? This name clearly is copied from
src/test/subscription/t/100_bugs.pl - but I've never understood why that is
outside of the normal numbering space.
Mainly to avoid awkwardness for backpatching. The number of tests in
On 2/17/23 5:22 AM, vignesh C wrote:
Hi,
The output sql generated by pg_dump for the below function refers to a
modified table name:
create table t1 (c1 int);
create table t2 (c1 int);
CREATE OR REPLACE FUNCTION test_fun(c1 int)
RETURNS void
LANGUAGE SQL
BEGIN ATOMIC
WITH delete_t1 AS (
On Fri, 2023-02-17 at 14:40 +0900, Michael Paquier wrote:
> Separate question: what's the state of the Windows installers provided
> by the community regarding libicu? Is that embedded in the MSI?
The EDB installer installs a quite old version of the ICU library
for compatibility reasons, as far
On 2023-Feb-17, Alvaro Herrera wrote:
> I tried a few things for a new test case, but I was unable to find
> anything useful. Maybe an intermediate view, I thought; no dice.
> Maybe one with a security barrier would do? Anyway, for now I just kept
> what you added in v2.
Sorry, I failed to keep
On 2022-Dec-11, Amit Langote wrote:
> While staring at the build_simple_rel() bit mentioned above, I
> realized that this code fails to set userid correctly in the
> inheritance parent rels that are child relations of subquery parent
> relations, such as UNION ALL subqueries. In that case, instea
On Fri, 17 Feb 2023 at 02:38, Jonathan S. Katz wrote:
>
> On 2/16/23 2:43 PM, Jonathan S. Katz wrote:
> > On 2/16/23 2:38 PM, Alvaro Herrera wrote:
> >> On 2023-Feb-16, Jonathan S. Katz wrote:
> >>
> >>> On 2/16/23 12:53 PM, Alvaro Herrera wrote:
> >>
> I don't think this is the fault of logi
Hello,
On the one hand, it would be nice to see the membership options with
the psql command.
After playing with cf5eb37c and e5b8a4c0 I think something must be made
with \du command.
postgres@demo(16.0)=# CREATE ROLE admin LOGIN CREATEROLE;
CREATE ROLE
postgres@demo(16.0)=# \c - admin
You a
Hi,
On 2/16/23 19:13, Andres Freund wrote:
+#define WALSTAT_ACC(fld, var_to_add) \
+ (stats_shmem->stats.fld += var_to_add.fld)
+#define WALLSTAT_ACC_INSTR_TIME_TYPE(fld) \
+ (stats_shmem->stats.fld += INSTR_TIME_GET_MICROSEC(PendingWalStats.fld))
+ WALSTAT_ACC(wal_records, di
On Fri, Feb 17, 2023 at 1:24 PM Julien Rouhaud wrote:
>
> I was working on testing a major upgrade scenario using a mix of physical and
> logical replication when I faced some unexpected problem leading to missing
> rows. Note that my motivation is to rely on physical replication / physical
> bac
Hi,
The output sql generated by pg_dump for the below function refers to a
modified table name:
create table t1 (c1 int);
create table t2 (c1 int);
CREATE OR REPLACE FUNCTION test_fun(c1 int)
RETURNS void
LANGUAGE SQL
BEGIN ATOMIC
WITH delete_t1 AS (
DELETE FROM t1 WHERE c1 = $1
On Fri, Feb 17, 2023 at 10:58 AM Zheng Li wrote:
>
> > > > Actually, I intend something for global objects. But the main thing
> > > > that is worrying me about this is that we don't have a clean way to
> > > > untie global object replication from database-specific object
> > > > replication.
> >
Greetings,
* Michael Paquier (mich...@paquier.xyz) wrote:
> On Mon, Sep 19, 2022 at 02:05:39PM -0700, Jacob Champion wrote:
> > It's not prevented, because a password is being used. In my tests I'm
> > connecting as an unprivileged user.
> >
> > You're claiming that the middlebox shouldn't be doi
On Fri, Feb 17, 2023 at 1:13 AM Jonathan S. Katz wrote:
>
> On 2/16/23 2:38 PM, Alvaro Herrera wrote:
> > On 2023-Feb-16, Jonathan S. Katz wrote:
> >
> >> On 2/16/23 12:53 PM, Alvaro Herrera wrote:
> >
> >>> I don't think this is the fault of logical replication. Consider that
> >>> for the backe
On 16.02.23 05:38, Nikolay Samokhvalov wrote:
On Thu, Feb 9, 2023 at 2:31 AM Peter Eisentraut
wrote:
I suggest we call it "xmlformat", which is an established term for
this.
Some very-very old, rusted memory told me that there was something in
standard – and indeed, it seems it desc
Thank you for having a look at this.
On Fri, 17 Feb 2023 at 14:01, Andres Freund wrote:
> > +set_ps_display_suffix(const char *suffix)
> > +{
> > + size_t len;
>
> Think this will give you an unused-variable warning in the PS_USE_NONE case.
Fixed
> > +#ifndef PS_USE_NONE
> > + /* updat
Hi,
Here is a small patch to improve the note, which was added by commit
97da48246 ("Allow batch insertion during COPY into a foreign table."),
by adding an explanation about how the actual number of rows
postgres_fdw inserts at once is determined in the COPY case, including
a limitation that does
On 2023-02-09 23:39, Hayato Kuroda (Fujitsu) wrote:
Dear Katsuragi-san,
Thank you for reviewing! PSA new version patches.
Thank you for updating the patch! These are my comments,
please check.
0001:
Extending pqSocketPoll seems to be a better way because we can
avoid having multiple similar f
Hi,
On 2/17/23 3:35 AM, Michael Paquier wrote:
On Thu, Feb 16, 2023 at 10:55:32AM +0100, Drouvot, Bertrand wrote:
In the new pg_stat_statements.sql? That way pg_stat_statements.sql would always
behave
with default values for those (currently we are setting both of them as non
default).
Then,
On Tue, 2023-02-14 at 09:59 -0800, Andres Freund wrote:
> I am saying that pg_upgrade should be able to deal with the
> difference. The
> details of how to implement that, don't matter that much.
To clarify, you're saying that pg_upgrade should simply update
pg_database to set the new databases' c
On Thu, Feb 16, 2023 at 01:17:54PM -0800, Andres Freund wrote:
> On 2023-02-16 12:15:12 -0800, Nathan Bossart wrote:
>> On Thu, Feb 16, 2023 at 11:29:56AM -0800, Andres Freund wrote:
>>> Not related the things changed here, but this should never have been pushed
>>> down into individual archive mod
On Thu, Feb 16, 2023 at 11:44 PM Andres Freund wrote:
>
> Hi,
>
> On 2023-02-16 16:22:56 +0700, John Naylor wrote:
> > On Thu, Feb 16, 2023 at 10:24 AM Masahiko Sawada
> > > Right. TidStore is implemented not only for heap, so loading
> > > out-of-order TIDs might be important in the future.
> >
77 matches
Mail list logo