paint-brush
Replicate PostgreSQL Databases Using async Python and RabbitMQ for High Availabilityby@bechir
3,519 reads
3,519 reads

Replicate PostgreSQL Databases Using async Python and RabbitMQ for High Availability

by bechir7mMay 5th, 2022
Read on Terminal Reader
Read this story w/o Javascript
tldt arrow

Too Long; Didn't Read

Triggers are useful for a wide range of cases, like verifying constraints or boosting performance. In our case, we will use triggers to notify our Python listener when data has been removed or added. We define a procedure called `notify_account_changes()` that will handle sending notifications about the changes in the database. We can have many listeners on a channel by executing `LISTEN channel_name. And to send notifications, we use the `NOTIFY` command or the built-in system function `pg_notify('channel_name', 'payload')

Company Mentioned

Mention Thumbnail
featured image - Replicate PostgreSQL Databases Using async Python and RabbitMQ for High Availability
bechir HackerNoon profile picture
bechir

bechir

@bechir

Software engineering student from Tunisia. Passionate about data engineering, deep learning and solutions architecture.

About @bechir
LEARN MORE ABOUT @BECHIR'S
EXPERTISE AND PLACE ON THE INTERNET.
L O A D I N G
. . . comments & more!

About Author

bechir HackerNoon profile picture
bechir@bechir
Software engineering student from Tunisia. Passionate about data engineering, deep learning and solutions architecture.

TOPICS

THIS ARTICLE WAS FEATURED IN...

Permanent on Arweave
Read on Terminal Reader
Read this story in a terminal
 Terminal
Read this story w/o Javascript
Read this story w/o Javascript
 Lite