diff --git a/web/context.go b/web/context.go index a748137a0aa..36cd28bbf29 100644 --- a/web/context.go +++ b/web/context.go @@ -35,7 +35,12 @@ type RequestEvent struct { Slug string `json:",omitempty"` InternalErrors []string `json:",omitempty"` Error string `json:",omitempty"` - UserAgent string `json:"ua,omitempty"` + // If there is an error checking the data store for our rate limits + // we ignore it, but attach the error to the log event for analysis. + // TODO(#7796): Treat errors from the rate limit system as normal + // errors and put them into InternalErrors. + IgnoredRateLimitError string `json:",omitempty"` + UserAgent string `json:"ua,omitempty"` // Origin is sent by the browser from XHR-based clients. Origin string `json:",omitempty"` Extra map[string]interface{} `json:",omitempty"` diff --git a/wfe2/wfe.go b/wfe2/wfe.go index fe0cf7c3603..18a9d224acb 100644 --- a/wfe2/wfe.go +++ b/wfe2/wfe.go @@ -789,8 +789,7 @@ func (wfe *WebFrontEndImpl) NewAccount( wfe.sendError(response, logEvent, probs.RateLimited(err.Error()), err) return } else { - wfe.sendError(response, logEvent, web.ProblemDetailsForError(err, "While checking rate limits"), err) - return + logEvent.IgnoredRateLimitError = err.Error() } } @@ -2372,7 +2371,7 @@ func (wfe *WebFrontEndImpl) NewOrder( wfe.sendError(response, logEvent, probs.RateLimited(err.Error()), err) return } else { - wfe.sendError(response, logEvent, web.ProblemDetailsForError(err, "While checking rate limits"), err) + logEvent.IgnoredRateLimitError = err.Error() return } }