ozomer / node-red-contrib-mongodb2

MongoDB driver node for Node-RED
Apache License 2.0
15 stars 19 forks source link

Examples for Atlas? #24

Closed peter-clarke closed 5 years ago

peter-clarke commented 6 years ago

Do you have any examples for connecting to a Mongodb in Atlas.

When I try to insert a document on 'test' I get the following error. "MongoError: user is not allowed to do action [insert] on [test.$cmd]"

I assume it must be something to do with possibly needing some connection options but I'm not familiar with the format they need to be in and there are no hints in node-red in the info tab.

ozomer commented 6 years ago

Hi, I don't have an example. If you can connect with the standard mongodb2 package, you should be able to connect with this package too.

namgk commented 5 years ago

same issue, haven't found a way.

namgk commented 5 years ago

turns out you'll need to use a special connection string, go to cluster, click connect, connect with mongo shell and choose the shell version 3.4 or earlier. Now you can copy the connection string from the example command.

You also need to append the following to the connection string:

 &ssl=true&authSource=admin
ozomer commented 5 years ago

Hi, If anyone wants to take control over this project please let me know. We're no longer using node-red in my company, so I don't have time and incentive to support node-red-contrib-mongodb2.