Unverified Commit 0c4e4334 authored by Dimitri Fontaine's avatar Dimitri Fontaine Committed by GitHub
Browse files

Assorted streaming fixes, including skipping of empty transactions. (#257)

* Assorted streaming fixes, including skipping of empty transactions.

* Fix memory management of JSON buffers when parsing Logical Messages.

Now that we need to keep around the previous LogicalMessageMetadata, we also
need to keep around its JSON buffer. This means we can't re-use the pointer
to the current context buffer, and we need to duplicate memory even when
using wal2json and keeping the same JSON buffer as received.

In passing, adjust the JSON files in the test suite according to the new
empty transactions filtering and synthetic KEEPALIVE situation.

* Atttempt to fix CI errors (exit code 141).

The exit code 141 is 128 + 13, and 13 is SIGPIPE. It means that in our
cdc-low-level test case when doing receive | transform | apply, one of the
processes is trying to write to its output pipe when the next process has
already exited, or at least closed its pipe input file descriptor.

By ignoring SIGPIPE we ask the system to return EPIPE at write time. Let's
now see how our code handles that.
parent 0f3db399
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment