azure-sdk-for-cpp icon indicating copy to clipboard operation
azure-sdk-for-cpp copied to clipboard

[Consistency] BackupClient should not accept Azure::Core::Url as input param, but rather std::string.

Open ahsonkhan opened this issue 1 year ago • 0 comments

We recently introduced BackupClient in azure-security-keyvault-administration: https://github.com/Azure/azure-sdk-for-cpp/pull/5744

It should accept input urls as std::string, instead of Azure::Core::Url following the consistent pattern from the rest of the SDK clients. When the user needs to pass a blobContainerUrl parameter, they would get it from the GetUrl() method, which returns the std::string: https://github.com/Azure/azure-sdk-for-cpp/blob/7e9246794a9774f656fc0dceba0fb9ca2a3fcedc/sdk/storage/azure-storage-blobs/inc/azure/storage/blobs/blob_container_client.hpp#L124

Calling out some examples, but we should evaluate all cases: https://github.com/Azure/azure-sdk-for-cpp/blob/7e9246794a9774f656fc0dceba0fb9ca2a3fcedc/sdk/keyvault/azure-security-keyvault-administration/inc/azure/keyvault/administration/backup_client.hpp#L74-L77 https://github.com/Azure/azure-sdk-for-cpp/blob/7e9246794a9774f656fc0dceba0fb9ca2a3fcedc/sdk/keyvault/azure-security-keyvault-administration/inc/azure/keyvault/administration/backup_client.hpp#L102-L106

Note, the BackupClient ctor is following the pattern from across KeyVault, as expected, for the vaultUrl: https://github.com/Azure/azure-sdk-for-cpp/blob/7e9246794a9774f656fc0dceba0fb9ca2a3fcedc/sdk/keyvault/azure-security-keyvault-administration/inc/azure/keyvault/administration/backup_client.hpp#L57-L60

ahsonkhan avatar Aug 29 '24 22:08 ahsonkhan