Skip to content

revolko/dbreplex

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

80 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

dbreplex

Prerequisite

  • erlang (OTP 28)
  • elixir (1.18.4)
  • docker (to run examples)

How to run

Either start the application with iex console:

iex -S mix run --no-halt

Or use example.exs script to quickly startup Subscribers.Postgres with Publishers.File:

iex -S mix run example.exs

Subscribers.Postgres requires running Postgres database. Checkout postgres example for a quick setup. Make sure that Publishers.File points to the existing location of your system (file does not need to exist, but parent directories must).

Finally, connect to a subscriber and execute INSERT/UPDATE/DELETE statement. The statement will be logged and saved by all publishers (in case of Publishers.File the statement is saved to a file).

Subscribers

Subscribers.Postgres 🚀

Subscriber for Postgres database. The subscriber creates logical replication connection to Postgres database. The replication connection makes database to push replication messages to the subscriber (push-based communication).

Features

  • ❌ pre-configuration of the source database
    • for now, database must correctly configure replication and publishing settings (see postgres example)
  • database statements:
    • ✅ INSERT
    • ✅ UPDATE
    • ✅ DELETE
    • ❌ TRUNCATE
  • ✅ tables without primary keys
  • ✅ tables with primary keys
  • ✅ tables with foreign keys
  • ❌ full initial load

Oracle 📌

MSSQL 📌

SQLite 📌

Publishers

Publishers.File 🚀

Publisher storing replication messages to files.

Features

  • serialized database messages:
    • ✅ INSERT
    • ✅ UPDATE
    • ✅ DELETE
    • ❌ TRUNCATE

S3Publisher 📌

PgPublisher 📌

About

Database subscription client

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages