Evaluate data age against a maximum threshold and label the freshness state.

Data Freshness Report

data_freshness.lua
local age_minutes = 
local max_age = 30
local fresh_status = "aging"

if age_minutes <= 10 then
  fresh_status = "fresh"
elseif age_minutes > max_age then
  fresh_status = "stale"
end

print("age=" .. age_minutes .. " max=" .. max_age .. " status=" .. fresh_status)
local age_minutes = 
local max_age = 30
local fresh_status = "aging"

if age_minutes <= 10 then
  fresh_status = "fresh"
elseif age_minutes > max_age then
  fresh_status = "stale"
end

print("age=" .. age_minutes .. " max=" .. max_age .. " status=" .. fresh_status)
local age_minutes = 
local max_age = 30
local fresh_status = "aging"

if age_minutes <= 10 then
  fresh_status = "fresh"
elseif age_minutes > max_age then
  fresh_status = "stale"
end

print("age=" .. age_minutes .. " max=" .. max_age .. " status=" .. fresh_status)
data freshness Data freshness compares recorded age against a configured maximum to flag stale inputs early.