etcdserver: Cluster.Endpoints() -> Cluster.PeerURLs()

This commit is contained in:
Yicheng Qin
2014-09-28 14:38:40 -07:00
parent e83f851995
commit 5784693a39
3 changed files with 18 additions and 18 deletions

View File

@ -99,10 +99,10 @@ func (c Cluster) IDs() []int64 {
return ids
}
// Endpoints returns a list of all peer addresses. Each address is prefixed
// PeerURLs returns a list of all peer addresses. Each address is prefixed
// with the scheme (currently "http://"). The returned list is sorted in
// ascending lexicographical order.
func (c Cluster) Endpoints() []string {
func (c Cluster) PeerURLs() []string {
endpoints := make([]string, 0)
for _, p := range c {
for _, addr := range p.PeerURLs {