diff options
author | Haibin Huang <haibin.huang@intel.com> | 2020-01-14 02:47:57 -0800 |
---|---|---|
committer | Haibin Huang <haibin.huang@intel.com> | 2020-01-14 03:12:01 -0800 |
commit | d331bc744dc365d24818481a3ca7118ba1f05b29 (patch) | |
tree | d03436753132f3e72501073f32b98b9d386c54e5 /multivimbroker | |
parent | 0f0175254dc2ea1d3e995f7abe00552f36d7bf53 (diff) |
Add Get register api implementation in framework
the openstack plugin have implemented the api, so we also need to
implement it in the framework, then user can call it
Issue-ID: MULTICLOUD-740
Signed-off-by: Haibin Huang <haibin.huang@intel.com>
Change-Id: I16bc23dffd15e0d7a21d6ace090757a8f444e14f
Diffstat (limited to 'multivimbroker')
-rw-r--r-- | multivimbroker/multivimbroker/forwarder/views.py | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/multivimbroker/multivimbroker/forwarder/views.py b/multivimbroker/multivimbroker/forwarder/views.py index 80146b6..898acc5 100644 --- a/multivimbroker/multivimbroker/forwarder/views.py +++ b/multivimbroker/multivimbroker/forwarder/views.py @@ -72,6 +72,11 @@ class Registry(BaseServer): return self.send(vimid, request.get_full_path(), request.body, "POST", headers=originHeaders(request)) + def get(self, request, vimid): + + return self.send(vimid, request.get_full_path(), request.body, "GET", + headers=originHeaders(request)) + class UnRegistry(BaseServer): @@ -177,6 +182,10 @@ class APIv1Identity(Identity): class APIv1Registry(Registry): + def get(self, request, cloud_owner, cloud_region_id): + vimid = extsys.encode_vim_id(cloud_owner, cloud_region_id) + return super(APIv1Registry, self).get(request, vimid) + def post(self, request, cloud_owner, cloud_region_id): vimid = extsys.encode_vim_id(cloud_owner, cloud_region_id) return super(APIv1Registry, self).post(request, vimid) |