[HACKERS] Increasing parallel workers at runtime - Mailing list pgsql-hackers

From Haribabu Kommi
Subject [HACKERS] Increasing parallel workers at runtime
Date
Msg-id CAJrrPGdMs8wzKEWuWgcpjrmopb9rUfnW2UMdzkzMqUMEn3BZxg@mail.gmail.com
Whole thread Raw
Responses Re: [HACKERS] Increasing parallel workers at runtime  (Dilip Kumar <dilipbalaut@gmail.com>)
Re: [HACKERS] Increasing parallel workers at runtime  (Robert Haas <robertmhaas@gmail.com>)
List pgsql-hackers

In the current parallel implementation, in case if the
number of planned workers doesn't available during
the start of the query execution, the query starts the
execution with the available number of workers till
the end of the query.

It may be possible that during the query processing
the required number of workers may be available.
so how about increasing the parallel workers to the
planned workers (only when the main backend has
going to wait for the workers send the tuples or it
has to process the plan by itself.)

The wait of the workers to send tuples is may be
because of less number of workers. So increasing
the parallel workers may improve the performance.

POC Patch attached for the same.

This still needs some adjustments to fix for the cases where
the main backend also does the scan instead of waiting for
the workers to finish the job. As increasing the workers logic
shouldn't add an overhead in this case.

Regards,
Hari Babu
Fujitsu Australia
Attachment

pgsql-hackers by date:

Previous
From: Ildus Kurbangaliev
Date:
Subject: Re: [HACKERS] Bug in ExecModifyTable function and trigger issuesfor foreign tables
Next
From: Tom Lane
Date:
Subject: Re: [HACKERS] Receive buffer size for the statistics socket