mirror of
https://github.com/kubernetes-sigs/kustomize.git
synced 2026-06-11 17:12:51 +00:00
Log response status code to help debug
Recently, the crawler job often fails after 10+ hours with the following error (10.0.47.27:9200 is the ElasticSearch master): dial tcp 10.0.47.27:9200: connect: connection refused
This commit is contained in:
@@ -87,7 +87,7 @@ func (idx *index) responseErrorOrNil(info string, res *esapi.Response,
|
|||||||
|
|
||||||
defer res.Body.Close()
|
defer res.Body.Close()
|
||||||
if res.IsError() {
|
if res.IsError() {
|
||||||
return fmt.Errorf("%s: %s", messageStart, res.String())
|
return fmt.Errorf("%s: %s [%d]", messageStart, res.String(), res.StatusCode)
|
||||||
}
|
}
|
||||||
|
|
||||||
if reader != nil {
|
if reader != nil {
|
||||||
|
|||||||
Reference in New Issue
Block a user