From 165dd39c642769ca2378e2c4ff813b962690723c Mon Sep 17 00:00:00 2001 From: Gustavo Herzmann Date: Thu, 14 Mar 2024 18:37:29 -0300 Subject: [PATCH] Fix bootstrap_address parameter name during PGA sync This commit changes the bootstrap address parameter from "bootstrap-address" to "bootstrap_address" during the subcloud update call made during the PGA sync operation. This fixes the issue where the bootstrap_address was not being updated on the peer site, as the subcloud update API expects the "bootstrap_address" parameter, with an underscore. Test Plan: 1. PASS - Create a peer group association and let it do the initial sync. Modify the bootstrap-address of the subcloud using the subcloud update command and then run the PGA sync command. Verify that the rehome_data of the secondary subcloud was updated with the new address. Closes-Bug: 2057973 Change-Id: Ib5786a56c90f771b940e740bc095ebc8168d2830 Signed-off-by: Gustavo Herzmann --- distributedcloud/dcmanager/manager/system_peer_manager.py | 3 +++ 1 file changed, 3 insertions(+) diff --git a/distributedcloud/dcmanager/manager/system_peer_manager.py b/distributedcloud/dcmanager/manager/system_peer_manager.py index b2a15dc34..17c3fdf5a 100644 --- a/distributedcloud/dcmanager/manager/system_peer_manager.py +++ b/distributedcloud/dcmanager/manager/system_peer_manager.py @@ -307,6 +307,9 @@ class SystemPeerManager(manager.Manager): # Sync subcloud information to peer site peer_subcloud = self.get_peer_subcloud(dc_client, subcloud_name) if peer_subcloud: + # The subcloud update API expects 'bootstrap_address' + # instead of 'bootstrap-address' + data["bootstrap_address"] = data.pop(consts.BOOTSTRAP_ADDRESS) dc_peer_subcloud = dc_client.update_subcloud(region_name, files, data, is_region_name=True)