Dependency chain is now api -> api/rest -> apiserver. Makes the
interfaces much cleaner to read, and cleans up some inconsistenties
that crept in along the way.
Add a route for /proxy/<kind>/<name>/ without requiring additional path
information. This allows for e.g. /proxy/service/myservice/, which will
proxy to the service at /, instead of always requiring something in the
path.
1) Absolute paths without a hostname were being rewritten relative to
the current page, rather than relative to the current host.
e.g. When viewing /some/page.html, it would rewrite:
/other/page.html => proxyPrepend/some/other/page.html
Instead, it should rewrite:
/other/page.html => proxyPrepend/other/page.html
2) Trailing slashes were being stripped from all rewritten URLs.
This is because path.Join() always calls path.Clean() as well:
http://golang.org/pkg/path/#Join
Some servers are sensitive to the presence of a trailing slash.
For example, http://etcd/v2/keys returns 404 while
http://etcd/v2/keys/ returns the key named "/".
To proxy traffic to anything that implements ResourceLocation.
Currently, this is only services. This is easily extensible to minions
(would supercede existing mechanism) and pods.