hmarr/mongoengine — Issue #425: Support automatic reconnection to mongoDB
Author: rbdrbd
Created: 2012-02-02 14:16:12+00:00
State: open

Post detailing this here: http://groups.google.com/group/mongoengine-users/browse_thread/thread/9fc4f8a699f4d12

This would involve implementing a handler for pymongo's AutoReconnect exception. Regarding doing this, I've found numerous examples on the web and am having a big challenge getting them to work properly, including https://gist.github.com/1393029 (which doesn't recover at all...I get recusion errors) and http://pastebin.com/HE8LSp5v (which will recover if mongo comes back up, but will not properly count the # of attempts and error out...meaning it's just an infinite loop of retries until mongo comes back up).