Skip to content

Commit

Permalink
fix http debugging
Browse files Browse the repository at this point in the history
  • Loading branch information
skonto committed Jan 15, 2025
1 parent 12f0b78 commit 6cbf1a7
Show file tree
Hide file tree
Showing 4 changed files with 5 additions and 4 deletions.
2 changes: 1 addition & 1 deletion config/core/deployments/activator.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -87,7 +87,7 @@ spec:
- name: METRICS_DOMAIN
value: knative.dev/internal/serving
- name: GODEBUG
value: "http1debug=2"
value: "http2debug=2"

securityContext:
allowPrivilegeEscalation: false
Expand Down
2 changes: 1 addition & 1 deletion pkg/reconciler/revision/resources/queue.go
Original file line number Diff line number Diff line change
Expand Up @@ -462,7 +462,7 @@ func makeQueueContainer(rev *v1.Revision, cfg *config.Config) (*corev1.Container
Value: cfg.Deployment.QueueSidecarRootCA,
}, {
Name: "GODEBUG",
Value: "http1debug=2", // Enable HTTP/1.1 debugging
Value: "http2debug=2", // Enable HTTP2 debugging
},
{
Name: "ENABLE_MULTI_CONTAINER_PROBES",
Expand Down
2 changes: 1 addition & 1 deletion test/conformance/runtime/readiness_probe_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -127,7 +127,7 @@ func TestProbeRuntime(t *testing.T) {

t.Log("Creating a new Service")
envs := tc.env

Check failure on line 129 in test/conformance/runtime/readiness_probe_test.go

View workflow job for this annotation

GitHub Actions / style / Golang / Lint

ineffectual assignment to envs (ineffassign)
envs = append(tc.env, corev1.EnvVar{Name: "GODEBUG", Value: "http1debug=2"})
envs = append(tc.env, corev1.EnvVar{Name: "GODEBUG", Value: "http2debug=2"})
resources, err := v1test.CreateServiceReady(t, clients, &names,
v1opts.WithEnv(envs...),
v1opts.WithReadinessProbe(
Expand Down
3 changes: 2 additions & 1 deletion vendor/knative.dev/pkg/network/transports.go
Original file line number Diff line number Diff line change
Expand Up @@ -152,7 +152,8 @@ func NewProberTransport() http.RoundTripper {
// NewProxyAutoTLSTransport is same with NewProxyAutoTransport but it has DialTLSContextFunc to create HTTPS request.
func NewProxyAutoTLSTransport(maxIdle, maxIdlePerHost int, tlsContext DialTLSContextFunc) http.RoundTripper {
return newAutoTransport(
newHTTPSTransport(false /*disable keep-alives*/, true /*disable auto-compression*/, maxIdle, maxIdlePerHost, tlsContext),
//newHTTPSTransport(false /*disable keep-alives*/, true /*disable auto-compression*/, maxIdle, maxIdlePerHost, tlsContext),
newH2Transport(true /*disable auto-compression*/, tlsContext),
newH2Transport(true /*disable auto-compression*/, tlsContext))
}

Expand Down

0 comments on commit 6cbf1a7

Please sign in to comment.