1
我正在蔚藍工作,可以請你幫我如何將參數傳遞給存儲空間在天藍色。如何將參數傳遞給存儲Uri?
這裏他們有5個參數credientials,blob,隊列,表,文件 如何傳遞參數?請檢查下面的代碼。
enter code here
Microsoft.WindowsAzure.Storage.CloudStorageAccount storageAccount = null;
string AccountName = RoleEnvironment.GetConfigurationSettingValue("AccountName");
string AccountKey = RoleEnvironment.GetConfigurationSettingValue("AccountKey");
StorageCredentialsAccountAndKey credentials = new StorageCredentialsAccountAndKey(AccountName, AccountKey);
storageAccount = new Microsoft.WindowsAzure.Storage.CloudStorageAccount(credentials,
new StorageUri(),
new StorageUri("https://{0}.queue.core.windows.net"),
new StorageUri("https://{0}.table.core.windows.net"),
new StorageUri("https://{0}.table.core.windows.net"));
有你想通過這些存儲URI參數的原因是什麼?從你的問題看,你似乎連接到標準的存儲端點。 –
是的,當我們通過「DefaultEndpointsProtocol = https我們面臨一些問題,所以我們從StorageCredentialsAccountAndKey或StorageCredentials傳遞accntnt名稱和密鑰,以便它的需要終點,你可以幫我如何傳遞存儲參數 – stpdevi