Lyo.Job.Alerts 2.0.1

dotnet add package Lyo.Job.Alerts --version 2.0.1
                    
NuGet\Install-Package Lyo.Job.Alerts -Version 2.0.1
                    
This command is intended to be used within the Package Manager Console in Visual Studio, as it uses the NuGet module's version of Install-Package.
<PackageReference Include="Lyo.Job.Alerts" Version="2.0.1" />
                    
For projects that support PackageReference, copy this XML node into the project file to reference the package.
<PackageVersion Include="Lyo.Job.Alerts" Version="2.0.1" />
                    
Directory.Packages.props
<PackageReference Include="Lyo.Job.Alerts" />
                    
Project file
For projects that support Central Package Management (CPM), copy this XML node into the solution Directory.Packages.props file to version the package.
paket add Lyo.Job.Alerts --version 2.0.1
                    
#r "nuget: Lyo.Job.Alerts, 2.0.1"
                    
#r directive can be used in F# Interactive and Polyglot Notebooks. Copy this into the interactive tool or source code of the script to reference the package.
#:package Lyo.Job.Alerts@2.0.1
                    
#:package directive can be used in C# file-based apps starting in .NET 10 preview 4. Copy this into a .cs file before any lines of code to reference the package.
#addin nuget:?package=Lyo.Job.Alerts&version=2.0.1
                    
Install as a Cake Addin
#tool nuget:?package=Lyo.Job.Alerts&version=2.0.1
                    
Install as a Cake Tool

Lyo.Job.Alerts

Hosted JobAlertConsumer that binds the job.notifications.alert routing key on the job.events exchange, deserializes JobAlertEvent payloads, and sends them through INotificationPublisher (in-process handlers) and/or an optional HTTP webhook.

Alert producers include JobService (SLA breaches), JobScheduler (failures, circuit breaker), and JobMaintenanceService (dead jobs, SLA scans) via IJobEventPublisher.PublishAlertAsync.

Examples

Register in DI

services.AddJobAlerts(configuration);

// Or inline options:
services.AddJobAlerts(o => {
    o.AlertWebhookUrl = "https://hooks.example.com/job-alerts";
});

Options (JobAlertsOptions.SectionName = "JobAlerts")

{
  "JobAlerts": {
    "AlertWebhookUrl": "https://hooks.example.com/job-alerts"
  }
}

Registration

IMqService must already be registered and connected. INotificationPublisher is optional. When it is missing, only the webhook path runs (if configured).

Options (JobAlertsOptions.SectionName = "JobAlerts")

Property Default Notes
AlertWebhookUrl null Each alert is POSTed as JSON to this URL when it is set.

JobAlertConsumer does not read per-definition AlertWebhookUrl on JobDefinition (that field is persisted for custom integrations). Alerts from this package leave through JobAlertsOptions.AlertWebhookUrl (or INotificationPublisher handlers).

Alert kinds (JobAlertType)

Type Usually produced by
Failure After consecutive failures the scheduler fires (AlertOnFailure)
CircuitBreakerTripped The scheduler turns the definition off
DeadJob Maintenance timeout (heartbeat missing)
SlaBreach SLA checks in JobService start/finish; maintenance SLA scan

JobAlertEvent payload

public sealed record JobAlertEvent(
    Guid DefinitionId,
    Guid? RunId,
    JobAlertType AlertType,
    string Message,
    DateTime Timestamp) : INotification;

When you use INotificationPublisher, implement INotificationHandler<JobAlertEvent> (or your app's notification pipeline).

How it flows

flowchart LR
    pub[JobService / Scheduler / Maintenance] --> ex[job.events]
    ex -->|job.notifications.alert| q[job.notifications.alert queue]
    q --> c[JobAlertConsumer]
    c --> n[INotificationPublisher]
    c --> w[HTTP webhook]

A transient dispatch failure requeues the message (HandleMessageAsync returns true).

Metrics

  • job.scheduler.circuit_breaker.tripped
  • job.sla.breach (Constants.Metrics.Sla.Breach)
  • job.maintenance.dead_jobs.failed

Dependencies

Generated from ProjectReference / PackageReference (same model as docs/Lyo.ProjectGraph.html).

  • Lyo.Common.Core (direct, lyo)
  • Lyo.Job.Models (direct, lyo)
  • Lyo.MessageQueue (direct, lyo)
  • Lyo.Metrics (direct, lyo)
  • Lyo.Notification (direct, lyo)
  • Microsoft.Extensions.Hosting.Abstractions 10.0.5 (direct, microsoft)
  • Microsoft.Extensions.Http 10.0.5 (direct, microsoft)
  • Microsoft.Extensions.Options.ConfigurationExtensions 10.0.5 (direct, microsoft)
  • Lyo.Api.Models (transitive, lyo)
  • Lyo.Common.Json (transitive, lyo)
  • Lyo.Common.Metadata (transitive, lyo)
  • Lyo.DateAndTime (transitive, lyo)
  • Lyo.Exceptions (transitive, lyo)
  • Lyo.Health (transitive, lyo)
  • Lyo.Parameters (transitive, lyo)
  • Lyo.Query.Models (transitive, lyo)
  • Lyo.Result (transitive, lyo)
  • Lyo.Schedule.Models (transitive, lyo)
  • Microsoft.Bcl.AsyncInterfaces 10.0.5 (transitive, microsoft, netstandard2.0)
  • Microsoft.Extensions.DependencyInjection 10.0.5 (transitive, microsoft)
  • Microsoft.Extensions.Logging.Abstractions 10.0.5 (transitive, microsoft)
  • System.Diagnostics.DiagnosticSource 10.0.5 (transitive, microsoft, netstandard2.0)
  • System.Memory 4.6.3 (transitive, microsoft, netstandard2.0)
  • System.Text.Json 10.0.5 (transitive, microsoft, netstandard2.0)
Product Compatible and additional computed target framework versions.
.NET net10.0 is compatible.  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. 
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.

NuGet packages

This package is not used by any NuGet packages.

GitHub repositories

This package is not used by any popular GitHub repositories.

Version Downloads Last Updated
2.0.1 84 9/14/2026
2.0.0 85 9/9/2026
1.0.13 102 8/25/2026
1.0.11 100 8/23/2026
1.0.9 109 8/22/2026
1.0.6 97 8/20/2026
1.0.4 114 8/20/2026
1.0.3 88 8/19/2026
1.0.2 104 8/19/2026
1.0.1 106 8/18/2026
1.0.0 113 8/16/2026