Skip to content

Commit 727a5b3

Browse files
authored
fix: correcting the condition for switching to cold storages (#301)
1 parent 4c86707 commit 727a5b3

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

storeapi/grpc_search.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -83,7 +83,7 @@ func (g *GrpcV1) doSearch(
8383

8484
// in store mode hot we return error in case request wants data, that we've already rotated
8585
if g.config.StoreMode == StoreModeHot {
86-
if g.fracManager.Flags().IsCapacityExceeded() && g.earlierThanOldestFrac(uint64(from)) {
86+
if g.fracManager.Flags().IsCapacityExceeded() && g.earlierThanOldestFrac(uint64(req.From)) {
8787
metric.RejectedRequests.WithLabelValues("search", "old_data").Inc()
8888
return &storeapi.SearchResponse{Code: storeapi.SearchErrorCode_INGESTOR_QUERY_WANTS_OLD_DATA}, nil
8989
}

0 commit comments

Comments
 (0)