Guillermo Bonet
bffb9abd0d
gitea/mycdc/pipeline/pr-master This commit looks good
Details
|
||
---|---|---|
assets | ||
config | ||
lib | ||
queues | ||
.gitignore | ||
Jenkinsfile | ||
LICENSE | ||
README.md | ||
consumer.js | ||
docker-compose.yml | ||
index.js | ||
mycdc.js | ||
package-lock.json | ||
package.json |
README.md
MyCDC - MySQL change data capture
Application to run asynchronous operations based on DB changes. It is divided into three services:
- RabbitMQ: Service that allows the exchange and queuing of messages between applications.
- Producer: Reads and filters changes from the DB binary log and adds the relevant messages to each RabbitMQ queue.
- Consumer: Obtains the elements from the queues and performs the necessary operations asynchronously.
Environment setup
Because a bug with MariaDB wich it's fix is pending to be merged into main project branch, a zongji fork must be cloned into project root directory. More info at https://github.com/nevill/zongji/issues/143
git clone https://github.com/juan-ferrer-toribio/zongji.git
cd zongji
git checkout fix-143
npm install
Apply zongji.sql script into DB.
Copy producer.json and consumer.json from config directory to producer.local.json and consumer.local.json and place your local configuration there.
Install dependencies.
npm install
Run application
Start rabbit.
npm run rabbit
Start producer and consumer.
npm start
npm run consumer
Built With
- Zongji
- MySQL2
- [RabbitMQ] (https://www.rabbitmq.com/)