azure - 微软.WindowsAzure.存储: No valid combination of account information found

标签 azure azure-functions azure-storage-queues azure-functions-runtime

我正在使用 Azure Functions Preview,并且想要添加 QueueTrigerFunction。

函数定义如下:

[FunctionName("QueueTrigger")]        
public static void Run([QueueTrigger("testqueue1", Connection = "AzureWebJobsStorage")]string myQueueItem, TraceWriter log)
{
    log.Info($"C# Queue trigger function processed: {myQueueItem}");
}

使用 local.settings.json:

{
    "IsEncrypted": false,
  "Values": {
    "AzureWebJobsStorage": "DefaultEndpointsProtocol=https;AccountName=test1storage;AccountKey=XXXXX==;EndpointSuffix=core.windows.net/;",
    "AzureWebJobsDashboard": ""
  }
}

当我启动 VS 调试器时,收到以下错误消息:

[8/5/2017 1:07:56 AM] Microsoft.WindowsAzure.Storage: No valid combination of account information found.

我错过了什么?我需要检查 Azure 中是否有一些其他设置以确保正确配置此方案?

最佳答案

What am I missing? Is there some additional settings in Azure I need to check to make sure this scenario is correctly configured?

我可以通过提供的 AzureWebJobsStorage 连接字符串格式重现您提到的问题。请尝试从连接字符串中删除 EndpointSuffix=core.windows.net/; 。然后它在我这边工作正常。

local.settings.json:

{
  "IsEncrypted": false,
  "Values": {
    "AzureWebJobsStorage": "DefaultEndpointsProtocol=https;AccountName=storageaccountname;AccountKey=xxxxxxxxxxxx",
    "AzureWebJobsDashboard": ""
  }
}

enter image description here

关于azure - 微软.WindowsAzure.存储: No valid combination of account information found,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/45517282/

相关文章:

javascript - 如何为 Azure Functions 准备代码

Azure队列接收http请求

azure - SQL 数据库 (Paas) 中有没有办法从 Azure 存储队列插入或查看消息?

azure - 从本地计算机访问azure vm中的spark docker

azure - 有没有办法修复 Azure ML Studio 中俄语的 CSV 读取问题?

python - 从 VS Code 启动的 Azure Functions 出现 ssl 错误

runtime - 如何找到 azure 函数应用运行时的出站 IP?

c# - Azure队列存储不发送队列消息

azure - 一天后删除旧的 Azure Blob

python - 保持azure管道作业中的postgres docker容器运行