Skip to content
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

GetLeaderRaftConnectString returns consistent result #857

Merged

Conversation

oliveagle
Copy link
Contributor

return a consistant leader raft connection string when called on all living nodes include leader.

@jvshahid
Copy link
Contributor

@oliveagle can you explain or give an example of why the old version is inconsistent vs the new one

@oliveagle
Copy link
Contributor Author

on leader node. the old version api will return empty string ""
on follower node. the old api will return leader raft string.

IMHO, isLeader or not should be hold in another variable. otherwise , u have to explain this behavior in doc or some other place.

"isLeader": only return True or False. indicator the server is leader or not.
"leaderRaftConnectString": only return leader raft connection string. even the node is the leader.

by doing this way. the variable is totally self-explained. If the cluster has one leader, then there is only one value will be returned cross all nodes.

well, IsUp is more interesting. when called on A node, it shows B node is Up. A nodes is down.
when called on B node, it shows A node is UP, B node is down. isUp variable is private but IsUp function is public.

@jvshahid jvshahid added this to the Next release milestone Aug 29, 2014
jvshahid added a commit that referenced this pull request Aug 29, 2014
GetLeaderRaftConnectString returns consistent result
@jvshahid jvshahid merged commit 1df438a into influxdata:master Aug 29, 2014
@oliveagle oliveagle deleted the more_informative_api_get_servers branch September 4, 2014 07:29
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.

None yet

2 participants