azure-webjobs

Azure WebJobs, catch error to prevent host failure

吃可爱长大的小学妹 提交于 2020-03-05 04:08:10
问题 Assume a simple HostBuilder configuration as described here. Just like that: static async Task Main() { var builder = new HostBuilder(); builder.ConfigureWebJobs(b => b .AddAzureStorageCoreServices() .AddAzureStorage() .AddTimers()) var host = builder.Build(); using (host) { await host.RunAsync(); } } There seem to be some situations where Exceptions can happen, not inside the QueueTrigger or TimerTrigger functions directly (these are catched gracefully), but on a global scope. Some of them I

Stopping Locked On-Demand/Triggered Azure Webjob

会有一股神秘感。 提交于 2020-02-05 14:01:51
问题 I have a "Triggered" Webjob in Azure that is stuck on "Running" It has been in this state for two days, it is scheduled to run every 5 minutes. This Webjob has previously worked without any problem. This problem seems to have occurred on a Saturday (my timezone), which means that no one was playing with it when it broke. What I have tried so far: Restarting the site the Webjob is attached to. Running the job manually from the azure portal* Redeploying the site Setting WEBJOBS_STOPPED=1 in App

In Azure, can I call a Python script from my C# WebJob?

雨燕双飞 提交于 2020-01-24 20:31:05
问题 I want to create a WebJob in C#. Unfortunately, I need to use a Python 3 script as there is currently no suitable library for 1 particular task that I need to perform, using C#. For example, see this answer/example. Is it possible to have my WebJob call a Python script? I can place the Python3 script in a blob container - would I then be able to call and execute it from my C# WebJob? 回答1: Sure, it's possible to call a Python 3 script via C# WebJob that follow the sample you linked. First of

Azure webjob logs - looking for logs that detail the SDK's handling of queue triggered items

元气小坏坏 提交于 2020-01-24 20:11:29
问题 As shown in my Stack Overflow question Azure webjob not appearing to respect MaxDequeueCount property, I'm troubleshooting a problem where despite my setting of the MaxDequeueCount property to 1, some items are dequeued many times before they're poisoned (in fact some items may never be poisoned at all and just dequeue, fail and are retried and fail endlessly). The Webjobs SDK handles the retries and poisoning of queue triggered messages automatically and I'm looking for logs that contain

Azure webjob logs - looking for logs that detail the SDK's handling of queue triggered items

北城以北 提交于 2020-01-24 20:11:26
问题 As shown in my Stack Overflow question Azure webjob not appearing to respect MaxDequeueCount property, I'm troubleshooting a problem where despite my setting of the MaxDequeueCount property to 1, some items are dequeued many times before they're poisoned (in fact some items may never be poisoned at all and just dequeue, fail and are retried and fail endlessly). The Webjobs SDK handles the retries and poisoning of queue triggered messages automatically and I'm looking for logs that contain

Use a client certificate in a WebJob

十年热恋 提交于 2020-01-23 09:48:13
问题 I have a web job running on an Azure web app. I web job needs to access a client certificate for outbound traffic encryption. How can I access a client certificate from an Azure web job? I tried installing the certificate on the host web app and access the certificate this way: private static X509Certificate2 LoadCertificateFromStore(string certificateThumbprint){ var store = new X509Store(StoreLocation.CurrentUser); try { store.Open(OpenFlags.ReadOnly); var certCollection = store

Use a client certificate in a WebJob

↘锁芯ラ 提交于 2020-01-23 09:48:05
问题 I have a web job running on an Azure web app. I web job needs to access a client certificate for outbound traffic encryption. How can I access a client certificate from an Azure web job? I tried installing the certificate on the host web app and access the certificate this way: private static X509Certificate2 LoadCertificateFromStore(string certificateThumbprint){ var store = new X509Store(StoreLocation.CurrentUser); try { store.Open(OpenFlags.ReadOnly); var certCollection = store

Error Creating Webjob schedule

眉间皱痕 提交于 2020-01-21 04:43:06
问题 I have the source code hosted in a TFS 2012 on premise installation. When I try to publish my Azure WebJob to Azure from Visual Studio 2015, I get the following error. Error : An error occurred while creating the WebJob schedule: Response status code does not indicate success: 409 (Conflict). The WebJob does get created under the web application, but it is set to On Demand rather than scheduled. When I open Fiddler to try to troubleshoot this issue, I get the following error. Error ERROR

Azure Web Jobs suddenly stopped working properly

一世执手 提交于 2020-01-16 19:34:22
问题 I wrote a program named "blobsUploader" that uploads a csv file to a blob container every night at 11pm. Whenever a new csv file arrives to the blobs container, a new message in a queue named "blobsAdressQueue" appears with the address of the new blob (csv file). This evokes the Web Job which reads the csv file and stores all it's data in Azure Table named "myDataTable". The whole process worked great but suddenly from the past month or two, every night when a new csv is uploaded, there is an

Azure Web Jobs suddenly stopped working properly

主宰稳场 提交于 2020-01-16 19:34:06
问题 I wrote a program named "blobsUploader" that uploads a csv file to a blob container every night at 11pm. Whenever a new csv file arrives to the blobs container, a new message in a queue named "blobsAdressQueue" appears with the address of the new blob (csv file). This evokes the Web Job which reads the csv file and stores all it's data in Azure Table named "myDataTable". The whole process worked great but suddenly from the past month or two, every night when a new csv is uploaded, there is an