As like other databases, MongoDB has its own stunning features such as
- load balancing
and it's easier to use when the user prefers a NoSQL database.
1) As we implementing MongoDB, A deployed MongoDB Server with valid credentials.
1) Search for 'HTTP' which look like this:
and drag-and-drop in the editor.
Search and drop the 'function' node which looks like this:
Search and drop the 'MongoDB' Node which looks like this:
Search for 'HTTP Response' which look like this
and drop these nodes in the workplace editor.
2) Connect them to each other like this:
msg.payload = msg.required.body;
return msg;3) Double-click on mongodb2 to reveal its settingsNow click onto reveal MongoDB settings for setting up a server with credentials.
Finally, search 'Console' and drop into the editor:
So we explain what the flow and their node actually do:
- The /test takes the JSON input which passes through the node function.
- Node.js function to input MongoDB.
- mongo simply parses the output to a HTTP response.
4) Deploy and see the magic