Fix bug 2216 to remove hardcoded numa affinity in VIO 80/12980/1
authorgarciadeblas <gerardo.garciadeblas@telefonica.com>
Mon, 13 Feb 2023 16:48:32 +0000 (17:48 +0100)
committeraticig <gulsum.atici@canonical.com>
Wed, 15 Feb 2023 10:35:19 +0000 (11:35 +0100)
Change-Id: I0912c2841e7c5c1febe056ba092afedaea77f6a1
Signed-off-by: garciadeblas <gerardo.garciadeblas@telefonica.com>
(cherry picked from commit 3822010a26b2e21290b6acdf288db277c7f36605)

RO-VIM-openstack/osm_rovim_openstack/tests/test_vimconn_openstack.py
RO-VIM-openstack/osm_rovim_openstack/vimconn_openstack.py
releasenotes/notes/fix_bug_2216-b03687f2d9d422fa.yaml [new file with mode: 0644]
tox.ini

index eb8da2f..7b81510 100644 (file)
@@ -7763,7 +7763,6 @@ class TestNewFlavor(unittest.TestCase):
         numa_nodes = 0
         extra_specs = {"hw:numa_nodes": "0"}
         expected_extra_spec = {
-            "vmware:extra_config": '{"numa.nodeAffinity":"0"}',
             "vmware:latency_sensitivity_level": "high",
             "hw:numa_nodes": "0",
         }
@@ -7795,7 +7794,6 @@ class TestNewFlavor(unittest.TestCase):
         expected_extra_spec = {
             "vmware:latency_sensitivity_level": "high",
             "hw:numa_nodes": "None",
-            "vmware:extra_config": '{"numa.nodeAffinity":"0"}',
         }
         self.vimconn.process_vio_numa_nodes(numa_nodes, extra_specs)
         self.assertDictEqual(extra_specs, expected_extra_spec)
index 36f6e31..94d5827 100644 (file)
@@ -1393,10 +1393,6 @@ class vimconnector(vimconn.VimConnector):
             extra_specs     (dict):        Extra specs dict to be updated
 
         """
-        # If there is not any numa, numas_nodes equals to 0.
-        if not numa_nodes:
-            extra_specs["vmware:extra_config"] = '{"numa.nodeAffinity":"0"}'
-
         # If there are several numas, we do not define specific affinity.
         extra_specs["vmware:latency_sensitivity_level"] = "high"
 
diff --git a/releasenotes/notes/fix_bug_2216-b03687f2d9d422fa.yaml b/releasenotes/notes/fix_bug_2216-b03687f2d9d422fa.yaml
new file mode 100644 (file)
index 0000000..46094ba
--- /dev/null
@@ -0,0 +1,28 @@
+#######################################################################################
+# 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:
+  - |
+    Fix Bug 2216 All deployments with EPA in VIO land in NUMA node 0
+    This fix removes the hardcoded decision that makes all deployments
+    withe EPA land in NUMA node 0.
+    The fix removes the extra_spec "vmware:extra_config" that was previously
+    set to '{"numa.nodeAffinity":"0"}'.
+    It maintains the extra_spec "vmware:latency_sensitivity_level", set to "high"
+    for deployments with EPA.
+
+
diff --git a/tox.ini b/tox.ini
index 04a5ad5..3aca1a4 100644 (file)
--- a/tox.ini
+++ b/tox.ini
@@ -72,7 +72,7 @@ deps =  {[testenv]deps}
         -r{toxinidir}/requirements-dev.txt
         -r{toxinidir}/requirements-test.txt
 skip_install = true
-whitelist_externals = sh
+allowlist_externals = sh
 commands =
         sh -c 'rm -f nosetests.xml'
         coverage erase