This is an automated email from the ASF dual-hosted git repository.
bbovenzi pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/airflow.git
The following commit(s) were added to refs/heads/main by this push:
new 348eb455a9d Add autorefresh to health section for live updates.
(#49645)
348eb455a9d is described below
commit 348eb455a9d22adf30768af6237369a1c2731a45
Author: Karthikeyan Singaravelan <[email protected]>
AuthorDate: Thu Apr 24 00:13:48 2025 +0530
Add autorefresh to health section for live updates. (#49645)
---
airflow-core/src/airflow/ui/src/pages/Dashboard/Health/Health.tsx | 7 ++++++-
1 file changed, 6 insertions(+), 1 deletion(-)
diff --git a/airflow-core/src/airflow/ui/src/pages/Dashboard/Health/Health.tsx
b/airflow-core/src/airflow/ui/src/pages/Dashboard/Health/Health.tsx
index 742fc36c3b6..7b85d26588f 100644
--- a/airflow-core/src/airflow/ui/src/pages/Dashboard/Health/Health.tsx
+++ b/airflow-core/src/airflow/ui/src/pages/Dashboard/Health/Health.tsx
@@ -21,11 +21,16 @@ import { MdOutlineHealthAndSafety } from "react-icons/md";
import { useMonitorServiceGetHealth } from "openapi/queries";
import { ErrorAlert } from "src/components/ErrorAlert";
+import { useAutoRefresh } from "src/utils";
import { HealthBadge } from "./HealthBadge";
export const Health = () => {
- const { data, error, isLoading } = useMonitorServiceGetHealth();
+ const refetchInterval = useAutoRefresh({});
+
+ const { data, error, isLoading } = useMonitorServiceGetHealth(undefined, {
+ refetchInterval,
+ });
return (
<Box>