Re: Passing values to a dynamic background worker

From: Keith Fiske <keith(at)omniti(dot)com>
To: Peter Eisentraut <peter(dot)eisentraut(at)2ndquadrant(dot)com>
Cc: PostgreSQL Hackers <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: Passing values to a dynamic background worker
Date: 2017-04-18 20:00:48
Message-ID: CAG1_KcCZEmwx9ShiEk6ZwfeJqOg3sm_arrStY6bU25E61fM6NQ@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Tue, Apr 18, 2017 at 12:34 PM, Peter Eisentraut <
peter(dot)eisentraut(at)2ndquadrant(dot)com> wrote:

> On 4/17/17 16:19, Keith Fiske wrote:
> > I've reached a roadblock in that bgw_main_arg can only accept a single
> > argument that must be passed by value for a dynamic bgw. I already
> > worked around this for passing the database name to the my existing use
> > of a bgw with doing partition maintenance (pass a simple integer to use
> > as an index array value). But I'm not sure how to do this for passing
> > multiple values in.
>
> You can also store this kind of information in a table.
>
> --
> Peter Eisentraut http://www.2ndQuadrant.com/
> PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services
>

True, but that seemed like the easy way out. :) Trying to find ways to
learn internals better through projects I'm actively working on.

Keith

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Fabien COELHO 2017-04-18 21:06:38 Re: Other formats in pset like markdown, rst, mediawiki
Previous Message Tom Lane 2017-04-18 19:57:09 Re: Inadequate parallel-safety check for SubPlans