azure-webjobs

Azure WebJobs: Queue triggers with different batch sizes

陌路散爱 提交于 2019-12-11 07:04:54
问题 I have a WebJob on azure that processes messages from multiple queues at the same time: public async static Task ProcessQueueMessage1([QueueTrigger("queue1")] string message) { switch (message.Substring(message.Length - 3, 3)) { case "tze": await Parser.Process1(message); break; default: break; } } public async static Task ProcessQueueMessage2([QueueTrigger("queue2")] string message) { switch (message.Substring(message.Length - 3, 3)) { case "tzr": await Parser.Process2(message); break;

Azure function returns error: No job functions found. Try making your job classes and methods public

自作多情 提交于 2019-12-11 06:51:39
问题 I have created an Azure Function application in Visual Studio 2017 and can publish it to Azure without any issues using the Visual Studio publish functionality (right click project then select Publish). As deploying from a developers instance of Visual Studio isn't an ideal continuous integration strategy, I have created a deployment pipeline with TeamCity and Octopus where TeamCity builds the Azure function application and Octopus uses the WAWSDeploy application to deploy the Azure Function

ResetPasswordAsync returns 'Invalid Token' when token is generated inside a WebJob

烂漫一生 提交于 2019-12-11 06:47:23
问题 I have a scheduled WebJob that runs on daily basis and checks the password expiry date for all users in my database. If the password expiry date is today, it will generate a password reset token and send it to the user via email. Then user clicks the url in the email and is brought to a website, where they input the new password. I managed to generate a token in my WebJob and send it over via email. However, when resetting the password through my Asp.NET Website I get Invalid Token . I cannot

Azure WebJob File Storage activity trigger alternative

99封情书 提交于 2019-12-11 06:07:13
问题 I read this question and answer but it doesn't solve my problem. What would be the best way of solving the following scenario. I have a file storage which receives files from an external app. I need to process those files as soon as they arrive. This is currently achieved through an Azure Web Job This is a change request to a solution (Web Job) which is already working based on a TimerTrigger. Basically it's executed every N minutes. Since I can't change the external program which puts files

DI with ILogger in Azure webJob

痴心易碎 提交于 2019-12-11 05:49:45
问题 I have an azure webjob project created in .net framework 4.6. i am trying to implement dependency injection with ILogger and log the information in application insights. class Program { private static IConfigurationRoot configuration; // Please set the following connection strings in app.config for this WebJob to run: // AzureWebJobsDashboard and AzureWebJobsStorage public static void Main() { var config = new JobHostConfiguration(); if (config.IsDevelopment) { config.UseDevelopmentSettings()

Azure WebJob removed after App Service publish with Autoswap

守給你的承諾、 提交于 2019-12-11 05:26:40
问题 We have an Asp.Net Core Azure App Service. We have added one deployment slot, to which we deploy. This slow has Autoswap enabled. When we deploy a new version .Net Core Console app WebJob we have added in production, it is removed. The question is, when will it be possible to publish a WebJob alongside an Asp.Net Core project. 回答1: As stated ins this SO answer, a Web job is part of the App service content. So when switching from one slot to another, you are switching the whole App Service

Nightmare.js does not work with Azure webjob

五迷三道 提交于 2019-12-11 05:09:52
问题 I am trying to run an azure webjob which takes a json object and renders a webpage, then prints it to pdf, via the electron browser in Nightmare.js. When I run this locally it works perfectly, but when I run it in azure webjob it never completes. I get the two console.log statements output to the log, but seeing as I can not output anything from the nightmare.js calls, nor display the electron browser window, I have no idea what is going wrong. There is also a webserver in the script, omitted

Want Azure webjobs to maintain running state (Running or Stopped) following publishing of web app

穿精又带淫゛_ 提交于 2019-12-11 04:56:22
问题 I'm deploying a web application and various associated (continuous) webjobs to Azure using Visual Studio 2015. Until very recently my observation was that following the deployment process the webjobs would maintain their state; if the job was running, it would be restarted if the code was changed. If the job was Stopped, the code would update and the webjob would remain in the Stopped state. The behavior I'm seeing now now is that the Stopped webjobs are starting following deployment. This is

How to receive data from App Settings Azure (webapp) to my webjob

孤街醉人 提交于 2019-12-11 04:45:13
问题 I have made an Azure WebJob in c#. I have a web app on Azure, I added my WebJob to my subscription, all good works but in Application Settings I add a new entry, an example: <add key="MyDesiredKey" value="1234" /> How can I get value of my key into my application when that runs on azure? I try like this but not working, in this case no need to have that key in my web config no? When webjob run need to get value from Appsettings from my webapp stored on Azure var keyFromAzureApp =

Limit number of instances of a *standard* azure webjob when scaling out

有些话、适合烂在心里 提交于 2019-12-11 04:43:50
问题 Very similar to (but not a duplicate of!) this question: Limit number of instances of an azure webjob when scaling out I would like to be able to limit the number of instances of a webjob within our standard webapp. I am aware of the possibility of having a singleton instance but would like to be able to limit this to a number other than 1. Is such a thing possible? If not, are there any sensbile workarounds for the type of scenario described in q. 45067648 for those of us running on the