Hi,
On 2020-07-29 22:26:04 -0500, David Pirotte wrote:
> FWIW, we have been using pg_logical_emit_message to send application-level
> events alongside our change-data-capture for about two years, and we would
> move this part of our stack to pgoutput if message support was available.
Yea, it's really useful for this kind of thing.
> @@ -119,14 +124,16 @@ _PG_output_plugin_init(OutputPluginCallbacks *cb)
>
> static void
> parse_output_parameters(List *options, uint32 *protocol_version,
> - List **publication_names, bool *binary)
> + List **publication_names, bool *binary, bool *messages)
I think it might be time to add a PgOutputParameters struct, instead of
adding more and more output parameters to
parse_output_parameters. Alternatively just passing PGOutputData owuld
make sense.
> diff --git a/src/test/subscription/t/015_messages.pl b/src/test/subscription/t/015_messages.pl
> new file mode 100644
> index 0000000000..4709e69f4e
> --- /dev/null
> +++ b/src/test/subscription/t/015_messages.pl
A test verifying that a non-transactional message in later aborted
transaction is handled correctly would be good.
Greetings,
Andres Freund