I can successfully connect to a MongoDB database hosted on mLab from Google App Engine Standard (Node.js 8 runtime) using the 3.4+ driver.
But I can't connect to a MongoDB database hosted on MongoDB Atlas from Google App Engine Standard (Node.js 8 runtime) using both, 3.6+ driver as well as 3.4+ driver. The 3.4+ driver works for a while before failing.
I get the error "Error: querySrv ESERVFAIL _mongodb._tcp.xyz-wc7dj.gcp.mongodb.net"
3.6+ driver connection string:
mongodb+srv://username:password@xyz-wc7dj.gcp.mongodb.net/dbname?retryWrites=true
3.4+ driver connection string
mongodb://username:password@xyz-shard-00-00-wc7dj.gcp.mongodb.net:27017,xyz-shard-00-01-wc7dj.gcp.mongodb.net:27017,xyz-shard-00-02-wc7dj.gcp.mongodb.net:27017/dbname?ssl=true&replicaSet=xyz-shard-0&authSource=admin&retryWrites=true
Please help!