Windows – 我无法从本地Azure存储模拟器,VisualStudio或Azure存储资源管理器访问队列

前端之家收集整理的这篇文章主要介绍了Windows – 我无法从本地Azure存储模拟器,VisualStudio或Azure存储资源管理器访问队列前端之家小编觉得挺不错的,现在分享给大家,也给大家做个参考。
我需要通过Azure队列发送消息,我需要使用 Windows Azure模拟器进行测试,该模拟器表示正确运行.这些是我经历的步骤:

1-运行Windows Azure存储模拟器(我尝试了2.0.0和3.2.0版本)
   确保模拟器正在运行:

>使用Windows Azure存储模拟器2.0.0时:

现在“已弃用”的UI显示所有三个存储模拟器正确运行. (我无法附加显示它的快照,因为我已经升级了VisualStudio 2013的Windows Azure存储SDK工具.
>使用Windows Azure存储模拟器3.2.0时:

[这是一个快照显示它正确运行但我没有声誉添加imgaes:s]

2-代码

string azureStorageConnectionString = "UseDevelopmentStorage=true";
        string queueName = "queuetest";

        CloudStorageAccount storageAccount = CloudStorageAccount.Parse(storageConnectionString);
        CloudQueueClient queueClient = storageAccount.CreateCloudQueueClient();
        _queue = queueClient.GetQueueReference(queueName);
        _queue.CreateIfNotExists();

3- I每个WAS Emulator版本都有两个不同的问题.

-Problem A:在行_queue.CreateIfNotExists();得到一个未找到uri的异常(404),因为它无法找到队列,使用uri:127.0.0.1:10001 / devstoreaccount1 /queuetest

-Problem B:当我升级WAS仿真器时,异常消失了(因此升级是问题A的解决方案)但Azure Storage Explorer不会访问开发人员存储帐户并提供以下消息:

Windows Azure Developer Storage is not runnign.
The process DSService.exe is not detected

总而言之,我修复了问题A,但现在我无法使用Azure存储资源管理器访问DevStorage帐户.

解决方法

配偶给了我一个惊人的解决方案.您需要创建一个名为DSService的VisualStudio项目,将其放在C:中的任何位置,并包含以下代码

namespace DSService
{
    class Program
    {
        static void Main(string[] args)
        {
            Console.ReadLine();
        }
    }
}

现在,我可以使用Azure存储资源管理器…创建,插入消息和访问DevStorage帐户队列:-0

但是,正如Gaurav Mantri所说,您还可以使用VisualStudio 2013工具查看DevStorage帐户的内容,这是一个非常好的选择.

猜你在找的Windows相关文章