Revert "etcdhttp: add internalVersion"

This reverts commit a77bf97c14.

Conflicts:
	version/version.go
This commit is contained in:
Yicheng Qin
2015-03-27 16:53:55 -07:00
parent dd92a2b484
commit 60efd4d96e
3 changed files with 3 additions and 4 deletions

View File

@@ -359,7 +359,7 @@ func serveVersion(w http.ResponseWriter, r *http.Request) {
if !allowMethod(w, r.Method, "GET") {
return
}
fmt.Fprintf(w, `{"releaseVersion":"%s","internalVersion":"%s"}`, version.Version, version.InternalVersion)
w.Write([]byte("etcd " + version.Version))
}
// parseKeyRequest converts a received http.Request on keysPrefix to

View File

@@ -1327,7 +1327,7 @@ func TestServeVersion(t *testing.T) {
if rw.Code != http.StatusOK {
t.Errorf("code=%d, want %d", rw.Code, http.StatusOK)
}
w := fmt.Sprintf(`{"releaseVersion":"%s","internalVersion":"%s"}`, version.Version, version.InternalVersion)
w := fmt.Sprintf("etcd %s", version.Version)
if g := rw.Body.String(); g != w {
t.Fatalf("body = %q, want %q", g, w)
}

View File

@@ -23,8 +23,7 @@ import (
)
var (
Version = "2.0.4+git"
InternalVersion = "2"
Version = "2.0.4+git"
)
// WalVersion is an enum for versions of etcd logs.