蔚蓝辅助角色的内部异常之一请求输入超出范围。“

编程入门 行业动态 更新时间:2024-10-08 00:30:37
本文介绍了蔚蓝辅助角色的内部异常之一请求输入超出范围。“的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧! 问题描述

我打电话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 <account>.table.core.windows/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 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="schemas.microsoft/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

更多推荐

蔚蓝辅助角色的内部异常之一请求输入超出范围。“

本文发布于:2023-10-23 02:26:14,感谢您对本站的认可!
本文链接:https://www.elefans.com/category/jswz/34/1519469.html
版权声明:本站内容均来自互联网,仅供演示用,请勿用于商业和其他非法用途。如果侵犯了您的权益请与我们联系,我们将在24小时内删除。
本文标签:蔚蓝   异常   角色

发布评论

评论列表 (有 0 条评论)
草根站长

>www.elefans.com

编程频道|电子爱好者 - 技术资讯及电子产品介绍!