From: rahul Date: Wed, 30 Aug 2023 09:36:49 +0000 (+0530) Subject: Fix bug 2281: Healing operation Failing for Dual stack IP feature X-Git-Tag: release-v16.0-start~8 X-Git-Url: https://osm.etsi.org/gitweb/?a=commitdiff_plain;h=refs%2Fchanges%2F77%2F13877%2F7;p=osm%2FRO.git Fix bug 2281: Healing operation Failing for Dual stack IP feature Change-Id: I80b56dd9ea64e0a4974a0b6c93461fcd84425ae6 Signed-off-by: rahul Signed-off-by: garciadeblas --- diff --git a/NG-RO/osm_ng_ro/ns.py b/NG-RO/osm_ng_ro/ns.py index fc2b9a74..317579be 100644 --- a/NG-RO/osm_ng_ro/ns.py +++ b/NG-RO/osm_ng_ro/ns.py @@ -2001,7 +2001,11 @@ class Ns(object): net_item["model"] = interface.get("type") if interface.get("ip-address"): - net_item["ip_address"] = interface["ip-address"] + dual_ip = interface.get("ip-address").split(";") + if len(dual_ip) == 2: + net_item["ip_address"] = dual_ip + else: + net_item["ip_address"] = interface["ip-address"] if interface.get("mac-address"): net_item["mac_address"] = interface["mac-address"] diff --git a/releasenotes/notes/bug_fix_2281_Healing_operation_Failing_for_Dual_stack_IP_feature-598fc9f01d71c6aa.yaml b/releasenotes/notes/bug_fix_2281_Healing_operation_Failing_for_Dual_stack_IP_feature-598fc9f01d71c6aa.yaml new file mode 100644 index 00000000..008cd9fa --- /dev/null +++ b/releasenotes/notes/bug_fix_2281_Healing_operation_Failing_for_Dual_stack_IP_feature-598fc9f01d71c6aa.yaml @@ -0,0 +1,25 @@ +####################################################################################### +# Copyright ETSI Contributors and Others. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or +# implied. +# See the License for the specific language governing permissions and +# limitations under the License. +####################################################################################### +--- + +fixes: + - | + This change aims to fix auto heal operation failing for dual stack NS. + This is happening because the function "_process_recreate_vdu_params" + in osm-ngro/ns.py still expects a single IP instead of a list of IPs, + as it was possible after the feature that enable dual stack IPs for + VNF interfaces.