Skip to content

Commit

Permalink
fix: bump timeout in server to address responseheadertimeout flake (#…
Browse files Browse the repository at this point in the history
  • Loading branch information
df-wg authored Jan 7, 2025
1 parent 7c4f209 commit c2f2131
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions router/core/timout_transport_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -102,13 +102,13 @@ func TestTimeoutTransport(t *testing.T) {
transportOpts := &SubgraphTransportOptions{
SubgraphMap: map[string]*TransportTimeoutOptions{
testSubgraphKey: {
ResponseHeaderTimeout: 3 * time.Millisecond,
ResponseHeaderTimeout: 10 * time.Millisecond,
},
},
}

headerTimeoutServer := httptest.NewServer(http.HandlerFunc(func(w http.ResponseWriter, r *http.Request) {
time.Sleep(5 * time.Millisecond) // Delayed header response
time.Sleep(50 * time.Millisecond) // Delayed header response
w.WriteHeader(http.StatusOK)
}))
defer headerTimeoutServer.Close()
Expand Down

0 comments on commit c2f2131

Please sign in to comment.