etcdserver/etcdhttp: split out peers and add tests

and we could get rid of `sortint64`