Relative Content

Tag Archive for mernreact-fullstack

How to resolve this MongoDb atlas related problem that is coming in my vs code terminal

OJ PROJECT 3backend>node server.js
(node:23356) [MONGODB DRIVER] Warning: useNewUrlParser is a deprecated option: useNewUrlParser has no effect since Node.js Driver version 4.0.0 and will be removed in the next major version
(Use node --trace-warnings ... to show where the warning was created)
(node:23356) [MONGODB DRIVER] Warning: useUnifiedTopology is a deprecated option: useUnifiedTopology has no effect since Node.js Driver version 4.0.0 and will be removed in the next major version
Server running on port 5000
MongoDB connection error: MongooseServerSelectionError: Could not connect to any servers in your MongoDB Atlas cluster. One common reason is that you’re trying to access the database from an IP that isn’t whitelisted. Make sure your current IP address is on your Atlas cluster’s IP whitelist: https://www.mongodb.com/docs/atlas/security-whitelist/
at _handleConnectionErrors (D:OJ PROJECT 3backendnode_modulesmongooselibconnection.js:897:11)
at NativeConnection.openUri (D:OJ PROJECT 3backendnode_modulesmongooselibconnection.js:848:11) {
reason: TopologyDescription {
type: ‘ReplicaSetNoPrimary’,
servers: Map(3) {
‘ac-gychqlq-shard-00-02.1ihsa2a.mongodb.net:27017’ => [ServerDescription],
‘ac-gychqlq-shard-00-01.1ihsa2a.mongodb.net:27017’ => [ServerDescription],
‘ac-gychqlq-shard-00-00.1ihsa2a.mongodb.net:27017’ => [ServerDescription]
},
stale: false,
compatible: true,
heartbeatFrequencyMS: 10000,
localThresholdMS: 15,
setName: ‘atlas-ax2s65-shard-0’,
maxElectionId: null,
maxSetVersion: null,
commonWireVersion: 0,
logicalSessionTimeoutMinutes: null
},
code: undefined