Quri

Stale-while-revalidate

Last updated 2026-06-14

Definition

Stale-while-revalidate serves you the last cached answer instantly, then refreshes it in the background. Your screen fills right away with recent numbers instead of spinning on a cold fetch, and the fresh value swaps in moments later. You see a freshness banner so you always know how recent the figure on screen is.

How to do this in Quri

  1. Open a metric view in /app — the cached value loads at once, so nothing blocks on a slow source.
  2. Read the freshness banner near the top to see how recently that number was fetched.
  3. Quri refreshes the value in the background and quietly swaps in the newer one.
  4. Hit the refresh control if you need the latest figure before the background update lands.

Frequently asked

Am I looking at stale numbers, then?
Only for a moment, and you can see it. Quri shows the last cached value with a freshness banner, then refreshes in the background. The banner tells you how recent the figure is, so nothing pretends to be live when it is not.
How do I force the newest value right now?
Use the refresh control in the view. That triggers a fresh read from the source instead of waiting for the background update, and the banner updates to show the new fetch time.

Related terms