且构网

分享程序员开发的那些事...
且构网 - 分享程序员编程开发的那些事

Azure WebJobs:找不到跟踪日志记录

更新时间:2023-11-18 17:52:46

要为Web Job日志指定存储帐户,您需要在 CONFIGURE 选项卡> 连接字符串部分,连接字符串的名称必须为 AzureWebJobsDashboard .

To specify the storage account for Web Job logs, you need to add connection string under CONFIGURE tab > connection string sections, name of the connection string has to be AzureWebJobsDashboard.

应如下图所示:

  • 名称: AzureWebJobsDashboard
  • : DefaultEndpointsProtocol = https; AccountName ="; AccountKey ="
  • 类型:自定义
  • Name: AzureWebJobsDashboard
  • Value: DefaultEndpointsProtocol=https;AccountName="";AccountKey=""
  • Type: Custom

您还可以在Azure门户中查看日志,打开Web应用程序并选择 WEBJOBS 选项卡,单击Web作业的URL,它将显示上一次运行,单击 Toggle 按钮,其中显示了运行的详细信息,包括应用使用以下语句编写的自定义消息.

You can also view logs in Azure portal, open the Web app and select WEBJOBS tab, click on the URL of web job, it will show the last runs, click on Toggle button, which shown details of the run including the custom messages written by app using below statement.

Console.WriteLine("Error While Doing Something ...");