harbor/src/chartserver/handler_proxy_traffic.go
Steven Zou df241c0666 Refactor the chart service implementation to provide more extemding flexibilities
- use unified proxy handler to handle all the proxy traffic
- define interfaces for the handlers
- implement the interface at chart controller level
- refactor UT cases
- update other related reference code

Signed-off-by: Steven Zou <szou@vmware.com>
2018-09-19 16:34:58 +08:00

13 lines
240 B
Go

package chartserver
import (
"net/http"
)
// ProxyTraffic implements the interface method.
func (c *Controller) ProxyTraffic(w http.ResponseWriter, req *http.Request) {
if c.trafficProxy != nil {
c.trafficProxy.ServeHTTP(w, req)
}
}