Re: cpu-intensive immutable function and parallel scan - Mailing list pgsql-general

From David Rowley
Subject Re: cpu-intensive immutable function and parallel scan
Date
Msg-id CAApHDvrBHyx=1kng+QbcN7B=nbn8ZbxN0gvK35gXaea7sSFpiA@mail.gmail.com
Whole thread Raw
In response to cpu-intensive immutable function and parallel scan  (Niels Jespersen <NJN@dst.dk>)
Responses Re: cpu-intensive immutable function and parallel scan
SV: cpu-intensive immutable function and parallel scan
List pgsql-general
On Tue, 22 Jun 2021 at 19:06, Niels Jespersen <NJN@dst.dk> wrote:
> I think I could achieve some speedup by parallelizing further, distributing the cpu-work among additional workers.
But,how do I achive that best?
 

You'll want to ensure max_parallel_workers_per_gather is set high
enough and you have max_parallel_workers set to something high enough.
You can then do:

alter table t1 set (parallel_workers = <number of workers>);

David



pgsql-general by date:

Previous
From: Niels Jespersen
Date:
Subject: cpu-intensive immutable function and parallel scan
Next
From: Mike Yeap
Date:
Subject: Postgres PANIC when it could not open file in pg_logical/snapshots directory