Re: recovery modules

From: Nathan Bossart <nathandbossart(at)gmail(dot)com>
To: Andres Freund <andres(at)anarazel(dot)de>
Cc: Michael Paquier <michael(at)paquier(dot)xyz>, pgsql-hackers(at)postgresql(dot)org
Subject: Re: recovery modules
Date: 2023-02-01 20:15:29
Message-ID: 20230201201529.GA3551058@nathanxps13
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Wed, Feb 01, 2023 at 03:54:26AM -0800, Andres Freund wrote:
> I'd make basic_archive's private data a struct, with a member for the
> context, but it's not that important.
>
> I'd also be inclined to do the same for the private_state you're passing
> around for each module. Even if it's just to reduce the number of
> functions accepting void * - loosing compiler type checking isn't great.
>
> So maybe an ArchiveModuleState { void *private_data } that's passed to
> basic_archive_startup() and all the other callbacks.

Here's a new patch set in which I've attempted to address this feedback and
Michael's feedback.

--
Nathan Bossart
Amazon Web Services: https://aws.amazon.com

Attachment Content-Type Size
v3-0001-s-ArchiveContext-ArchiveCallbacks.patch text/x-diff 2.8 KB
v3-0002-move-archive-module-exports-to-dedicated-headers.patch text/x-diff 6.8 KB
v3-0003-restructure-archive-modules-API.patch text/x-diff 13.8 KB

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Tom Lane 2023-02-01 20:34:52 Re: pg_dump versus hash partitioning
Previous Message Sergey Dudoladov 2023-02-01 19:59:39 Re: Introduce "log_connection_stages" setting.