I have installed the NuGet package Micorosft.Azure.WebJobs.ServiceBus, version 1.0.1 (March 19, 2015). My WebJob is perfectly triggered for a new message on the servicebus queue:
public static Task ProcessQueueMessage([ServiceBusTrigger("outbound")] BrokeredMessage message, TextWriter log)
I updated the NuGet package with version 1.1.0 (November 19, 2015). Now, this trigger method is not recognized anymore:
No job functions found. Try making your job classes and methods public. 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.).
Does anyone else experience this problem?
Found the answer here. Previously, you would start your webjob like this:
static void Main()
{
var host = new JobHost();
host.RunAndBlock();
}
Now, you must configure the JobHost more specifically:
static void Main()
{
var config = new JobHostConfiguration();
config.UseServiceBus();
var host = new JobHost(config);
host.RunAndBlock();
}