- resp = self._http.get_cmd('{}/{}'.format(self._apiBase, vnf_id))
- #print('RESP: {}'.format(resp))
- if resp:
- return resp
- raise NotFound("vnf {} not found".format(name))
-
+ try:
+ _, resp = self._http.get2_cmd('{}/{}'.format(self._apiBase, vnf_id))
+ #print('RESP: {}'.format(resp))
+ if resp:
+ return json.loads(resp)
+ except NotFound:
+ raise NotFound("vnf '{}' not found".format(name))
+ raise NotFound("vnf '{}' not found".format(name))