蔚蓝辅助角色的内部异常之一请求输入超出范围。“ [英] Azure Worker role Inner Exception of 'One of the request inputs is out of range.'

查看:195
本文介绍了蔚蓝辅助角色的内部异常之一请求输入超出范围。“的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我打电话CloudTableClient.CreateTableIfNotExist方法在我的工人角色,我得到的异常与内部异常其中一个请求输入超出范围。

I'm calling the CloudTableClient.CreateTableIfNotExist Method in my worker role and I'm getting an exception with an Inner Exception of 'One of the request inputs is out of range.'

我做了一些研究,发现这是由命名表一个非法的表名,不过,我已经试过名我的桌子几个不同的名字造成的,一切都没有成功。有些我已经试过表名是:

I did a little research and found that this is caused by naming the table an illegal table name, however, I've tried name my table several different names and all have not succeeded. Some of the table names I've tried are:


  • 例外

  • exceptioninfo

  • listoferrors

他们都失败了同样的错误。

All of them have failed with the same error.

修改

下面是code,我使用创建表:

Here is the code that I'm using to create the table:

    public static void InitializeTableStorage()
    {
        var storageAccount = CloudStorageAccount.Parse(CloudConfigurationManager.GetSetting(Constants.StorageConnectionString));
        // Retrieve storage account from connection-string
        // Create the table client

        CloudTableClient tableClient = storageAccount.CreateCloudTableClient();

        // Create the table if it doesn't exist
        string tableName = ExceptionsTableName;
        tableClient.CreateTableIfNotExist(tableName);
    }

这里是HTTP请求的错误了:

And here is the HTTP request that errors out:

请求:

GET https://<account>.table.core.windows.net/Tables('exceptioninfo') HTTP/1.1
User-Agent: Microsoft ADO.NET Data Services
DataServiceVersion: 1.0;NetFx
MaxDataServiceVersion: 2.0;NetFx
x-ms-version: 2011-08-18
x-ms-date: Mon, 03 Sep 2012 21:54:20 GMT
Authorization: SharedKeyLite <AccountName>:aBcDeFgAbCdEfGhIjKlMnOpQrStUba+jKlMn/DqrsTu=
Accept: application/atom+xml,application/xml
Accept-Charset: UTF-8
Host: <account>.table.core.windows.net
Connection: Keep-Alive

&LT;帐户&GT; 都是小写和&LT; AcountName&GT; 是骆驼的情况下(如果这意味着什么)
这里是回应:

<account> is all lowercase and <AcountName> is camel case (if that means anything) Here is the response:

HTTP/1.1 400 One of the request inputs is out of range.
Content-Length: 343
Content-Type: application/xml
Server: Microsoft-HTTPAPI/2.0
x-ms-request-id: abcdefgh-ijkl-44ed-9ff2-3d07df99c266
Date: Mon, 03 Sep 2012 21:54:03 GMT


<?xml version="1.0" encoding="utf-8" standalone="yes"?>
<error xmlns="http://schemas.microsoft.com/ado/2007/08/dataservices/metadata">
  <code>OutOfRangeInput</code>
  <message xml:lang="en-US">One of the request inputs is out of range.
RequestId:abcdefgh-ijkl-44ed-9ff2-3d07df99c266
Time:2012-09-03T21:54:03.6716225Z</message>
</error>

我用同样的CloudStorageAccount创建队列和斑点,并已取得了成功。

I've used the same CloudStorageAccount to create Queues and Blobs, and have succeeded.

还有没有其他原因让试图建立在蔚蓝的一个表时OutOfRange例外呢?

are there any other reasons to get an OutOfRange exception when trying to create a table in azure?

推荐答案

我找到了。

纵观HTTP请求和响应,我一直在从成功的队列请求和失败请求表得到,似乎如果账户名称有任何大写字母,都失败。

Looking at the HTTP requests and responses that I've been getting from successful Queue requests and the failing Table requests, it seems if the Account Name has any uppercase letters, everything fails.

要解决这个问题,我改变了帐户名全部为小写字母和一切工作

To fix this, I changed the Account Name to be all lower case and everything worked

这篇关于蔚蓝辅助角色的内部异常之一请求输入超出范围。“的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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