mirror of https://github.com/portainer/portainer
feat(offlinegate): improve error message BE-11402 (#163)
parent
821c1fdbef
commit
4265ae4dae
|
@ -41,8 +41,8 @@ func (o *OfflineGate) WaitingMiddleware(timeout time.Duration, next http.Handler
|
|||
}
|
||||
|
||||
if !o.lock.RTryLockWithTimeout(timeout) {
|
||||
log.Error().Msg("timeout waiting for the offline gate to signal")
|
||||
httperror.WriteError(w, http.StatusRequestTimeout, "Timeout waiting for the offline gate to signal", http.ErrHandlerTimeout)
|
||||
log.Error().Str("url", r.URL.Path).Msg("request timed out while waiting for the backup process to finish")
|
||||
httperror.WriteError(w, http.StatusRequestTimeout, "Request timed out while waiting for the backup process to finish", http.ErrHandlerTimeout)
|
||||
return
|
||||
}
|
||||
next.ServeHTTP(w, r)
|
||||
|
|
Loading…
Reference in New Issue