https://github.com/phungvandat/cdcdb
https://github.com/phungvandat/cdcdb
change-data-capture golang mongo-oplog mongodb postgresql write-ahead-log
Last synced: about 2 months ago
JSON representation
- Host: GitHub
- URL: https://github.com/phungvandat/cdcdb
- Owner: phungvandat
- Created: 2021-04-02T11:04:58.000Z (about 5 years ago)
- Default Branch: master
- Last Pushed: 2021-07-06T05:03:18.000Z (almost 5 years ago)
- Last Synced: 2025-03-16T02:28:14.123Z (over 1 year ago)
- Topics: change-data-capture, golang, mongo-oplog, mongodb, postgresql, write-ahead-log
- Language: Go
- Homepage:
- Size: 19.5 KB
- Stars: 2
- Watchers: 0
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# cdcdb: CHANGE DATA CAPTURE DATABASE
`cdcdb`: example demo program the connects to a database and receive some message events(`insert`, `update`, `delete`, ...)
## Database:
- [PostgreSQL 13.2](https://www.postgresql.org/docs/13/release-13-2.html) : [Write-Ahead Logging (WAL)](https://www.postgresql.org/docs/13/wal-intro.html)
- [x] `insert`
- [x] `update`
- [x] `delete`
- [MongoDB 4.4](https://docs.mongodb.com/manual/release-notes/4.4/): [Change Streams](https://docs.mongodb.com/manual/changeStreams/)
- [x] `insert`
- [x] `update`
- [x] `replace`
- [x] `delete`
- [MySQL 8.0](https://dev.mysql.com/doc/relnotes/mysql/8.0/en/): [Binary Log](https://dev.mysql.com/doc/internals/en/binary-log-overview.html)
- [ ] `insert`
- [ ] `update`
- [ ] `delete`
## How to run
### `Postgres`
- Into the executable directory
```
cd pg
```
- Setup replication Postgres DB inside docker evironment:
```
make setup
```
- Create some tables to listen
- Start listening:
```
make dev
```
### `MongoDB`
- Into the executable directory
```
cd mongodb
```
- Setup replication MongoDB inside docker evironment:
```
make setup
```
- Start listening:
```
make dev
```
- Create collection and insert, delete or update some documents.