Skip to content

Commit

Permalink
[WIP] debugging
Browse files Browse the repository at this point in the history
  • Loading branch information
norbjd committed Apr 7, 2024
1 parent c2d1697 commit 471c694
Showing 1 changed file with 6 additions and 3 deletions.
9 changes: 6 additions & 3 deletions test/gracefulshutdown/gracefulshutdown_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -21,10 +21,11 @@ package gracefulshutdown

import (
"context"
"errors"
"fmt"
"io"
"log"
"net/http"
"net/url"
"os"
"sync"
"testing"
Expand Down Expand Up @@ -168,8 +169,10 @@ func sendRequest(client *http.Client, name string, requestTimeout time.Duration)
resp, err := client.Do(req)
if err != nil {
log.Printf("sendRequest %s: err: %T, %+v", requestTimeout, err, err)
// EOF is returned when Envoy cuts the connection
if err == io.EOF {

var errURL *url.Error
if errors.As(err, &errURL) {
log.Printf("sendRequest %s: err: %T, %+v", requestTimeout, errURL, errURL)
return 0, nil
}

Expand Down

0 comments on commit 471c694

Please sign in to comment.