No job functions found. try making your job classes and methods public. if you’re using binding extensions (e.g. azure storage, servicebus, timers, etc.) make sure you’ve called the registration method for the extension(s) in your startup code (e.g. builder.addazurestorage(), builder.addservicebus(), builder.addtimers(), etc.).

When encountering the error message “No job functions found,” it means that the Azure Functions runtime could not find any functions to execute in your code. This error usually occurs when the job classes and methods are not declared as public.

To resolve this issue, make sure that your job classes and methods have the public access modifier. This allows the Azure Functions runtime to discover and execute the functions properly.

Here’s an example of a public job class and method in C#:


public class MyJobClass
{
    [FunctionName("MyJobFunction")]
    public static void Run([TimerTrigger("0 */5 * * * *")] TimerInfo myTimer)
    {
        // Function logic goes here
        Console.WriteLine("My job function is running...");
    }
}
  

In this example, the MyJobFunction method is marked with the [FunctionName("MyJobFunction")] attribute and is declared as public. The TimerTrigger attribute specifies that the function will be triggered every 5 minutes.

Additionally, if you’re using binding extensions like Azure Storage, ServiceBus, Timers, etc., make sure you’ve called the registration method for the extension(s) in your startup code. For example, to add Azure Storage binding extension, you can use the builder.AddAzureStorage() method in your startup code.

Related Post

Leave a comment