Question on io_min_workers > io_max_workers semantics - Mailing list pgsql-hackers

From Xuneng Zhou
Subject Question on io_min_workers > io_max_workers semantics
Date
Msg-id CABPTF7U0wzdGcNUxtwxO9p86k3p0KoEJWZQBKg+Ve8pAiDtfqA@mail.gmail.com
Whole thread
List pgsql-hackers
Hi Thomas, Hackers,

While looking at d1c01b79d4ae (aio: Adjust I/O worker pool
automatically), I had a question about the intended semantics for
io_min_workers > io_max_workers.

Both GUCs currently have independent 1..MAX_IO_WORKERS range checks,
so a configuration such as:

io_min_workers = 32 io_max_workers = 1

is accepted. In maybe_start_io_workers_scheduled_at(), the
io_max_workers check comes first, so io_max_workers effectively caps
the minimum:

if (io_worker_count >= io_max_workers) return 0;
if (io_worker_count < io_min_workers) return TIMESTAMP_MINUS_INFINITY;

Is that intended? If so, should we document that the effective minimum
is capped by io_max_workers, or perhaps emitting a warning similar to
the autovacuum_max_workers / autovacuum_worker_slots case?

-- 
Best,
Xuneng



pgsql-hackers by date:

Previous
From: shveta malik
Date:
Subject: Re: Include schema-qualified names in publication error messages.
Next
From: Nisha Moond
Date:
Subject: Re: Proposal: Conflict log history table for Logical Replication