Sami Imseih wrote:
> > pgstat_progress_start_command() is called twice: First with
> > cmdtype=PROGRESS_COMMAND_CLUSTER, second with
> > PROGRESS_COMMAND_CREATE_INDEX. The first happens in cluster_rel() the second
> > in cluster_rel() -> rebuild_relation() -> finish_heap_swap() ->
> > reindex_rel
> pgstat_progress_start_command() is called twice: First with
> cmdtype=PROGRESS_COMMAND_CLUSTER, second with
> PROGRESS_COMMAND_CREATE_INDEX. The first happens in cluster_rel() the second
> in cluster_rel() -> rebuild_relation() -> finish_heap_swap() ->
> reindex_relation() -> reindex_index().
>
>
Sami Imseih wrote:
> >> pgstat_progress_start_command should only be called once by the entry
> >> point for the
> >> command. In theory, we could end up in a situation where start_command
> >> is called multiple times during the same top-level command;
>
> > Not only in theory - it actually hap
Fujii Masao wrote:
> On 2025/04/15 2:13, Sami Imseih wrote:
> >> While working on [1] I realized that some field of pg_stat_progress_cluste
> >> has
> >> weird value.
>
> I ran into the same issue while working on [2], and eventually had to
> withdraw that patch because of it.
Have you conside
>> pgstat_progress_start_command should only be called once by the entry
>> point for the
>> command. In theory, we could end up in a situation where start_command
>> is called multiple times during the same top-level command;
> Not only in theory - it actually happens when CLUSTER is rebuilding i
Sami Imseih wrote:
> > While working on [1] I realized that some field of pg_stat_progress_cluste
> > has
> > weird value.
>
> Is there a repro that you can share that shows the weird values? It sounds
> like
> the repro is on top of [1]. Is that right?
Yes.
> > AFAICS the current design doe
On 2025/04/15 2:13, Sami Imseih wrote:
While working on [1] I realized that some field of pg_stat_progress_cluste has
weird value.
I ran into the same issue while working on [2], and eventually had to
withdraw that patch because of it.
Is there a repro that you can share that shows the we
> While working on [1] I realized that some field of pg_stat_progress_cluste has
> weird value.
Is there a repro that you can share that shows the weird values? It sounds like
the repro is on top of [1]. Is that right?
> AFAICS the current design does not consider that one progress-reporting
> co