Home / Companies / Courier / Blog / Post Details
Content Deep Dive

Hacking PostgreSQL Internals to Deliver Push Notifications

Blog post from Courier

Post Details
Company
Date Published
Author
Tejas Kumthekar
Word Count
1,209
Company Posts That Month
3
Language
English
Hacker News Points
11
Post removed?
No
Summary

PostgreSQL 14 has been released with various features including pipeline API, improved query parallelism, and enhanced replication capabilities. The database system uses Write-Ahead Logging (WAL) to ensure data integrity, which involves writing changes to the server's file system before they are acted upon by consumers. WAL records can be replicated across multiple servers using a file-based or streaming approach, with the latter being typically asynchronous but can be tuned to be synchronous. Logical decoding is used to extract persistent changes from database tables into a coherent format that can be interpreted without detailed knowledge of the internal state. This process enables replication solutions and auditing to be achieved easily. The PostgreSQL instance needs configuration changes to enable logical decoding, including setting the `wal_level` parameter to `logical`, adjusting `max_replication_slots`, and configuring output plugins like `decoderbufs`. Output plugins transform WAL records into a specified format, such as JSON, which can be consumed by applications or used for change data capture (CDC) solutions. The process of sending push notifications involves modifying the configuration to use a different plugin, such as changing from email integration to notification integration supported by Courier.

Trends Found in this Post
Trend Post Mentions Total Month Mentions Posts Companies MoM
Real-time 2 951 285 97 -5%
Use This Data

Use this post, company, and trend context to find content marketing opportunities, perform competitive analysis, or address product feature gaps via the Plushcap MCP server or the Plushcap API.