From 99dcc7cf78122fbaf3fe2fe3223886189ee1b5c9 Mon Sep 17 00:00:00 2001 From: Taha Yassine Kraiem Date: Thu, 27 Apr 2023 17:44:52 +0200 Subject: [PATCH] feat(chalice): changed health-check response --- api/chalicelib/core/health.py | 7 +++++-- ee/api/chalicelib/core/health.py | 7 +++++-- 2 files changed, 10 insertions(+), 4 deletions(-) diff --git a/api/chalicelib/core/health.py b/api/chalicelib/core/health.py index e8bf8f909..44bc6816a 100644 --- a/api/chalicelib/core/health.py +++ b/api/chalicelib/core/health.py @@ -170,8 +170,11 @@ def __get_sessions_stats(*_): cur.execute(query) row = cur.fetchone() return { - "numberOfSessionsCaptured": row["s_c"], - "numberOfEventCaptured": row["e_c"] + "health": True, + "details": { + "numberOfSessionsCaptured": row["s_c"], + "numberOfEventCaptured": row["e_c"] + } } diff --git a/ee/api/chalicelib/core/health.py b/ee/api/chalicelib/core/health.py index cbb8dcc0d..d1120e19b 100644 --- a/ee/api/chalicelib/core/health.py +++ b/ee/api/chalicelib/core/health.py @@ -174,8 +174,11 @@ def __get_sessions_stats(tenant_id, *_): cur.execute(query) row = cur.fetchone() return { - "numberOfSessionsCaptured": row["s_c"], - "numberOfEventCaptured": row["e_c"] + "health": True, + "details": { + "numberOfSessionsCaptured": row["s_c"], + "numberOfEventCaptured": row["e_c"] + } }