MCPcopy Create free account
hub / github.com/1Panel-dev/1Panel / HandleRequest

Function HandleRequest

agent/utils/req_helper/request.go:50–54  ·  view source on GitHub ↗
(url, method string, timeout int)

Source from the content-addressed store, hash-verified

48}
49
50func HandleRequest(url, method string, timeout int) (int, []byte, error) {
51 transport := xpack.MultiNodeProvider.LoadRequestTransport()
52 client := http.Client{Timeout: time.Duration(timeout) * time.Second, Transport: transport}
53 return HandleRequestWithClient(&client, url, method, timeout)
54}
55
56func HandleRequestWithClient(client *http.Client, url, method string, timeout int) (int, []byte, error) {
57 defer func() {

Callers

nothing calls this directly

Calls 2

HandleRequestWithClientFunction · 0.85
LoadRequestTransportMethod · 0.65

Tested by

no test coverage detected