From: | Robert Haas <robertmhaas(at)gmail(dot)com> |
---|---|
To: | Amit Kapila <amit(dot)kapila16(at)gmail(dot)com> |
Cc: | PostgreSQL Hackers <pgsql-hackers(at)lists(dot)postgresql(dot)org> |
Subject: | Re: tablespace_map code cleanup |
Date: | 2020-05-12 20:24:00 |
Message-ID: | CA+TgmoZTU8w8JnAx+7shuz4nDLN7o1vc3PnwNiZj1cppag62CA@mail.gmail.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
On Tue, May 12, 2020 at 2:23 AM Amit Kapila <amit(dot)kapila16(at)gmail(dot)com> wrote:
> While looking at this, I noticed that caller (perform_base_backup) of
> do_pg_start_backup, sets the backup phase as
> PROGRESS_BASEBACKUP_PHASE_WAIT_CHECKPOINT whereas, in
> do_pg_start_backup, we do collect the information about all
> tablespaces after the checkpoint. I am not sure if it is long enough
> that we consider having a separate phase for it. Without your patch,
> it was covered under PROGRESS_BASEBACKUP_PHASE_ESTIMATE_BACKUP_SIZE
> phase which doesn't appear to be a bad idea.
Maybe I'm confused here, but I think the size estimation still *is*
covered under PROGRESS_BASEBACKUP_PHASE_ESTIMATE_BACKUP_SIZE. It's
just that now that happens a bit later. I'm assuming that listing the
tablespaces is pretty cheap, but sizing them is expensive, as you'd
have to iterate over all the files and stat() each one.
--
Robert Haas
EnterpriseDB: http://www.enterprisedb.com
The Enterprise PostgreSQL Company
From | Date | Subject | |
---|---|---|---|
Next Message | Alvaro Herrera | 2020-05-12 20:25:24 | Re: Add "-Wimplicit-fallthrough" to default flags (was Re: pgsql: Support FETCH FIRST WITH TIES) |
Previous Message | Bruce Momjian | 2020-05-12 20:23:43 | Re: PG 13 release notes, first draft |