X-Git-Url: https://osm.etsi.org/gitweb/?a=blobdiff_plain;f=rwlaunchpad%2Fplugins%2Frwpkgmgr%2Frift%2Ftasklets%2Frwpkgmgr%2Frpc.py;h=5c3303f4293789fc73a2afbd39bcdf56907d2be0;hb=436f5d472455968c482eb07e699084b2fda0d59b;hp=a71f10855dd1a8a789ae5685e1f20dc19d06f11c;hpb=5961867a2cc6674a576e1a2fb836c1bf5779ec12;p=osm%2FSO.git diff --git a/rwlaunchpad/plugins/rwpkgmgr/rift/tasklets/rwpkgmgr/rpc.py b/rwlaunchpad/plugins/rwpkgmgr/rift/tasklets/rwpkgmgr/rpc.py index a71f1085..5c3303f4 100644 --- a/rwlaunchpad/plugins/rwpkgmgr/rift/tasklets/rwpkgmgr/rpc.py +++ b/rwlaunchpad/plugins/rwpkgmgr/rift/tasklets/rwpkgmgr/rpc.py @@ -56,8 +56,9 @@ class EndpointDiscoveryRpcHandler(mano_dts.AbstractRpcHandler): def callback(self, ks_path, msg): """Forwards the request to proxy. """ + url = yield from self.proxy.endpoint( - msg.package_type, + msg.package_type if msg.has_field('package_type') else "", msg.package_id) rpc_op = RPC_PKG_ENDPOINT.from_dict({"endpoint": url}) @@ -192,10 +193,13 @@ class PackageDeleteOperationsRpcHandler(mano_dts.AbstractRpcHandler): rpc_op = RPC_PACKAGE_DELETE_ENDPOINT.from_dict({"status": str(True)}) try: + package_file_type = msg.vnfd_file_type.lower() \ + if msg.package_type == 'VNFD' else msg.nsd_file_type.lower() self.proxy.package_file_delete( msg.package_type, msg.package_id, - msg.package_path) + msg.package_path, + package_file_type) except Exception as e: self.log.exception(e) rpc_op.status = str(False)