X-Git-Url: https://gerrit.o-ran-sc.org/r/gitweb?a=blobdiff_plain;f=o2ims%2Fviews%2Focloud_dto.py;h=7d1b8f634af021641cfbd66e6a6aca788dfa2093;hb=refs%2Fheads%2Fmaster;hp=f283ca0de521f7a805c8d103f180a83f9c8b5269;hpb=e1c1a75b2ca93f9d05a9431093554002efff994d;p=pti%2Fo2.git diff --git a/o2ims/views/ocloud_dto.py b/o2ims/views/ocloud_dto.py index f283ca0..a35be4b 100644 --- a/o2ims/views/ocloud_dto.py +++ b/o2ims/views/ocloud_dto.py @@ -89,11 +89,11 @@ class OcloudDTO: # 'smoRegistrationService': fields.String 'extensions': fields.String( example='', - description='These are unspecified (not standardized) ' +\ - 'properties (keys) which are tailored by the vendor ' +\ + description='These are unspecified (not standardized) ' + + 'properties (keys) which are tailored by the vendor ' + 'to extend the information provided about the O-Cloud.'), }, - mask='{oCloudId,globalCloudId,globalcloudId,name,description,' +\ + mask='{oCloudId,globalCloudId,globalcloudId,name,description,' + 'serviceUri}' ) @@ -264,9 +264,9 @@ class ResourcePoolDTO: # 'resources': fields.String, 'extensions': fields.String( example='', - description='List of metadata key-value pairs ' +\ - 'used to associate meaningful metadata to ' +\ - 'the related resource pool.') + description=('List of metadata key-value pairs ' + 'used to associate meaningful metadata to ' + 'the related resource pool.')) }, mask='{resourcePoolId,oCloudId,globalLocationId,name,description}' ) @@ -367,6 +367,22 @@ class DeploymentManagerDTO: 'the Deployment Manager'), }) + capacity = api_ims_inventory_v1.model( + "DeploymentManagerCapacity", { + 'cpu': fields.String( + example='32', + description='Show the cpu capacity of ' + + 'the Deployment Manager'), + 'hugepages-2Mi': fields.String( + example='2048', + description='Show the 2Mi hugepages capacity of ' + + 'the Deployment Manager'), + 'hugepages-1Gi': fields.String( + example='2048', + description='Show the 1Gi hugepages capacity of ' + + 'the Deployment Manager'), + }) + deployment_manager_list = api_ims_inventory_v1.model( "DeploymentManagerListDto", { @@ -389,11 +405,12 @@ class DeploymentManagerDTO: example='https://128.224.115.51:6443', description='The fully qualified URI to a Deployment ' + 'Management server for O2dms.'), + # Comment for the future implementation # 'deploymentManagementServiceEndpoint': fields.String( # attribute='serviceUri'), - # 'supportedLocations': fields.String, + 'supportedLocations': fields.String, 'capabilities': fields.Nested(capabilities, True, True), - # 'capacity': fields.String, + 'capacity': fields.Nested(capacity, True, True), 'profileSupportList': fields.List( fields.String, example=['native_k8sapi'], @@ -405,8 +422,8 @@ class DeploymentManagerDTO: 'associate meaningful metadata to the related Deployment ' + 'Manager'), }, - mask='{deploymentManagerId,name,description,oCloudId,serviceUri,' + \ - 'profileSupportList}' + mask='{deploymentManagerId,name,description,oCloudId,serviceUri,' + + 'supportedLocations,capabilities,capacity,profileSupportList}' ) profile = api_ims_inventory_v1.model("DeploymentManagerGetDtoProfile", { @@ -480,12 +497,13 @@ class DeploymentManagerDTO: 'Management server for O2dms.'), # 'deploymentManagementServiceEndpoint': fields.String( # attribute='serviceUri'), - # 'supportedLocations': fields.String, + 'supportedLocations': fields.String, 'capabilities': fields.Nested(capabilities, True, True), - # 'capacity': fields.String, + 'capacity': fields.Nested(capacity, True, True), 'extensions': fields.Nested(extensions, True, True) }, - mask='{deploymentManagerId,name,description,oCloudId,serviceUri,' +\ + mask='{deploymentManagerId,name,description,oCloudId,serviceUri,' + + 'supportedLocations,capabilities,capacity,' + 'extensions{profileName,profileData}}' )