Skip to content
This repository has been archived by the owner on Jan 15, 2024. It is now read-only.

Retry on SocketError when calling resolv() #265

Closed
wants to merge 8 commits into from
Closed

Retry on SocketError when calling resolv() #265

wants to merge 8 commits into from

Conversation

reidmorrison
Copy link
Contributor

After running for a few more days in production, we changed it to retry the resolv() call should it fail rather than removing the node from the list of available servers.
So far this latest change appears to be working well in our production environments.

The only issue from a generic perspective is that it is has a hard-coded retry of 3. Is there a better way to configure it in Moped?

@reidmorrison
Copy link
Contributor Author

Added several changes to address other outstanding issues that needed to be addressed for Moped to function in our production environment

…ew primary

Fails immediately with Moped::Errors::QueryFailure:
failed with error 13435: "not master and slaveOk=false"
@reidmorrison
Copy link
Contributor Author

Confirmed that the tests complete successfully on Ruby V2.1.1. Appears the above test failure is a hanging Travis environment. Can you try re-running the test?

The above fixes are after thorough testing with replica-sets across multiple data centers in production. We are currently running these fixes in production and have found Moped to be significantly more stable with them.

@ptolts
Copy link

ptolts commented Apr 25, 2014

Thanks for this. I believe this is what's causing an issue of mine.

@coveralls
Copy link

Coverage Status

Coverage decreased (-0.58%) when pulling 59c8d5e on reidmorrison:master into a44b4e1 on mongoid:master.

@reidmorrison
Copy link
Contributor Author

Replaced Mongoid with MongoMapper to remove Moped due to constant production problems with Moped.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants