#8276·thanos

query frontend cache could be nil

Author: zdyj3170101136Created May 27, 2025Updated Sep 13, 2026
Labelsbugcomponent: query-frontend

Thanos, Prometheus and Golang version used:

thanos:

v0.34.1

Object Storage Provider:

oss

What happened:

when query frontend enable cache, the data in cache could be nil.

query now-4h to now( 2025-05-27 19:46), the oldest data is 2025-05-27 17:21:00 Image

query now-4h to now-3h, the jaeger show all data hit cache.

and there is no result.

What you expected to happen:

it should have result, when enable query frontend cache.

Anything else we need to know: i have two query frontend node.

so sometimes the grafana return result is correct, sometimes is not.

after disable cache, everything work well.

cache config:

    - --query-range.response-cache-max-freshness=10m
    - --labels.response-cache-max-freshness=10m
    - --cache-compression-type=snappy
    - |-
      --query-range.response-cache-config="config":
        "max_size": "1GB"
        "max_size_items": 0
        "validity": "0s"
      "type": "IN-MEMORY"
    - |-
      --labels.response-cache-config="config":
        "max_size": "100MB"
        "max_size_items": 0
        "validity": "0s"
      "type": "IN-MEMORY"