Search Options

Results per page
Sort
Preferred Languages
Advance

Results 91 - 100 of 207 for StatusOK (0.12 sec)

  1. pkg/credentialprovider/config.go

    	if cfg, err := ReadDockerConfigJSONFile(nil); err == nil {
    		return cfg, nil
    	}
    	// Can't find latest config file so check for the old one
    	return ReadDockercfgFile(nil)
    }
    
    // HTTPError wraps a non-StatusOK error code as an error.
    type HTTPError struct {
    	StatusCode int
    	URL        string
    }
    
    // Error implements error
    func (he *HTTPError) Error() string {
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Wed Apr 19 15:11:57 UTC 2023
    - 9.3K bytes
    - Viewed (0)
  2. staging/src/k8s.io/apiserver/pkg/endpoints/filters/audit.go

    			// But Audit-Id http header will only be sent when http.ResponseWriter.WriteHeader is called.
    			fakedSuccessStatus := &metav1.Status{
    				Code:    http.StatusOK,
    				Status:  metav1.StatusSuccess,
    				Message: "Connection closed early",
    			}
    			if ev.ResponseStatus == nil && longRunningSink != nil {
    				ev.ResponseStatus = fakedSuccessStatus
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Mon Jul 03 16:16:51 UTC 2023
    - 8.6K bytes
    - Viewed (0)
  3. pkg/test/echo/server/endpoint/http.go

    		epLog.Warn("websocket-echo read failed: " + err.Error())
    		return
    	}
    
    	body := bytes.Buffer{}
    	h.addResponsePayload(r, &body)
    	body.Write(message)
    
    	echo.StatusCodeField.Write(&body, strconv.Itoa(http.StatusOK))
    
    	// pong
    	err = c.WriteMessage(mt, body.Bytes())
    	if err != nil {
    		writeError(&body, "websocket-echo write failed: "+err.Error())
    		return
    	}
    }
    
    // nolint: interfacer
    Registered: Fri Jun 14 15:00:06 UTC 2024
    - Last Modified: Tue May 23 16:20:31 UTC 2023
    - 12.8K bytes
    - Viewed (0)
  4. pkg/test/echo/server/forwarder/udp.go

    		if line != "" {
    			echo.WriteBodyLine(&msgBuilder, requestID, line)
    		}
    	}
    
    	msg := msgBuilder.String()
    	expected := fmt.Sprintf("%s=%d", string(echo.StatusCodeField), http.StatusOK)
    	if cfg.Request.ExpectedResponse != nil {
    		expected = cfg.Request.ExpectedResponse.GetValue()
    	}
    	if !strings.Contains(msg, expected) {
    Registered: Fri Jun 14 15:00:06 UTC 2024
    - Last Modified: Thu Oct 13 17:19:22 UTC 2022
    - 3.4K bytes
    - Viewed (0)
  5. cmd/bucket-lifecycle-handlers_test.go

    			expectedRespStatus: http.StatusOK,
    			lifecycleResponse:  []byte(``),
    			errorResponse:      APIErrorResponse{},
    			shouldPass:         true,
    		},
    		{
    			method:             http.MethodGet,
    			accessKey:          creds.AccessKey,
    Registered: Sun Jun 16 00:44:34 UTC 2024
    - Last Modified: Mon Jun 10 15:50:49 UTC 2024
    - 11.3K bytes
    - Viewed (0)
  6. docs/sts/client-grants.go

    			InsecureSkipVerify: true,
    		},
    	}
    	hclient := http.Client{
    		Transport: t,
    	}
    	resp, err := hclient.Do(req)
    	if err != nil {
    		return nil, err
    	}
    	defer resp.Body.Close()
    	if resp.StatusCode != http.StatusOK {
    		return nil, fmt.Errorf("%s", resp.Status)
    	}
    
    	var idpToken JWTToken
    	if err = json.NewDecoder(resp.Body).Decode(&idpToken); err != nil {
    		return nil, err
    	}
    
    Registered: Sun Jun 16 00:44:34 UTC 2024
    - Last Modified: Thu Aug 19 01:35:22 UTC 2021
    - 3.3K bytes
    - Viewed (0)
  7. internal/config/identity/openid/jwt.go

    	client := &http.Client{
    		Transport: r.transport,
    	}
    
    	resp, err := client.Get(pCfg.JWKS.URL.String())
    	if err != nil {
    		return err
    	}
    	defer r.closeRespFn(resp.Body)
    	if resp.StatusCode != http.StatusOK {
    		return errors.New(resp.Status)
    	}
    
    	return r.pubKeys.parseAndAdd(resp.Body)
    }
    
    // ErrTokenExpired - error token expired
    var (
    	ErrTokenExpired = errors.New("token expired")
    )
    
    Registered: Sun Jun 16 00:44:34 UTC 2024
    - Last Modified: Thu May 30 18:10:41 UTC 2024
    - 8.3K bytes
    - Viewed (0)
  8. staging/src/k8s.io/apiserver/pkg/server/routes/flags.go

    				return
    			}
    			defer req.Body.Close()
    			response, err := setter(string(body))
    			if err != nil {
    				writePlainText(http.StatusBadRequest, err.Error(), w)
    				return
    			}
    			writePlainText(http.StatusOK, response, w)
    			return
    		default:
    			writePlainText(http.StatusNotAcceptable, "unsupported http method", w)
    			return
    		}
    	})
    }
    
    // writePlainText renders a simple string response.
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Sat May 16 11:54:27 UTC 2020
    - 3.2K bytes
    - Viewed (0)
  9. cmd/kubeadm/app/phases/patchnode/patchnode_test.go

    					patchRequest = buf.String()
    				default:
    					t.Errorf("request for unexpected HTTP verb: %v", req.Method)
    					http.Error(w, "", http.StatusNotFound)
    					return
    				}
    
    				w.WriteHeader(http.StatusOK)
    				w.Write(jsonNode)
    			}))
    			defer s.Close()
    
    			cs, err := clientset.NewForConfig(&restclient.Config{Host: s.URL})
    			if err != nil {
    				t.Fatalf("unexpected error building clientset: %v", err)
    			}
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Wed Jan 12 15:15:45 UTC 2022
    - 3.7K bytes
    - Viewed (0)
  10. internal/config/subnet/subnet.go

    	}
    	defer xhttp.DrainBody(resp.Body)
    
    	respBytes, err := io.ReadAll(io.LimitReader(resp.Body, respBodyLimit))
    	if err != nil {
    		return "", err
    	}
    	respStr := string(respBytes)
    
    	if resp.StatusCode == http.StatusOK {
    		return respStr, nil
    	}
    
    	return respStr, fmt.Errorf("SUBNET request failed with code %d and error: %s", resp.StatusCode, respStr)
    }
    
    // Post submit 'payload' to specified URL
    Registered: Sun Jun 16 00:44:34 UTC 2024
    - Last Modified: Mon Feb 27 16:35:36 UTC 2023
    - 2.9K bytes
    - Viewed (0)
Back to top