minor fix related to Auxiliary processes and IO workers

Started by Cédric Villemain12 months ago5 messageshackers
Jump to latest
#1Cédric Villemain
cedric.villemain@data-bene.io

Hello Andres,

I noticed a comment in "include/miscadmin.h" which might be need a fix:
it states that there is a single auxiliary process of each kind running
at once.

However, with IO workers it's not true anymore I believe.
See minor patch attached.

---
Cédric Villemain +33 6 20 30 22 52
https://www.Data-Bene.io
PostgreSQL Support, Expertise, Training, R&D

Attachments:

0001-Fix-comment-on-auxiliary-processes-for-IO-workers.patchtext/x-patch; charset=UTF-8; name=0001-Fix-comment-on-auxiliary-processes-for-IO-workers.patchDownload+1-2
#2Michael Paquier
michael@paquier.xyz
In reply to: Cédric Villemain (#1)
Re: minor fix related to Auxiliary processes and IO workers

On Tue, May 06, 2025 at 06:25:24PM +0200, Cédric Villemain wrote:

@@ -353,7 +353,7 @@ typedef enum BackendType
* Auxiliary processes. These have PGPROC entries, but they are not
* attached to any particular database, and cannot run transactions or
* even take heavyweight locks. There can be only one of each of these
-	 * running at a time.
+	 * running at a time, except for IO worker.

Right. Perhaps this should say "IO workers", no?
--
Michael

#3Cédric Villemain
cedric.villemain@data-bene.io
In reply to: Michael Paquier (#2)
Re: minor fix related to Auxiliary processes and IO workers

On 07/05/2025 01:52, Michael Paquier wrote:

On Tue, May 06, 2025 at 06:25:24PM +0200, Cédric Villemain wrote:

@@ -353,7 +353,7 @@ typedef enum BackendType
* Auxiliary processes. These have PGPROC entries, but they are not
* attached to any particular database, and cannot run transactions or
* even take heavyweight locks. There can be only one of each of these
-	 * running at a time.
+	 * running at a time, except for IO worker.

Right. Perhaps this should say "IO workers", no?

Sure, modified this way.

---
Cédric Villemain +33 6 20 30 22 52
https://www.Data-Bene.io
PostgreSQL Support, Expertise, Training, R&D

Attachments:

0001-Fix-comment-on-auxiliary-processes-for-IO-workers.patchtext/x-patch; charset=UTF-8; name=0001-Fix-comment-on-auxiliary-processes-for-IO-workers.patchDownload+1-2
#4Michael Paquier
michael@paquier.xyz
In reply to: Cédric Villemain (#3)
Re: minor fix related to Auxiliary processes and IO workers

On Wed, May 07, 2025 at 03:25:07AM +0200, Cédric Villemain wrote:

Sure, modified this way.

I have detected two more of these under NumProcSignalSlots and
NumProcStateSlots. NUM_AUXILIARY_PROCS is adjusted in both cases with
MAX_IO_WORKERS, which is OK, but their comments were incorrect.

Adjusted these two as well, applied the result.
--
Michael

#5Cédric Villemain
cedric.villemain@data-bene.io
In reply to: Michael Paquier (#4)
Re: minor fix related to Auxiliary processes and IO workers

On 07/05/2025 07:56, Michael Paquier wrote:

On Wed, May 07, 2025 at 03:25:07AM +0200, Cédric Villemain wrote:

Sure, modified this way.

I have detected two more of these under NumProcSignalSlots and
NumProcStateSlots. NUM_AUXILIARY_PROCS is adjusted in both cases with
MAX_IO_WORKERS, which is OK, but their comments were incorrect.

Adjusted these two as well, applied the result.

Thank you for the other edits.

---
Cédric Villemain +33 6 20 30 22 52
https://www.Data-Bene.io
PostgreSQL Support, Expertise, Training, R&D