-
Notifications
You must be signed in to change notification settings - Fork 1.4k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
MONGOID-5758: Add Mongoid.reconnect_clients and improve forking webserver documentation #5808
Merged
Merged
Changes from 6 commits
Commits
Show all changes
8 commits
Select commit
Hold shift + click to select a range
bdfa862
This PR does the following:
johnnyshields 3207f1b
Fix method name
johnnyshields b0cfcd8
More terse syntax
johnnyshields 5fb1a87
Preserve old return type
johnnyshields 36f6e87
Update configuration.txt
johnnyshields dd6956b
Update configuration.txt
johnnyshields bb7c181
Merge branch 'master' into reconnect-clients
johnnyshields 7a0d4b3
Merge remote-tracking branch 'remotes/johnnyshields/reconnect-clients'
johnnyshields File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hey @johnnyshields -- here and elsewhere, do you think there's value in actually returning the list of clients? I don't believe the current return value is intentional (or even useful). I think I'd rather leave the documented return value as
true
(or at least "truthy"), rather than be committed to always returning a list of clients here.There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@jamis the documentation should match what the method does, and today the method returns the list of clients. It is certainly fine to raise another PR and change the return value, I doubt anyone is relying on this behavior today.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You're not wrong, Johnny. However, it's also fair to say that the method returns truthy, which is what the documentation today (poorly) implies. I much prefer a truthy return value, than telling the world to expect it to return a list of clients. There are other ways to get the list of clients, and I'd really rather this not be one of them.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
OK so would you like me to change the method return behavior of both
disconnect
(existing) andreconnect
(new) in this PR?There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
reconnect
should mirror the behavior ofdisconnect
. I'm honestly more worried about the documentation (and the contract it exposes) than the actual implementation, but as long as we're not promising clients more than we want to deliver (e.g. exposing the client list as a return value here), I'm okay.There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@jamis this is done--both disconnect and reconnect now return true.