I need some help. I’m trying to connect to an Atlas Serverless database from Nodejs. It just won’t work. Tried and triple checked everything I found. mongosh connect works, so user/passwd must be right, and ip whitelisting must work too. Did http://portquiz.net:27017.
sorry but i am quite confused. In the link that you post is wrote that NodeJS is not supported, but then I found this:
And I tried to connect with Mongoose and it give me an error:
Error in MongoDb connection: MongoParseError: Text record must only set `authSource` or `replicaSet`
(node:9708) UnhandledPromiseRejectionWarning: MongoParseError: Text record must only set `authSource` or `replicaSet`
at QueryReqWrap.callback (T:\Lavori_Software\k-core\node_modules\mongodb\lib\core\uri_parser.js:111:13)
at QueryReqWrap.onresolve [as oncomplete] (dns.js:205:10)
(node:9708) UnhandledPromiseRejectionWarning: Unhandled promise rejection. This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). To terminate the node process on unhandled promise rejection, use the CLI flag `--unhandled-rejections=strict` (see https://nodejs.org/api/cli.html#cli_unhandled_rejections_mode). (rejection id: 1)
(node:9708) [DEP0018] DeprecationWarning: Unhandled promise rejections are deprecated. In the future, promise rejections that are not handled will terminate the Node.js process with a non-zero exit code.
Please can you clarify the situation? Is it supported or not NodeJS/Mongoose? If not, do you have an idea bout when it could be supported?