MCPcopy Index your code
hub / github.com/zalando/skipper / proxyForBackend

Function proxyForBackend

proxy/longpoll_test.go:92–104  ·  view source on GitHub ↗
(backendURL string)

Source from the content-addressed store, hash-verified

90}
91
92func proxyForBackend(backendURL string) (url string, closeServer func()) {
93 route := fmt.Sprintf(`* -> "%s"`, backendURL)
94 p, err := newTestProxy(route, FlagsNone)
95 if err != nil {
96 panic(err)
97 }
98
99 s := httptest.NewServer(p.proxy)
100 return s.URL, func() {
101 s.Close()
102 p.close()
103 }
104}
105
106// func stdlibProxy(backendURL string) (proxyURL string, closeServer func()) {
107// parsed, err := url.Parse(backendURL)

Callers

nothing calls this directly

Calls 3

newTestProxyFunction · 0.85
CloseMethod · 0.65
closeMethod · 0.45

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…