HackerReposA FIELD GUIDE TO OPEN SOURCE
ProSponsor the shelf♧ 0
← Back to top all-time
eugene-khyst
postgresql-event-sourcing
Java2023–2023
eugene-khyst / postgresql-event-sourcing · Archived

postgresql-event-sourcing

A reference implementation of an event-sourced system that uses PostgreSQL as an event store built with Spring Boot. Fork the repository and use it as a template for your projects. Or clone the repository and run end-to-end tests to see how everything works together.

2Distinct people
3Mentions
0Explicit recommenders
1.4KGitHub stars
REPOSITORY AT A GLANCE

What to know before exploring

What it is

A reference implementation of an event-sourced system that uses PostgreSQL as an event store built with Spring Boot. Fork the repository and use it as a template for your projects. Or clone the repository and run end-to-end tests to see how everything works together.

GitHub

Where it is used

No documented product use has been verified yet.

What people are saying

No recommendation phrase was found in the indexed comments.

No classified warning is attached to this page. Read the discussions before treating silence as approval.

Also in these discussions

No other repository is repeatedly linked in the same discussions.

This week on Hacker News

Nov 7–Nov 14 UTC · Direct repository links and separately labeled related project stories. Indexed through 11/14/2026, 5:04:57 PM UTC.

No direct repository links were found in the indexed HN discussions over the past seven days. Older discussions are available below.

Mentions over time

HN mentions by week3 dated mentions

Observed mentions: 2023-10-31 12:56:43 UTC to 2023-12-16 21:04:07 UTC. Weeks start Monday, UTC.

0122023-10-30 00:00:00 UTC to 2023-11-06 00:00:00 UTC (exclusive): 2 mentions; 1 submissions, 1 commentsOct 302023-11-06 00:00:00 UTC to 2023-11-13 00:00:00 UTC (exclusive): 0 mentions; 0 submissions, 0 comments2023-11-13 00:00:00 UTC to 2023-11-20 00:00:00 UTC (exclusive): 0 mentions; 0 submissions, 0 comments2023-11-20 00:00:00 UTC to 2023-11-27 00:00:00 UTC (exclusive): 0 mentions; 0 submissions, 0 commentsNov 202023-11-27 00:00:00 UTC to 2023-12-04 00:00:00 UTC (exclusive): 0 mentions; 0 submissions, 0 comments2023-12-04 00:00:00 UTC to 2023-12-11 00:00:00 UTC (exclusive): 0 mentions; 0 submissions, 0 comments2023-12-11 00:00:00 UTC to 2023-12-18 00:00:00 UTC (exclusive): 1 mentions; 0 submissions, 1 commentsDec 11

Counts come from the repository’s dated source evidence. Index cutoff: 2026-11-02 08:16:59 UTC.

View mention counts and date ranges
UTC ranges include their start and exclude their end. Select a period to filter the source evidence.
PeriodStart (UTC)End (exclusive, UTC)MentionsSubmissionsComments
Oct 302023-10-30 00:00:00 UTC2023-11-06 00:00:00 UTC211
Nov 62023-11-06 00:00:00 UTC2023-11-13 00:00:00 UTC000
Nov 132023-11-13 00:00:00 UTC2023-11-20 00:00:00 UTC000
Nov 202023-11-20 00:00:00 UTC2023-11-27 00:00:00 UTC000
Nov 272023-11-27 00:00:00 UTC2023-12-04 00:00:00 UTC000
Dec 42023-12-04 00:00:00 UTC2023-12-11 00:00:00 UTC000
Dec 112023-12-11 00:00:00 UTC2023-12-18 00:00:00 UTC101

What Hacker News says

3 sources

Show HN: Light implementation of Event Sourcing using PostgreSQL as event store

Hi everyone, If you have a Java Spring Boot application with a PostgreSQL database, you can implement Event Sourcing without introducing new specialized databases or frameworks. If you have an application dealing with an entity called Order, you should adopt Event Sourcing to keep track of all changes, and know how the Order got into the current state. Event Sourcing gives you: 1. the true history of the system (audit and traceability), 2. the ability to put the system in any prior state (debugging), 3. the ability to create read projections from events as needed to respond to new demands. There are several well-known specialized frameworks and databases for Event Sourcing: EventStoreDB, Marten, Eventuate, to name a few. But adopting a new framework or database you are not familiar with may stop you from trying the Event Sourcing pattern
Read the rest
in your project. But you can actually implement Event Sourcing with a few classes and use PostgreSQL as an event store. The "postgresql-event-sourcing" project is a reference implementation of an event-sourced system that uses PostgreSQL as an event store built with Spring Boot. Fork the repository and use it as a template for your projects. Or clone the repository and run end-to-end tests to see how everything works together. The project describes in detail: - database model for storing events, - synchronous and asynchronous event handlers, - CQRS, - Transactional Outbox pattern, - Polling Publisher pattern, - optimized publisher that uses PostgreSQL LISTEN/NOTIFY capabilities, - and more. This project can be easily extended to comply with your domain model. The source code is available on GitHub <https://github.com/eugene-khyst/postgresql-event-sourcing>.
231 points · Open discussion

MAKE YOURSELF AT HOME

A few shortcuts

/
Search the collection
?
Open this guide
Esc
Close dialogs and navigation

Your saved repositories and interests stay in this browser.