Remove inspector client usage

This is not used anymore and py37/38 jobs are broken as it's
not in requierements. Not sure what was installing it earlier.

Closes-Bug: #1995566
Change-Id: I42694d4042574eb1adeb84b66eef637f7f5178a3
(cherry picked from commit aa47e5499c)
This commit is contained in:
rabi 2022-11-03 12:54:13 +05:30 committed by Rabi Mishra
parent d2323bb1e6
commit 93bc07799c
1 changed files with 0 additions and 33 deletions

View File

@ -28,33 +28,12 @@ from tripleo_common.utils import heat as tc_heat_utils
from tripleo_common.utils import nodes
from tripleo_common.utils import parameters
import ironic_inspector_client
class TripleOCommon(object):
def __init__(self, session):
self.sess = session
self.client_cache = dict()
def get_ironic_inspector_client(self):
"""Return the ironic inspector client.
This method will return a client object using the legacy library. Upon
the creation of a successful client creation, the client object will
be stored in the `self.client_cache object`, should this method be
called more than once, the cached object will automatically return,
resulting in fewer authentications and faster API interactions.
:returns: Object
"""
if 'ironic_inspector_client' in self.client_cache:
return self.client_cache['ironic_inspector_client']
else:
self.client_cache['ironic_inspector_client'] = \
ironic_inspector_client.ClientV1(session=self.sess)
return self.client_cache['ironic_inspector_client']
def get_orchestration_client(self):
"""Return the orchestration (heat) client.
@ -102,15 +81,3 @@ class TripleOCommon(object):
os_ironic_api_version='1.36'
)
return self.client_cache['ironicclient']
def return_introspected_node_data(self, node_id):
"""Return baremetal data from the ironic inspector.
:param node_id: Node UUID
:type node_id: String
:returns: Object
"""
client = self.get_ironic_inspector_client()
return client.get_data(node_id=node_id)