{"repo":"abdelfattehsakkat/mongo-elastic-sync","free":true,"listed":false,"github":"https://github.com/abdelfattehsakkat/mongo-elastic-sync","clone":"git clone https://github.com/abdelfattehsakkat/mongo-elastic-sync.git","description":"Realtime sync from MongoDB to Elasticsearch with optional initial indexing, built for extensibility and production use.","language":"TypeScript","stars":12,"topics":["elasticsearch","mongodb","nodejs","synchronization"],"license":"MIT","category":"deployment-docker-iac","readme_excerpt":"🔄 MongoDB to Elasticsearch Sync (Realtime) A simple Node.js project to synchronize data between MongoDB and Elasticsearch in real time. This project uses MongoDB change streams to detect changes (insert, update, delete) and automatically indexes the data into Elasticsearch. It also includes an initial sync mechanism and integration with Docker to simplify environment setup. It supports: - Real-time sync from MongoDB to Elasticsearch using MongoDB change streams. - Full document indexing (on insert/update). - Delete document handling in Elasticsearch when a document is deleted in MongoDB. - Initial sync from MongoDB to Elasticsearch if Elasticsearch is empty or forced. - Docker Compose for easy setup of MongoDB, Elasticsearch, and Kibana services. Prerequisites Make sure you have the following installed: - Node.js = 16.x - MongoDB = 4.x (for change streams support) - Elasticsearch = 7.x - Docker (optional, for local setup) Installation 1. Clone the repository: 2. Install dependencies: 3. Create a .env file: Copy .env.example to .env and update the values with your MongoDB and Elasticsearch connection details. Example: 4. Run the application: To run the initial sync and start the real-time watcher, run: This will connect to MongoDB and Elasticsearch, check if an initial sync is needed, and start watching for real-time changes in MongoDB. --- 📆 Planned Features - Support for MongoDB TLS/SSL connection - Write to file for Filebeat ingestion (optional) - Save resume token for tr","default_branch":null,"files":null,"tree":[],"storefront":"/r/abdelfattehsakkat","claimed":false,"request_supported":{"post":"https://gitbuyer.com/r/abdelfattehsakkat/mongo-elastic-sync/request-supported","requests":0},"note":"indexed from public GitHub; nothing is for sale on this page. Clone it from GitHub. Paid listings live at /search."}