Skip to content

Commit 89881f2

Browse files
author
Naor Livne
committed
edge case protection against starting a worker as part of a device_group that does not exist yet
1 parent 5f38150 commit 89881f2

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

worker.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -253,7 +253,8 @@ def get_device_group_info(nebula_connection_object, device_group_to_get_info):
253253
while local_device_group_info["status_code"] == 403 and \
254254
local_device_group_info["reply"]["device_group_exists"] is False:
255255
print("device_group " + device_group + " doesn't exist in nebula cluster, waiting for it to be created")
256-
time.sleep(5)
256+
local_device_group_info = get_device_group_info(nebula_connection, device_group)
257+
time.sleep(nebula_manager_check_in_time)
257258

258259
# start all apps that are set to running on boot
259260
for nebula_app in local_device_group_info["reply"]["apps"]:

0 commit comments

Comments
 (0)