I could use some forum help on an issue in Meteor 1.10.2 that I’m running into.
I use Mongo Atlas and whenever they do a maintenance update, my app’s UI starts failing to do real-time synchronization. Their maintenance update seems to take down the master, which causes problems in my app.
Users can still do things in the app, but Meteor stops returning the updates from the database to the UI which causes functionality errors and confusion of course. Upon doing a browser refresh, any database updates are then shown. So it’s not a full disconnection from the database.
In my APM logs I see a
UnhandledPromiseRejectionWarning: MongoError: not master error that’s rooted in Meteor’s Mongo code.
MONGO_URL, I follow Mongo Atlas’s example, but I don’t use the
replicaSet parameter. They don’t show it in their example. The various references I’ve seen online say to use the
replicaSet parameter in the
MONGO_OPLOG_URL, which I’ve disabled because I use redis-oplog.
MONGO_URL looks like this:
I’ve also read that in some Mongo versions/drivers, you don’t need to specify the
replicaSet parameter. I also found StackExchange posts that mention you need to use the
MONGO_OPLOG_URL so Meteor knows about. Which could solve the failover issue.
It doesn’t seem like in the Meteor Guide there’s any real documentation on the proper current Mongo URL format. Though I know it depends on the version of Meteor and Mongo. But there should be more documentation on this. For example, what Mongo URL parameters work and which ones don’t.