public inbox for [email protected]
help / color / mirror / Atom feedFrom: Luca Ferrari <[email protected]>
To: pgsql-general <[email protected]>
Subject: passing a pointer from a BackgroundWorker to a DynamicBackgroundWorker
Date: Fri, 20 Dec 2024 16:57:53 +0100
Message-ID: <CAKoxK+7ZHmv_GoEvtDDKtxpFfmPGUp+D3wDtZRgLXLjNm+yL5g@mail.gmail.com> (raw)
Hi all,
I've a doubt about background workers. I've a worker (loaded by a
module via shared_preloaded_libraries) should register a dyanmic
background worker per database, in a manner similar to what autovacuum
does.
I would like to pass to these dynamic background workers a pointer to
a custom struct, that has been allocated and initialized by the "main"
background worker.
Is it sage to pass the pointer via the Datum main argument from one
worker to another? Clearly, the struct has be allocated in a shared
memory segment,but I'm not sure in which context.
Any suggestion is appreciated.
Thanks,
Luca
reply
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients using the --to and --cc options:
reply via email
To: [email protected]
Cc: [email protected], [email protected]
Subject: Re: passing a pointer from a BackgroundWorker to a DynamicBackgroundWorker
In-Reply-To: <CAKoxK+7ZHmv_GoEvtDDKtxpFfmPGUp+D3wDtZRgLXLjNm+yL5g@mail.gmail.com>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by agora; see mirroring instructions
for how to clone and mirror all data and code used for this inbox