- Sort Score
- Result 10 results
- Languages All
Results 51 - 60 of 194 for StatusOK (0.12 sec)
-
pkg/http/get.go
} for k, v := range headers { req.Header.Set(k, v) } response, err := httpClient.Do(req) if err != nil { return nil, err } defer response.Body.Close() if response.StatusCode != http.StatusOK { return nil, fmt.Errorf("unexpected status %d", response.StatusCode) } var b bytes.Buffer if _, err := io.Copy(&b, response.Body); err != nil { return nil, err } return &b, nil
Registered: Fri Jun 14 15:00:06 UTC 2024 - Last Modified: Wed Aug 09 03:52:10 UTC 2023 - 1.9K bytes - Viewed (0) -
staging/src/k8s.io/apiserver/pkg/server/config_test.go
`, t) checkPath(server.URL+"/healthz/poststarthook/delegate-post-start-hook", http.StatusOK, `ok`, t) checkPath(server.URL+"/healthz/poststarthook/wrapping-post-start-hook", http.StatusOK, `ok`, t) checkPath(server.URL+"/foo", http.StatusForbidden, ``, t) checkPath(server.URL+"/bar", http.StatusUnauthorized, ``, t) }
Registered: Sat Jun 15 01:39:40 UTC 2024 - Last Modified: Mon Apr 29 18:59:21 UTC 2024 - 13.1K bytes - Viewed (0) -
pkg/ctrlz/fw/utils.go
b := &bytes.Buffer{} if err := t.Execute(b, data); err != nil { RenderError(w, http.StatusInternalServerError, err) return } w.WriteHeader(http.StatusOK) w.Header().Set("Content-Type", "text/html; charset=utf-8") _, _ = b.WriteTo(w) } // RenderJSON outputs the given data as JSON func RenderJSON(w http.ResponseWriter, statusCode int, data any) {
Registered: Fri Jun 14 15:00:06 UTC 2024 - Last Modified: Wed May 24 14:06:41 UTC 2023 - 1.6K bytes - Viewed (0) -
istioctl/pkg/util/handlers/handlers_test.go
body := cmdtesting.ObjBody(codec, attachDeploy("istio-system")) return &http.Response{StatusCode: http.StatusOK, Header: cmdtesting.DefaultHeader(), Body: body}, nil case p == "/namespaces/test/deployments/foo" && m == "GET": body := cmdtesting.ObjBody(codec, attachDeploy("test")) return &http.Response{StatusCode: http.StatusOK, Header: cmdtesting.DefaultHeader(), Body: body}, nil default:
Registered: Fri Jun 14 15:00:06 UTC 2024 - Last Modified: Fri Jun 09 18:17:49 UTC 2023 - 6.6K bytes - Viewed (0) -
internal/http/response-recorder.go
func NewResponseRecorder(w http.ResponseWriter) *ResponseRecorder { rf, _ := w.(io.ReaderFrom) return &ResponseRecorder{ ResponseWriter: w, ReaderFrom: rf, StatusCode: http.StatusOK, StartTime: time.Now().UTC(), } } // ErrNotImplemented when a functionality is not implemented var ErrNotImplemented = errors.New("not implemented")
Registered: Sun Jun 16 00:44:34 UTC 2024 - Last Modified: Sat Dec 02 00:13:19 UTC 2023 - 4.9K bytes - Viewed (0) -
src/net/http/pprof/testdata/delta_mutex.go
req := httptest.NewRequest("GET", "/debug/pprof/mutex?seconds=1", nil) rec := httptest.NewRecorder() rec.Body = new(bytes.Buffer) h.ServeHTTP(rec, req) resp := rec.Result() if resp.StatusCode != http.StatusOK { log.Fatalf("Request failed: %s\n%s", resp.Status, rec.Body) } fmt.Print(rec.Body)
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Thu Dec 07 19:52:28 UTC 2023 - 1.2K bytes - Viewed (0) -
tests/integration/security/egress_gateway_origination_test.go
// This root certificate can validate the server cert presented by the echoboot server instance. { name: "simple", statusCode: http.StatusOK, credentialToUse: strings.TrimSuffix(credName, "-cacert"), useGateway: true, }, // Use CA certificate stored as k8s secret with different issuing CA as server's CA.
Registered: Fri Jun 14 15:00:06 UTC 2024 - Last Modified: Mon Apr 08 22:02:59 UTC 2024 - 15.4K bytes - Viewed (0) -
src/net/http/responsewrite_test.go
"Connection: close\r\n" + "Foo: Bar Baz\r\n" + "\r\n", }, // Want a single Content-Length header. Fixing issue 8180 where // there were two. { Response{ StatusCode: StatusOK, ProtoMajor: 1, ProtoMinor: 1, Request: &Request{Method: "POST"}, Header: Header{}, ContentLength: 0, TransferEncoding: nil, Body: nil,
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Wed Sep 07 01:07:32 UTC 2022 - 6.9K bytes - Viewed (0) -
staging/src/k8s.io/apiserver/pkg/server/routes/version.go
c.Add(versionWS) } // handleVersion writes the server's version information. func (v Version) handleVersion(req *restful.Request, resp *restful.Response) { responsewriters.WriteRawJSON(http.StatusOK, *v.Version, resp.ResponseWriter)
Registered: Sat Jun 15 01:39:40 UTC 2024 - Last Modified: Thu Jun 09 18:11:41 UTC 2022 - 1.6K bytes - Viewed (0) -
tests/integration/telemetry/policy/traffic_registry_only_test.go
Aggregation: "sum", Labels: map[string]string{ "destination_service_name": "istio-egressgateway", "response_code": "200", }, }, StatusCode: http.StatusOK, RequestHeaders: map[string]string{ // We inject this header in the VirtualService "Handled-By-Egress-Gateway": "true", }, }, }, // TODO add HTTPS through gateway {
Registered: Fri Jun 14 15:00:06 UTC 2024 - Last Modified: Tue Oct 18 18:03:23 UTC 2022 - 3.3K bytes - Viewed (0)