Quartz.Extensions.Hosting 3.9.0

Quartz.Extensions.Hosting provides integration with hosted services.

Quartz 3.2 or later required for Quartz.Extensions.Hosting. You can use package Quartz.AspNetCore with version 3.1.

Installation

You need to add NuGet package reference to your project which uses Quartz.

Quartz 3.1

Install-Package Quartz.AspNetCore 

Quartz 3.2 onwards

Install-Package Quartz.Extensions.Hosting

Using

You can add Quartz configuration by invoking an extension method AddQuartzHostedService on IServiceCollection. This will add a hosted quartz server into process that will be started and stopped based on applications lifetime.

See Quartz.Extensions.DependencyInjection documentation to learn more about configuring Quartz scheduler, jobs and triggers.

Example program utilizing hosted services configuration

public class Program
{
    public static void Main(string[] args)
    {
        Log.Logger = new LoggerConfiguration()
            .Enrich.FromLogContext()
            .WriteTo.Console()
            .CreateLogger();
        
        CreateHostBuilder(args).Build().Run();
    }

    public static IHostBuilder CreateHostBuilder(string[] args) =>
        Host.CreateDefaultBuilder(args)
            .UseSerilog()
            .ConfigureServices((hostContext, services) =>
            {
                // see Quartz.Extensions.DependencyInjection documentation about how to configure different configuration aspects
                services.AddQuartz(q =>
                {
                    // your configuration here
                });

                // Quartz.Extensions.Hosting hosting
                services.AddQuartzHostedService(options =>
                {
                    // when shutting down we want jobs to complete gracefully
                    options.WaitForJobsToComplete = true;
                });
            });
}

Showing the top 20 packages that depend on Quartz.Extensions.Hosting.

Packages Downloads
Elsa.Activities.Timers
Elsa is a set of workflow libraries and tools that enable lean and mean workflowing capabilities in any .NET Core application. This package provides the following Timer activities: * CronEvent * InstantEvent * TimerEvent
4
Quartz.AspNetCore
Quartz.NET ASP.NET Core integration; Quartz Scheduling Framework for .NET
3
Quartz.AspNetCore
Quartz.NET ASP.NET Core integration; Quartz Scheduling Framework for .NET
4
Quartz.AspNetCore
Quartz.NET ASP.NET Core integration; Quartz Scheduling Framework for .NET
5
Quartz.AspNetCore
Quartz.NET ASP.NET Core integration; Quartz Scheduling Framework for .NET
7
Quartz.AspNetCore
Quartz.NET ASP.NET Core integration; Quartz Scheduling Framework for .NET
8
Quartz.AspNetCore
Quartz.NET ASP.NET Core integration; Quartz Scheduling Framework for .NET
9

https://github.com/quartznet/quartznet/releases

Version Downloads Last updated
3.9.0 1 05/27/2024
3.8.1 4 05/06/2024
3.8.0 3 05/10/2024
3.7.0 3 05/19/2024
3.6.3 4 05/06/2024
3.6.2 4 06/11/2023
3.6.1 3 05/06/2024
3.6.0 4 05/06/2024
3.5.0 4 05/27/2024
3.4.0 5 07/05/2022
3.3.3 6 07/12/2022
3.3.2 3 06/11/2023
3.3.1 2 05/27/2024
3.3.0 2 05/27/2024
3.2.4 3 06/11/2023
3.2.3 5 06/11/2023
3.2.2 6 06/11/2023
3.2.1 4 05/27/2024
3.2.0 7 06/11/2023
1.0.0 4 05/06/2024