From 9fa8a7124e5fbf588f8b18fb73262ac32d6e6396 Mon Sep 17 00:00:00 2001 From: Jarrod Johnson Date: Fri, 11 Nov 2022 14:33:54 -0500 Subject: [PATCH] Pull the typical XCC scanning to remote registration path --- confluent_server/confluent/discovery/core.py | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/confluent_server/confluent/discovery/core.py b/confluent_server/confluent/discovery/core.py index 26646cee..59a19e1a 100644 --- a/confluent_server/confluent/discovery/core.py +++ b/confluent_server/confluent/discovery/core.py @@ -484,8 +484,10 @@ def handle_api_request(configmanager, inputdata, operation, pathcomponents): sd['hwaddr'] = sd['attributes']['mac-address'] if not sd: raise exc.Unsupported('Target address is not a supported device for remote discovery registration') - detected(sd) - return msg.CreatedResource(inputdata['address']) + nh = xcc.NodeHandler(sd, configmanager) + nh.scan() + detected(nh.info) + return [msg.CreatedResource(inputdata['address'])] if 'node' not in inputdata: raise exc.InvalidArgumentException('Missing node name in input') mac = _get_mac_from_query(pathcomponents)