gpt4 book ai didi

azure-functions - 创建新 Azure 函数时出现此错误的原因是什么?

转载 作者:行者123 更新时间:2023-12-04 07:01:13 28 4
gpt4 key购买 nike

我创建了一个 C# Blob 触发器函数。它默认生成此代码:

public static void Run(Stream myBlob, string name, TraceWriter log)
{
log.Info($"C# Blob trigger function Processed blob\n Name:{name} \n Size: {myBlob.Length} Bytes");
}

并立即在红色弹出窗口中显示以下错误。

Error: Function ($BlobTriggerCSharp1) Error: Microsoft.Azure.WebJobs.Host: Error indexing method 'Functions.BlobTriggerCSharp1'. Microsoft.Azure.WebJobs.Host: Cannot bind parameter 'name' to type String. Make sure the parameter Type is supported by the binding. If you're using binding extensions (e.g. ServiceBus, Timers, etc.) make sure you've called the registration method for the extension(s) in your startup code (e.g. config.UseServiceBus(), config.UseTimers(), etc.).

最佳答案

修复是更改“集成”中的路径设置以附加“/{name}”

关于azure-functions - 创建新 Azure 函数时出现此错误的原因是什么?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/42127855/

28 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com