- Sort Score
- Result 10 results
- Languages All
Results 1 - 10 of 14 for ClientTrace (0.17 sec)
-
src/net/http/httptrace/trace.go
) // unique type to prevent assignment. type clientEventContextKey struct{} // ContextClientTrace returns the [ClientTrace] associated with the // provided context. If none, it returns nil. func ContextClientTrace(ctx context.Context) *ClientTrace { trace, _ := ctx.Value(clientEventContextKey{}).(*ClientTrace) return trace } // WithClientTrace returns a new context based on the provided parent
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Wed Jan 10 03:29:50 UTC 2024 - 8.1K bytes - Viewed (0) -
src/net/http/header.go
textproto.MIMEHeader(h).Del(key) } // Write writes a header in wire format. func (h Header) Write(w io.Writer) error { return h.write(w, nil) } func (h Header) write(w io.Writer, trace *httptrace.ClientTrace) error { return h.writeSubset(w, nil, trace) } // Clone returns a copy of h or nil if h is nil. func (h Header) Clone() Header { if h == nil { return nil } // Find total number of values.
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Thu Mar 21 22:14:00 UTC 2024 - 7.6K bytes - Viewed (0) -
src/net/http/transport_dial_test.go
} dt.roundTripCount++ dt.t.Logf("RoundTrip %v: started", rt.roundTripID) dt.t.Cleanup(func() { rt.cancel() rt.finish() }) go func() { ctx = httptrace.WithClientTrace(ctx, &httptrace.ClientTrace{ GotConn: func(info httptrace.GotConnInfo) { rt.conn = info.Conn.(*transportDialTesterConn) }, }) req, _ := http.NewRequestWithContext(ctx, "POST", dt.cst.ts.URL, pr)
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Wed Apr 17 21:11:57 UTC 2024 - 6.3K bytes - Viewed (0) -
src/net/http/transport_test.go
c.Transport.(*Transport).DisableKeepAlives = tc.disableKeepAlives req, err := NewRequest("GET", ts.URL, nil) if err != nil { t.Fatal(err) } count := 0 trace := &httptrace.ClientTrace{ WroteHeaderField: func(key string, field []string) { if key != "Connection" { return } if httpguts.HeaderValuesContainsToken(field, "close") { count += 1 }
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Thu Jun 06 21:59:21 UTC 2024 - 192.6K bytes - Viewed (0) -
src/net/http/httputil/reverseproxy.go
// sends it to another server, proxying the response back to the // client. // // 1xx responses are forwarded to the client if the underlying // transport supports ClientTrace.Got1xxResponse. type ReverseProxy struct { // Rewrite must be a function which modifies // the request into a new request to be sent // using Transport. Its response is then copied
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Tue Feb 27 23:37:42 UTC 2024 - 24.9K bytes - Viewed (0) -
staging/src/k8s.io/apiserver/pkg/server/filters/timeout_test.go
newServerRequest := func(tr *panicOnNonReuseTransport) *http.Request { req, _ := http.NewRequest("GET", fmt.Sprintf("https://127.0.0.1:%d", ts.Listener.Addr().(*net.TCPAddr).Port), nil) trace := &httptrace.ClientTrace{ GotConn: tr.GotConn, } return req.WithContext(httptrace.WithClientTrace(req.Context(), trace)) } // client clientCACertPool := x509.NewCertPool() clientCACertPool.AppendCertsFromPEM(tsCrt)
Registered: Sat Jun 15 01:39:40 UTC 2024 - Last Modified: Tue Mar 26 16:28:45 UTC 2024 - 18.4K bytes - Viewed (0) -
src/net/http/transport.go
// exception is HTTP status code 101 (Switching Protocols), which is // considered a terminal status and returned by [Transport.RoundTrip]. To see the // ignored 1xx responses, use the httptrace trace package's // ClientTrace.Got1xxResponse. // // Transport only retries a request upon encountering a network error // if the connection has been already been used successfully and if the
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Thu Jun 06 21:59:21 UTC 2024 - 91K bytes - Viewed (0) -
src/cmd/vendor/golang.org/x/tools/internal/stdlib/manifest.go
}, "net/http/httptrace": { {"ClientTrace", Type, 7}, {"ClientTrace.ConnectDone", Field, 7}, {"ClientTrace.ConnectStart", Field, 7}, {"ClientTrace.DNSDone", Field, 7}, {"ClientTrace.DNSStart", Field, 7}, {"ClientTrace.GetConn", Field, 7}, {"ClientTrace.Got100Continue", Field, 7}, {"ClientTrace.Got1xxResponse", Field, 11}, {"ClientTrace.GotConn", Field, 7},
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Tue Apr 02 02:20:05 UTC 2024 - 534.2K bytes - Viewed (0) -
src/net/http/httputil/reverseproxy_test.go
// seeing a 1xx response. ctx, cancel := context.WithCancel(context.Background()) defer cancel() ctx = httptrace.WithClientTrace(ctx, &httptrace.ClientTrace{ Got1xxResponse: func(code int, header textproto.MIMEHeader) error { cancel() return nil }, }) req, _ := http.NewRequestWithContext(ctx, "GET", "http://go.dev/", nil)
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Thu May 23 01:00:11 UTC 2024 - 54.6K bytes - Viewed (0) -
src/net/http/h2_bundle.go
} func http2traceWroteHeaders(trace *httptrace.ClientTrace) { if trace != nil && trace.WroteHeaders != nil { trace.WroteHeaders() } } func http2traceGot100Continue(trace *httptrace.ClientTrace) { if trace != nil && trace.Got100Continue != nil { trace.Got100Continue() } } func http2traceWait100Continue(trace *httptrace.ClientTrace) {
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Tue Jun 04 16:19:04 UTC 2024 - 364.1K bytes - Viewed (0)