Removes leader from members and changes name since it's an address.

This commit is contained in:
James Phillips 2016-03-18 17:07:11 -07:00
parent 11b73bb1a5
commit e4ca18089f
2 changed files with 1 additions and 6 deletions

View File

@ -67,11 +67,6 @@ func (c *MembersCommand) Run(args []string) int {
}
defer client.Close()
leader, err := client.Stats()
if err == nil {
c.Ui.Output(fmt.Sprintf("Leader: %s", leader["consul"]["leader_name"]))
}
var members []agent.Member
if wan {
members, err = client.WANMembers()

View File

@ -733,7 +733,7 @@ func (s *Server) Stats() map[string]map[string]string {
"consul": map[string]string{
"server": "true",
"leader": fmt.Sprintf("%v", s.IsLeader()),
"leader_name": s.raft.Leader(),
"leader_addr": s.raft.Leader(),
"bootstrap": fmt.Sprintf("%v", s.config.Bootstrap),
"known_datacenters": toString(uint64(len(s.remoteConsuls))),
},