找不到本地主机元数据文件' host.json'

发布于 2025-02-13 23:13:48 字数 240 浏览 0 评论 0 原文

我想使用azure-funnctions核心工具“ func Durable delete-task-Hub”此命令在存储帐户下删除TaskHub(我具有当前上下文的存储的连接字符串)。但是当我运行此命令时,它报告:

找不到本地主机元数据文件'host.json' 无法找到项目根。期望在项目root中找到host.json,local.settings.json之一。

我可以使用此命令在Azure Portal中删除TaskHub吗?

I want to use azure-functions-core-tools "func durable delete-task-hub" this command to delete taskhub under a storage account (I have current context's storage's connection string). But when I run this command, it reports:

Could not find local host metadata file 'host.json'
Unable to find project root. Expecting to find one of host.json, local.settings.json in project root.

Could I use this command to delete taskhub in azure portal?

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

只为守护你 2025-02-20 23:13:48

我可以使用此命令在Azure Portal中删除TaskHub?

Azure函数核心工具命令用于从您的本地IDE终端或命令提示符中运行,如

找不到本地主机元数据文件'host.json'找不到项目root。期望在项目root中找到一个host.json,local.settings.json。

您必须将任务中心名称放在 host.json 文件中,作为 azure耐用功能 host.json settings

func durable delete-task-hub --task-hub-name TestHubName

使用此命令,您可以删除所有存储工件,包括Azure存储表,队列和斑点。与特定的任务中心相关联,

当我运行Azure耐用函数时,我从第一个结果中知道任务中心名称并传递到上述命令,它成功删除了:

​您可以清理存储帐户中存在的 taskHubs ,请参阅此 github票 cgillum 。

Could I use this command to delete taskhub in azure portal?

Azure Functions core Tools commands are used to run from your local IDE terminal or command prompt as mentioned in Microsoft Docs.

Could not find local host metadata file 'host.json' Unable to find project root. Expecting to find one of host.json, local.settings.json in project root.

You have to place your task hub name in the host.json file as the format specified in Azure Durable Functions Host.json settings.

func durable delete-task-hub --task-hub-name TestHubName

With this command, you can delete the all storage artifacts including Azure storage tables, queues, and blobs. associated with a particular task hub,

When I run my Azure Durable Function, I came to know the Task Hub Name from the 1st result and passed to the above command, it successfully deleted:

enter image description here

Cleanup taskhubs Programmatically:

Through code, you can clean up the taskhubs present in a storage account, refer to this GitHub Ticket for the code given by cgillum.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文