"Exception while polling query" with MLab and Meteor 1.4


#1

Every now and then my database connection will timeout. I have one large collection with 5M records, I’m not sure if this is causing some kind of issue. It is also taking awhile for the initial query, even though it has a limit of 30 records on it.

I’ve found some threads that are similar, but still not sure the answer here (or the possible answers at least):

What happens to Meteor during a MongoDB failover event?

Collection query exception fails with error on “meteor_accounts loginServiceConfiguration”

Problems with database connection

Mongo corrupted data maybe Ground db it is causing this

Meteor.publish() - how to get documents by free text

I’m hoping the data isn’t corrupted. Is there anyway to determine if the data is corrupted?


#2

In your case (a collection with a huge amount of documents) I guess you’d better use indexes, because they really reduce the query time. https://docs.mongodb.com/manual/indexes/

Mongodb database profiling may help in finding the queries that take a lot of time, thus making your app slow https://docs.mongodb.com/manual/administration/analyzing-mongodb-performance/#database-profiling

I had the same problem lately. But I found out that it was (mainly) due to a mistake a made in the code.