Abrandoned/config zmq#218
Merged
abrandoned merged 4 commits intomasterfrom Sep 16, 2014
Merged
Conversation
in the connector for zmq and the broker for zmq the poll weight influences how many messages will be pulled from the polling socket before it moves on to check the other socket, this is currently 2/1 weighted in favor of the backend socket (the work complete) Also made a configuration value of the number of attempts to make on getting the server uri on the client side
Contributor
There was a problem hiding this comment.
Any reason not to use += here?
Contributor
Author
There was a problem hiding this comment.
I don't like += other than that ..... no
Contributor
There was a problem hiding this comment.
To me, it's much more readable.
Contributor
There was a problem hiding this comment.
And why don't you like it?
Contributor
Author
There was a problem hiding this comment.
it's shorthand, you know my pref to avoid abbrevs ;)
Contributor
|
My only concern is that the broker's run method is getting a little thick around the middle with this change. Any chance we can break up the backend/frontend while loops into their own methods? |
Contributor
|
Something like |
Contributor
Author
|
on it |
Contributor
Author
Contributor
Contributor
|
Like it. Perfect. |
This file contains hidden or 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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.

Moving the values that were hardcoded into the zmq broker/connector into environment variables with "reasonable" defaults (the defaults basically maintain the behavior before this PR)
PB_ZMQ_CLIENT_HOST_ALIVE_CHECK_INTERVAL- how many seconds between health checksPB_ZMQ_CLIENT_SERVER_LOOKUP_ATTEMPTS- how many times to lookup the server in the service directory listPB_ZMQ_SERVER_BACKEND_POLL_WEIGHT- in the broker this is how many backend reads will be executed if the backend socket is readable while processing the backend responses (defaults to 1)PB_ZMQ_SERVER_FRONTEND_POLL_WEIGHT- in the broker this is how many frontend reads will be executed if the frontend socket is readable while processing the frontend requests (defaults to 1)@liveh2o @localshred @quixoten