Windows Azure Storage 3.0.1.0与Azure Storage Emulator 2.2.0.0兼容问题
来源:互联网 发布:工商数据采集工具 编辑:程序博客网 时间:2024/06/08 02:04
两天前,在Visual Studio 2013上通过NuGet安装了 Windows Azure Storage 3.0.1.0 客户端类库,该版本是12月份刚刚更新的,如下图所示。 但是在调用 CreateIfNotExists() 通过本地的 Windows Storage Emulator 2.2.0.0 创建Windows Azure Table时,总是抛出异常 : A first chance exception of type 'Microsoft.WindowsAzure.Storage.StorageException' occurred in Microsoft.WindowsAzure.Storage.dll. Additional Information : The remote server returned an error : (400) Bad Request。所使用创建代码非常简单:
// Creates Changeset table if not existsvar client = StorageAccount.CreateCloudTableClient();table = client.GetTableReference(tableName);table.CreateIfNotExists();
不应该是Windows Azure Storage APIs使用的问题。进一步检查给出的异常信息,发现其Response.StatusCode = BadRequest; Response.StatusDescription = The value for one of the HTTP headers is not in the correct format。在网上搜索了一下,已经有人报过类似的问题,但原因也是多种,比如:Table名字中包含非法字符的等。
此外,也有人提到有可能是Azure Storage API和Emulator不兼容的问题,于是将正在使用的Windows Azure Storage由3.0.1.0降到一个月前的版本 2.1.0.4,在安装了2.1.0.4后,同样的代码运行一切正常。看来确实是 Windows Azure Storage 3.0.1.0 和 Windows Azure Storage Enumlator 2.2.0.0 的兼容问题,解决的办法就是将Storage类库降级到较早的版本。不仅是3.0.1.0,在我的环境中Windows Azure Storage 3.0.0 也有类似与Storage Emulator的兼容的问题。
- Windows Azure Storage 3.0.1.0与Azure Storage Emulator 2.2.0.0兼容问题
- Troubleshooting - Windows Azure Storage Emulator Cannot Start
- Windows Azure Storage浏览器
- Windows Azure Storage
- (Solution)Failed to initialize Windows Azure storage emulator.
- Windows Azure Storage Emulator 无法安装和无法启动问题
- Windows Azure Introduction - Storage: Blob
- 公布Windows Azure Storage Analytics
- Windows Azure Storage Analytics Features
- Microsoft Azure Tools: Failed to initialize Microsoft Azure storage emulator. The storage emulator n
- Azure HDInsight 和 Azure Storage
- Windows Azure Platform (九) Windows Azure Storage Service存储服务
- Windows Azure Storage Emulator: 另一程序正在使用此文件进程无法访问
- 云计算存储Windows Azure Storage 随笔
- 使用Windows Azure Storage Analytics新特性
- Windows Azure 之 Storage Blob 常见操作
- Windows Azure 之 Storage Queue常用操作
- Windows Azure 之 Storage Table 常用操作
- 图形和函数图像的绘制
- Windows下OpenSSL创建CA证书以及客户端和服务器端证书
- 100层扔鸡蛋 2个及多个情况
- ThinkPHP的增、删、改、查
- DP24 最优BST Optimal Binary Search Tree @geeksforgeeks
- Windows Azure Storage 3.0.1.0与Azure Storage Emulator 2.2.0.0兼容问题
- poj3255 次短生成树
- Python-核心编程-学习笔记
- Binary Tree Level Order Traversal
- DP25 子集和问题 Subset Sum Problem @geeksforgeeks
- 你有没有编程天才
- cocos2d-x游戏开发系列教程-中国象棋04-摆棋
- Exercise 5.7
- 人人code,整数取反