nfv/nfv/nfv-plugins/nfv_plugins/nfvi_plugins
Al Bailey 94321e9d57 Debian: python3 fix for OpenStackRestAPIExceptions
When the NFV uses tasks and futures and coroutines to
interact with openstack APIs, an OpenStackRestAPIException
can be returned as a task result.

The exception needs to be 'pickled' when sent across the
queue/socket for the 'simulated' asyncio workflow.

However, the pickle code for that exception was broken in
python3. It was relying on a python2 'message' attribute
of the base Exception class to exist, which no longer
exists (in python3)

This was causing the pickle command to quietly fail and
the code waiting for the task result would timeout and
not report back the failure information.

The fix is to ensure that there is a 'message' property
on that exception type.

Unit tests have been added for all the pickleable
exceptions, to ensure their '__reduce__' and other
interactions with 'pickle' are not reporting any failures.

Test Plan:
 PASS: create and apply a kube-upgrade-strategy for an
 older version of kubernetes and observe it reports its
failure error (rather than a timeout)

Closes-Bug: #2007285
Signed-off-by: Al Bailey <al.bailey@windriver.com>
Change-Id: I3a8776163a78330810ae1097ddd1831b1b26a212
2023-02-14 15:21:13 +00:00
..
clients Fix host-delete for host that has k8s pods 2022-11-04 18:19:24 +00:00
openstack Debian: python3 fix for OpenStackRestAPIExceptions 2023-02-14 15:21:13 +00:00
__init__.py StarlingX open source release updates 2018-05-31 07:36:51 -07:00
config.ini Increase sysinv API timeout from 45 to 60 seconds 2022-08-18 15:35:17 +00:00
config.py Add support for containerized keystone to VIM 2018-10-03 08:29:08 -05:00
nfvi_block_storage_api.py Refactor nova service creation in the VIM 2019-01-11 09:23:54 -06:00
nfvi_compute_api.py Debian: Fix nova actions 2023-02-03 08:53:52 -03:00
nfvi_fault_mgmt_api.py add NFVFaultMgmtAPI to get alarms from fm in pods 2019-06-05 09:29:57 +08:00
nfvi_guest_api.py py3: Fix http server request handler wfile write parameter 2021-07-26 13:12:58 -04:00
nfvi_identity_api.py Refactor nova service creation in the VIM 2019-01-11 09:23:54 -06:00
nfvi_image_api.py Refactor nova service creation in the VIM 2019-01-11 09:23:54 -06:00
nfvi_infrastructure_api.py Improving kube rootca orchestration recovery 2021-11-25 09:11:04 -06:00
nfvi_network_api.py Remove kubernetes checks, wrs-headers from Rest API calls, and dead code. 2019-04-09 15:01:16 -04:00
nfvi_sw_mgmt_api.py py3: nfv wrap dict.keys() in list() 2021-07-26 13:13:11 -04:00
unit_test.py Remove kubernetes checks, wrs-headers from Rest API calls, and dead code. 2019-04-09 15:01:16 -04:00