Windows Azure Blob存储需要太多时间吗? [英] Windows Azure Blob Storage takes too much time ?

查看:111
本文介绍了Windows Azure Blob存储需要太多时间吗?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我尝试将图像文件上传到Local Blob Storage。一切都在Azure Blob和开发Blob(在Azure模拟器上)上成功运行,但每个请求都需要花费太多时间,比如为上传图像创建blob&在Azure模拟器开发Blob上删除。



创建blob的代码是

 CloudStorageAccount storageAccount = CloudStorageAccount.Parse (RoleEnvironment.GetConfigurationSettingValue(  ImageStorageAccountConn)); 
CloudBlobClient blobClient = storageAccount.CreateCloudBlobClient();
CloudBlobContainer blobContainer = blobClient.GetContainerReference( my-blob);

if (blobContainer.CreateIfNotExists())
{
blobContainer.SetPermissions( new BlobContainerPermissions {PublicAccess = BlobContainerPublicAccessType.Blob});
}
返回 blobContainer;





什么是错误?

解决方案

是的,当您在 Azure模拟器上运行应用程序时,这是非常正常行为本地machine.B'cos它是一个模拟器。不是真正的一个。但如果你的机器有8GB或更多的RAM,那么事情将非常快。我希望这些信息可能对你有所帮助。 :)

I try to upload image file to Local Blob Storage. Everything is running successfully on Azure Blob and Development Blob (On Azure Emulator) but it takes too much time in each request like creating blob for upload image & delete on Azure Emulator Development Blob.

Code to create blob is

CloudStorageAccount storageAccount = CloudStorageAccount.Parse(RoleEnvironment.GetConfigurationSettingValue("ImageStorageAccountConn"));
            CloudBlobClient blobClient = storageAccount.CreateCloudBlobClient();
            CloudBlobContainer blobContainer = blobClient.GetContainerReference("my-blob");
             
            if (blobContainer.CreateIfNotExists())
            {
                blobContainer.SetPermissions(new BlobContainerPermissions { PublicAccess = BlobContainerPublicAccessType.Blob });
            }
            return blobContainer;



What's wrong ?

解决方案

Yep,This is quite normal behavior when you run your app on Azure emulator on your local machine.B'cos it is a emulator.Not a real one.But if your machine has a 8GB or more RAM ,then things will work very fast.I hope this information may help to you. :)


这篇关于Windows Azure Blob存储需要太多时间吗?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆