LoginSignup
3
3

More than 5 years have passed since last update.

MongoDB の find がタイムアウトする

Last updated at Posted at 2014-10-21

MongoDB から結果が大きめのデータを引っ張ろうとすると

cursor didn't exist on server, possible restart or timeout?

みたいなエラーがでますた.

Cursor の addOption を使ってタイムアウトを無効にしましょう.

db.collection.find().addOption(DBQuery.Option.noTimeout)

参考

ほかにもいくつかオプションあるみたいです

3
3
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
3
3