Re: proposal: Allocate work_mem From Pool

From: Justin Pryzby <pryzby(at)telsasoft(dot)com>
To: Joseph D Wagner <joe(at)josephdwagner(dot)info>
Cc: pgsql-hackers(at)lists(dot)postgresql(dot)org
Subject: Re: proposal: Allocate work_mem From Pool
Date: 2022-07-12 14:39:59
Message-ID: 20220712143959.GZ13040@telsasoft.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Tue, Jul 12, 2022 at 03:55:39AM -0700, Joseph D Wagner wrote:
> Before I try to answer that, I need to know how the scheduler works.
>
> Let's say there's a max of 8 worker process, and 12 queries trying to run.
> When does query #9 run? After the first of 1-8 completes, simple FIFO?
> Or something else?
>
> Also, how long goes a query hold a worker process? All the way to
> completion? Or does is perform some unit of work and rotate to
> another query?

I think what you're referring to as a worker process is what postgres refers to
as a "client backend" (and not a "parallel worker", even though that sounds
more similar to your phrase).

> P.S. If there's a link to all this somewhere, please let me know.
> Parsing through years of email archives is not always user friendly or
> helpful.

Looking at historic communication is probably the easy part.
Here's some to start you out.
https://www.postgresql.org/message-id/flat/4d39869f4bdc42b3a43004e3685ac45d%40index.de

--
Justin

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Alvaro Herrera 2022-07-12 15:20:59 test_oat_hooks bug (was: Re: pgsql: Add copy/equal support for XID lists)
Previous Message Tom Lane 2022-07-12 14:36:45 Re: pgsql: Add copy/equal support for XID lists