Skip to content

Conversation

@xiaost
Copy link
Contributor

@xiaost xiaost commented May 25, 2016

it is obvious that we should set no_cursor_timeout to not timeout

this issue was exposed in our mongod with server stats of high opened noTimeout cursors


This change is Reviewable

@xiaost
Copy link
Contributor Author

xiaost commented May 27, 2016

@thedrow

https://raw.githubusercontent.com/mongodb/mongo-python-driver/master/doc/migrate-to-pymongo3.rst

"timeout" replaced by "no_cursor_timeout"

The timeout option has been replaced by no_cursor_timeout. Code like this::

 cursor = collection.find({"a": 1}, timeout=False)

can be changed to this with PyMongo 2.9 or later:

 cursor = collection.find({"a": 1}, no_cursor_timeout=True)

@thedrow thedrow merged commit 3469ed7 into MongoEngine:master May 29, 2016
xiaost added a commit to xiaost/mongoengine that referenced this pull request Jun 2, 2016
@xiaost xiaost deleted the fix-no-cursor-timeout branch June 2, 2016 17:29
lafrech added a commit that referenced this pull request Jun 2, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant