github.com/argoproj/argo-cd/v3@v3.2.1/resource_customizations/numaflow.numaproj.io/InterStepBufferService/health.lua (about) 1 local hs = {} 2 local healthy = {} 3 4 if obj.status ~= nil then 5 if obj.status.conditions ~= nil then 6 for i, condition in ipairs(obj.status.conditions) do 7 if condition.status == "False" then 8 healthy.status = "False" 9 healthy.message = condition.message 10 end 11 end 12 end 13 14 if obj.metadata.generation == obj.status.observedGeneration then 15 if (healthy ~= {} and healthy.status == "False") or obj.status.phase == "Failed" then 16 hs.status = "Degraded" 17 if obj.status.phase == "Failed" then 18 hs.message = obj.status.message 19 else 20 hs.message = healthy.message 21 end 22 return hs 23 elseif obj.status.phase == "Running" then 24 hs.status = "Healthy" 25 hs.message = "InterStepBufferService is healthy" 26 return hs 27 end 28 end 29 end 30 31 hs.status = "Progressing" 32 hs.message = "Waiting for InterStepBufferService status" 33 return hs