receiver_raw
============

This module is a background worker able to receive changes generated by
the logical replication output plugin called decoder_raw that generates raw
SQL queries that can be applied to remote sources.

This module has still very basic features, but it is able to receive changes
and start logical replication with a remote server as well as to apply changes
to a local database.

Options
-------

The following options are available:

- receiver_raw.database, database name on which changes are applied.
Default value is "postgres".
- receiver_raw.slot_name, slot name used to fetch logical changes on
remote. Default value is "slot".
- receiver_raw.conn_string, connection string used to connect to remote
server from which logical changes are taken. Default is the following:
replication=database dbname=postgres application_name=receiver_raw
Note that if replication is not set this bgworker is easily broken...
- receiver.idle_time, amount of time between two loops, time between which
two successive batches of changes are applied.
- receiver.sync_mode, to enforce sending feedback to server each time a
keepalive message is received. Useful for synchronous replication with
this logical receiver. Default is 'on'.

Notes
-----

Before running this background worker, be sure that the schema between
the two servers is consistent between the two databases that are linked.

This worker is compatible with PostgreSQL 9.4 and newer versions.

TODO
----

- Add a check to be sure that decoder_raw is used upstream
