JGUZDV.JobHost
1.0.2
See the version list below for details.
dotnet add package JGUZDV.JobHost --version 1.0.2
NuGet\Install-Package JGUZDV.JobHost -Version 1.0.2
<PackageReference Include="JGUZDV.JobHost" Version="1.0.2" />
<PackageVersion Include="JGUZDV.JobHost" Version="1.0.2" />
<PackageReference Include="JGUZDV.JobHost" />
paket add JGUZDV.JobHost --version 1.0.2
#r "nuget: JGUZDV.JobHost, 1.0.2"
#:package JGUZDV.JobHost@1.0.2
#addin nuget:?package=JGUZDV.JobHost&version=1.0.2
#tool nuget:?package=JGUZDV.JobHost&version=1.0.2
JGUZDV.JobHost
JGUZDV.JobHost is a .NET package designed to simplify the creation of background jobs in a Windows service using the IHostBuilder and Quartz.net. You can easily register jobs with a cron schedule, and they will be executed in the background as part of a Windows service.
Configuration
You can configure your schedules in the appsettings.json. The default sectionName is "HostedJobs"
{
"HostedJobs": {
"MyJob": "* * * * * ?",
"MyJob2": "* 0/5 * * * ?",
"MyJob3": "false" //this prevents the job from being registered e.g. for appsettings.development.json
}
}
Usage
Your jobs must implement the IJob interface from Quartz.net. To use JGUZDV.JobHost, you can create an IHostBuilder and register jobs with a cron schedule. The jobs will be executed in the background as part of a Windows service.
Here's a basic example:
using Microsoft.Extensions.DependencyInjection;
using JGUZDV.JobHost;
class Program
{
static void Main(string[] args)
{
var host = JobHost.CreateJobHostBuilder(args, configureWindowsService, quartzHostedServiceOptions)
.AddHostedJob<MyJob>() // with the configuration above the job runs every second
.AddHostedJob<MyJob2>() // with the configuration above the job runs every 5 minutes (at 0, 5, 10, 15.... etc Minutes)
.Build();
_ = host.RunAsync();
}
}
| Product | Versions Compatible and additional computed target framework versions. |
|---|---|
| .NET | net8.0 is compatible. net8.0-android was computed. net8.0-browser was computed. net8.0-ios was computed. net8.0-maccatalyst was computed. net8.0-macos was computed. net8.0-tvos was computed. net8.0-windows was computed. net9.0 was computed. net9.0-android was computed. net9.0-browser was computed. net9.0-ios was computed. net9.0-maccatalyst was computed. net9.0-macos was computed. net9.0-tvos was computed. net9.0-windows was computed. net10.0 was computed. net10.0-android was computed. net10.0-browser was computed. net10.0-ios was computed. net10.0-maccatalyst was computed. net10.0-macos was computed. net10.0-tvos was computed. net10.0-windows was computed. |
-
net8.0
- JGUZDV.Extensions.Logging (>= 1.0.2)
- Microsoft.Extensions.Hosting (>= 8.0.0)
- Microsoft.Extensions.Hosting.WindowsServices (>= 8.0.0)
- Quartz.Extensions.Hosting (>= 3.8.0)
NuGet packages (1)
Showing the top 1 NuGet packages that depend on JGUZDV.JobHost:
| Package | Downloads |
|---|---|
|
JGUZDV.JobHost.Dashboard.EntityFrameworkCore
Database of Dashboard for JGUZDV.JobHost package. |
GitHub repositories
This package is not used by any popular GitHub repositories.
| Version | Downloads | Last Updated | |
|---|---|---|---|
| 1.7.2 | 43 | 11/20/2026 | |
| 1.7.1 | 104 | 11/12/2026 | |
| 1.7.0 | 100 | 11/12/2026 | |
| 1.6.0 | 108 | 11/5/2026 | |
| 1.5.0 | 100 | 11/5/2026 | |
| 1.4.0 | 109 | 11/3/2026 | |
| 1.3.1 | 108 | 11/3/2026 | |
| 1.3.0 | 214 | 2/2/2026 | |
| 1.2.4 | 241 | 10/8/2025 | |
| 1.2.2 | 283 | 4/9/2025 | |
| 1.2.1 | 239 | 3/31/2025 | |
| 1.2.0 | 239 | 3/31/2025 | |
| 1.1.12 | 558 | 3/26/2025 | |
| 1.1.11 | 274 | 4/18/2024 | |
| 1.0.3 | 215 | 4/16/2024 | |
| 1.0.2 | 260 | 2/7/2024 | |
| 1.0.1 | 210 | 2/6/2024 | |
| 1.0.0 | 214 | 2/1/2024 |