summaryrefslogtreecommitdiffstats
path: root/conductor
diff options
context:
space:
mode:
authorkrishnaa96 <krishna.moorthy6@wipro.com>2021-05-05 19:44:01 +0530
committerkrishnaa96 <krishna.moorthy6@wipro.com>2021-05-06 17:01:36 +0530
commit99a779b2b42aea5eed648be065e1056ac6055d8c (patch)
treef765190999d933163fae5a5460dcf2d1aac92843 /conductor
parentd8b010d217720a10114f5db0efb1d95f2a65f8df (diff)
Modify CSIT scripts to use ETCD
Add healthcheck insert during the startup within the controller app Issue-ID: OPTFRA-947 Signed-off-by: krishnaa96 <krishna.moorthy6@wipro.com> Change-Id: I6b9a9bc4a02e24b10306395a92fd8830175e38df
Diffstat (limited to 'conductor')
-rw-r--r--conductor/conductor/controller/service.py18
1 files changed, 18 insertions, 0 deletions
diff --git a/conductor/conductor/controller/service.py b/conductor/conductor/controller/service.py
index 01ffe40..e970b65 100644
--- a/conductor/conductor/controller/service.py
+++ b/conductor/conductor/controller/service.py
@@ -86,6 +86,8 @@ class ControllerServiceLauncher(object):
if not self.OrderLock:
raise
+ self.insert_healthcheck_plan()
+
def run(self):
transport = messaging.get_transport(self.conf)
if transport:
@@ -108,3 +110,19 @@ class ControllerServiceLauncher(object):
workers=self.conf.controller.workers,
args=(self.conf,), kwargs=kwargs)
svcmgr.run()
+
+ def insert_healthcheck_plan(self):
+ healthcheck_plan = {
+ "id": "healthcheck",
+ "created": 1479482603641,
+ "message": "",
+ "name": "foo",
+ "recommend_max": "1",
+ "solution": "{\"healthcheck\": \" healthcheck\"}",
+ "status": "solved",
+ "template": "{\"healthcheck\": \"healthcheck\"}",
+ "timeout": 3600,
+ "translation": "{\"healthcheck\": \" healthcheck\"}",
+ "updated": 1484324150629
+ }
+ self.music.row_create(self.conf.keyspace, "plans", "id", "healthcheck", healthcheck_plan)