MongoDB 2 driver node

394 views
Skip to first unread message

Oren Zomer

unread,
Mar 22, 2015, 5:15:38 PM3/22/15
to node...@googlegroups.com
https://www.npmjs.com/package/node-red-node-mongodb2

This is a beta version. Not all operations were tested.

Let me know what you think,
Oren


Nicholas O'Leary

unread,
Mar 22, 2015, 5:21:43 PM3/22/15
to Node-RED Mailing LIst
Hi Oren,

thanks for sharing this.

Can you describe what this provides above the existing mongo nodes? Is there a reason this needs to exist as a separate node, rather than contribute back to the existing one?

We do politely request that 3rd party nodes use the name prefix "node-red-contrib-" to avoid confusion with ones maintained by the project - http://nodered.org/docs/creating-nodes/packaging.html

Nick






--
http://nodered.org
---
You received this message because you are subscribed to the Google Groups "Node-RED" group.
To unsubscribe from this group and stop receiving emails from it, send an email to node-red+u...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Oren Zomer

unread,
Mar 22, 2015, 6:19:14 PM3/22/15
to node...@googlegroups.com
Renamed to: https://www.npmjs.com/package/node-red-contrib-mongodb2

The node-red-contrib-mongodb2 supports all the collection operations of api2 (for example: findOne, updateMany, etc.).
The input msg.payload can be an array of parameters to pass to the operation.
Update operations also have an "output" - for example, in case of upsert, I want to know if the operation created a new document or updated an existing one, so I could react on the first insertion differently than on the following updates.

I also separated the "find" operation (which returns a cursor) to "find.toArray" (sends a single message with an array of the results) and "find.forEach" (sends a message for each result).

surbhi agarwal

unread,
Jul 5, 2016, 2:57:14 AM7/5/16
to Node-RED
Hi Oren,

I am unable to install the mongodb2 nodes on my MAC. May you please guide how to do the same.
It is showing me in the node-modules folder but when i run the node-red , it does not show the node there.

Regards,
Surbhi

Oren Zomer

unread,
Jul 6, 2016, 4:49:23 AM7/6/16
to Node-RED
If node-red-contrib-mongodb2 is inside node_modules and you cannot even see the nodes, I don't believe it's a problem with node-red-contrib-mongodb2.
Can you see any special error logs?
Reply all
Reply to author
Forward
0 new messages