Another rb sample showing working of Apache Camel with RabbitMQ and MongoDB3. I used Rabbit MQ Web UI to publish the message, and after receiving the message by RabbitMQ Consumer the Camel Router routes the message to MongoDB3. Had to convert the message/exchange body to String before routing body to mongodb.
https://docs.mongodb.com/v3.2/tutorial/install-mongodb-on-windows/
"C:\Program Files\MongoDB\Server<version>\bin\mongod.exe" --dbpath c:\mongo\datadb
Use the Mongo Client to validate the saved message. $ ./mongo MongoDB shell version v3.6.3 connecting to: mongodb://127.0.0.1:27017 MongoDB server version: 3.6.3 use userdb switched to db userdb db.user.find()
- command to enable Rabbit MQ Web UI
rabbitmq-plugins.bat enable rabbitmq_management
- Admin Web UI Link
- Admin commands to check status
rabbitmqctl status rabbitmqctl stop *
{ "age": 29, "eyeColor": "black", "name": "Vicki Slat", "gender": "female", "company": "TEST", "email": "vickislat@test.com", "phone": "+1 (000) 546-990", "address": "681 TEST Street, TEST, OLD, 8627" }
https://www.baeldung.com/apache-camel-spring-boot https://dzone.com/articles/apache-camel-mongodb-component-example https://docs.mongodb.com/v3.2/tutorial/install-mongodb-on-windows/ http://api.mongodb.com/java/2.10.1/com/mongodb/MongoClient.html https://github.com/apache/camel/blob/master/components/camel-mongodb3/src/main/docs/mongodb3-component.adoc http://camel.apache.org/mongodb.html https://www.rabbitmq.com/install-windows.html