From: | "Euler Taveira" <euler(at)eulerto(dot)com> |
---|---|
To: | "Nathan Bossart" <nathandbossart(at)gmail(dot)com> |
Cc: | pgsql-hackers <pgsql-hackers(at)postgresql(dot)org> |
Subject: | Re: improve performance of pg_dump with many sequences |
Date: | 2024-07-11 02:52:33 |
Message-ID: | d7f5942e-00ba-4d90-9bac-f0b2b7092dc4@app.fastmail.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
On Wed, Jul 10, 2024, at 7:05 PM, Nathan Bossart wrote:
> I'm not following why that would be a better approach. strncpy() will add
> a NUL to the end of the string unless it doesn't fit in the buffer, in
> which case we'll add our own via "seqtype[sizeof(seqtype) - 1] = '\0'".
> Furthermore, the compiler can determine the position where the NUL should
> be placed, whereas placing it at the end of the copied string requires a
> runtime strlen().
Nevermind, you are copying the whole buffer (n = sizeof(seqtype)).
> Unfortunately, I think we have to keep this workaround since older minor
> releases of PostgreSQL don't have the fix.
Hmm. Right.
> What pg_dump command did you test here? Did you dump the sequence data, or
> was this --schema-only?
time pg_dump -f - -s -d postgres
--
Euler Taveira
EDB https://www.enterprisedb.com/
From | Date | Subject | |
---|---|---|---|
Next Message | Yugo NAGATA | 2024-07-11 04:23:57 | Re: Incremental View Maintenance, take 2 |
Previous Message | Zhijie Hou (Fujitsu) | 2024-07-11 02:17:17 | RE: Conflict detection and logging in logical replication |