diff options
author | stark, steven <steven.stark@att.com> | 2020-08-03 13:03:24 -0700 |
---|---|---|
committer | stark, steven <steven.stark@att.com> | 2020-08-03 13:03:24 -0700 |
commit | 32409110b65b013bc65930f3cfdef09671cd3a5a (patch) | |
tree | 4bb6c95c057cdde0f08af78e7abc53e2be02fad4 /onap-client/onap_client/vid/client.py | |
parent | 9df81b14e7203d6c3911f5f36881cb5170afdccc (diff) |
[VVP] ONAP Client enhancements
Output hooks for resources. Outputs for each resource are returned as part of the complete onap-client spec when a resource is created. Hooks have been added for the SDC resources, to return the TOSCA model for each created resource.
Dynamic config change. Ability to specify and reconfigure the onap-client configuration file at runtime without restarting the current session.
Logging. Logging has been upgraded to create its own logging instance rather than the root logging instance, to avoid collisions.
Issue-ID: VVP-455
Signed-off-by: stark, steven <steven.stark@att.com>
Change-Id: I7b03411d221801fc51b80ee6a73d9491e823da56
Diffstat (limited to 'onap-client/onap_client/vid/client.py')
-rw-r--r-- | onap-client/onap_client/vid/client.py | 31 |
1 files changed, 13 insertions, 18 deletions
diff --git a/onap-client/onap_client/vid/client.py b/onap-client/onap_client/vid/client.py index 3b95618..d3d4468 100644 --- a/onap-client/onap_client/vid/client.py +++ b/onap-client/onap_client/vid/client.py @@ -36,11 +36,9 @@ # ============LICENSE_END============================================ from functools import partial -from onap_client import vid from onap_client.client.clients import Client from onap_client import config -vid_properties = vid.VID_PROPERTIES application_id = config.APPLICATION_ID @@ -51,19 +49,16 @@ class VIDClient(Client): @property def catalog_resources(self): - return CATALOG_RESOURCES - - -CATALOG_RESOURCES = { - "HEALTH_CHECK": { - "verb": "GET", - "description": "Queries VID health check endpoint", - "uri": partial( - "{endpoint}{service_path}".format, - endpoint=vid_properties.VID_ENDPOINT, - service_path=vid_properties.VID_HEALTH_CHECK_PATH, - ), - "success_code": 200, - "auth": (vid_properties.VID_USERNAME, vid_properties.VID_PASSWORD,), - }, -} + return { + "HEALTH_CHECK": { + "verb": "GET", + "description": "Queries VID health check endpoint", + "uri": partial( + "{endpoint}{service_path}".format, + endpoint=self.config.vid.VID_ENDPOINT, + service_path=self.config.vid.VID_HEALTH_CHECK_PATH, + ), + "success_code": 200, + "auth": (self.config.vid.VID_USERNAME, self.config.vid.VID_PASSWORD,), + }, + } |