mirror of https://github.com/minio/minio.git
Check for connection errors during event transit in elasticsearch and webhook (#8273)
This commit is contained in:
parent
0e1408844b
commit
dc0dce9beb
|
@ -171,6 +171,9 @@ func (target *ElasticsearchTarget) Send(eventKey string) error {
|
|||
}
|
||||
|
||||
if err := target.send(eventData); err != nil {
|
||||
if xnet.IsNetworkOrHostDown(err) {
|
||||
return errNotConnected
|
||||
}
|
||||
return err
|
||||
}
|
||||
|
||||
|
|
|
@ -155,6 +155,9 @@ func (target *WebhookTarget) Send(eventKey string) error {
|
|||
}
|
||||
|
||||
if err := target.send(eventData); err != nil {
|
||||
if xnet.IsNetworkOrHostDown(err) {
|
||||
return errNotConnected
|
||||
}
|
||||
return err
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue