@@ -52,6 +52,7 @@ const (
5252 reasonTooManyRequests = "too_many_requests"
5353 reasonResourceExhausted = "resource_exhausted"
5454 reasonTimeRangeExceeded = "time_range_exceeded"
55+ reasonResponseSizeExceeded = "response_size_exceeded"
5556 reasonTooManySamples = "too_many_samples"
5657 reasonSeriesFetched = "series_fetched"
5758 reasonChunksFetched = "chunks_fetched"
@@ -61,12 +62,13 @@ const (
6162 reasonChunksLimitStoreGateway = "store_gateway_chunks_limit"
6263 reasonBytesLimitStoreGateway = "store_gateway_bytes_limit"
6364
64- limitTooManySamples = `query processing would load too many samples into memory`
65- limitTimeRangeExceeded = `the query time range exceeds the limit`
66- limitSeriesFetched = `the query hit the max number of series limit`
67- limitChunksFetched = `the query hit the max number of chunks limit`
68- limitChunkBytesFetched = `the query hit the aggregated chunks size limit`
69- limitDataBytesFetched = `the query hit the aggregated data size limit`
65+ limitTooManySamples = `query processing would load too many samples into memory`
66+ limitTimeRangeExceeded = `the query time range exceeds the limit`
67+ limitResponseSizeExceeded = `the query response size exceeds limit`
68+ limitSeriesFetched = `the query hit the max number of series limit`
69+ limitChunksFetched = `the query hit the max number of chunks limit`
70+ limitChunkBytesFetched = `the query hit the aggregated chunks size limit`
71+ limitDataBytesFetched = `the query hit the aggregated data size limit`
7072
7173 // Store gateway limits.
7274 limitSeriesStoreGateway = `exceeded series limit`
@@ -529,6 +531,8 @@ func (f *Handler) reportQueryStats(r *http.Request, source, userID string, query
529531 reason = reasonTooManySamples
530532 } else if strings .Contains (errMsg , limitTimeRangeExceeded ) {
531533 reason = reasonTimeRangeExceeded
534+ } else if strings .Contains (errMsg , limitResponseSizeExceeded ) {
535+ reason = reasonResponseSizeExceeded
532536 } else if strings .Contains (errMsg , limitSeriesFetched ) {
533537 reason = reasonSeriesFetched
534538 } else if strings .Contains (errMsg , limitChunksFetched ) {
0 commit comments