Combine pkg/apitools and pkg/api/common and call the result pkg/runtime

This commit is contained in:
Daniel Smith
2014-09-02 10:55:27 -07:00
parent 099c8fd36f
commit a63966e73c
44 changed files with 218 additions and 237 deletions

View File

@@ -21,8 +21,8 @@ import (
"net/http"
"github.com/GoogleCloudPlatform/kubernetes/pkg/api"
"github.com/GoogleCloudPlatform/kubernetes/pkg/apitools"
"github.com/GoogleCloudPlatform/kubernetes/pkg/client"
"github.com/GoogleCloudPlatform/kubernetes/pkg/runtime"
)
// ProxyServer is a http.Handler which proxies Kubernetes APIs to remote API server.
@@ -53,7 +53,7 @@ func (s *ProxyServer) Serve() error {
func (s *ProxyServer) doError(w http.ResponseWriter, err error) {
w.WriteHeader(http.StatusInternalServerError)
w.Header().Add("Content-type", "application/json")
data, _ := apitools.Encode(api.Status{
data, _ := runtime.Encode(api.Status{
Status: api.StatusFailure,
Message: fmt.Sprintf("internal error: %#v", err),
})