piyush5netapp commented on PR #13053:
URL: https://github.com/apache/cloudstack/pull/13053#issuecomment-4829679447

   @winterhazel Correct me if this is what you are trying to suggest as per my 
understanding on this comment 
https://github.com/apache/cloudstack/pull/13053#discussion_r3223364310 -  We 
are doing volumeInfo.get_iScsiName() in 
VolumeServiceImpl.createManagedVolumeCopyTemplateAsync whose value  is set 
during OntapPrimaryDatastoreDriver.grantAccess from db. Instead of setting 
details.put(PrimaryDataStore.MANAGED_STORE_TARGET, managedStoreTarget) using 
that value, set the PrimaryDataStore.MANAGED_STORE_TARGET in 
OntapPrimaryDatastoreDriver.grantAccess itself. This will save one db call 
happening in VolumeServiceImpl.createManagedVolumeCopyTemplateAsync right ? 
   
   If yes, I had 2 reasons of not pursuing that- 
   1. Since the details is Map<String,String> and MANAGED_STORE_TARGET and 
other keys is specific(used by) by core code instead of vendor, vendor need not 
to remember the key (Also having key as String type can be error prone by 
vendors). 
   2. Existing code 1323-1330  also set the details here instead of any storage 
vendor setting those in either createAsync or grantAccess.
   
   My understanding was that the vendor should be responsible for updating the 
right data in volume fields like iscsi_name, path , pool_type etc instead of 
setting key,value in details map which can be used by orchestrator code. 
   
   Let me know if I misunderstood something. 


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to