GraphHealthChecks 4.0.1

dotnet add package GraphHealthChecks --version 4.0.1
                    
NuGet\Install-Package GraphHealthChecks -Version 4.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="GraphHealthChecks" Version="4.0.1" />
                    
For projects that support PackageReference, copy this XML node into the project file to reference the package.
<PackageVersion Include="GraphHealthChecks" Version="4.0.1" />
                    
Directory.Packages.props
<PackageReference Include="GraphHealthChecks" />
                    
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 GraphHealthChecks --version 4.0.1
                    
#r "nuget: GraphHealthChecks, 4.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 GraphHealthChecks@4.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=GraphHealthChecks&version=4.0.1
                    
Install as a Cake Addin
#tool nuget:?package=GraphHealthChecks&version=4.0.1
                    
Install as a Cake Tool

GraphHealthChecks

Graph Health Checks for HotChocolate.

The purpose of this middleware is to provide feedback regarding the health of the schema.

Nuget

Compatibility

Current Releases

HotChocolate Version GraphHealthChecks Version .NET Version
15.0.3 or higher 4.0.1 .NET 8, 9
15.0.3 or higher 4.0.0 .NET 8, 9
14.3.0 or higher 3.3.0 .NET 8, 9
14.2.0 or higher 3.2.0 .NET 8, 9
14.1.0 or higher 3.1.0 .NET 8, 9
14.0.0 or higher 3.0.0 .NET 8

Past Releases

HotChocolate Version Last GraphHealthChecks Version .NET Version
13.7.0 or higher 2.0.1 .NET 6, 8
13.3.3 or higher 1.0.2 .NET 6, 7

📝For more information please visit https://www.nuget.org/packages/GraphHealthChecks/#versions-body-tab

Note

There appears to be a compatibility issue for projects targeting .NET 7 and assembly Assembly Microsoft.Extensions.Hosting, Version=7.0.0.0 and more specifically OptionsBuilderExtensions.ValidateOnStart resulting in error:

The call is ambiguous between the following methods or properties:

Microsoft.Extensions.DependencyInjection.OptionsBuilderExtensions.ValidateOnStart<TOptions>(Microsoft.Extensions.Options.OptionsBuilder<TOptions>)

Until resolved please consider using a version of the package targeting .NET 7.

Usage

Locate the services registration and append one of:

  • .AddGraphHealthWithNoLogger - use when no logging is required
  • .AddGraphHealthWithILogger - use when the ILogger provider is available
  • .AddGraphHealthWithILoggerFactory - use when the ILoggerFactory provider is available

⚠️ Bear in mind that IHealthChecksBuilder needs to be appended before any of the aforementioned.

ex.

// Startup.cs
public void ConfigureServices(IServiceCollection services)
{
    // ...
    services
        .AddHealthChecks()
        .AddGraphHealthWithILogger();
    // ...
}

📝 If further customization is required, consider wiring up any of the factories manually or use the GraphHealthCheck class itself as required.

If separate schemas are present, multiple registrations can be done for each schema.

ex.

// Startup.cs
public void ConfigureServices(IServiceCollection services)
{
    // ...
    services
        .AddHealthChecks()
        .AddGraphHealthWithILogger(healthName: "health1", schemaName: "schema1")
        .AddGraphHealthWithILogger(healthName: "health2", schemaName: "schema2");
    // ...
}
Product 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 is compatible.  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. 
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
4.0.1 3,608 2/19/2025
4.0.0 1,015 2/7/2025
3.3.0 1,136 12/25/2024
3.2.0 499 12/4/2024
3.1.0 325 11/16/2024
3.0.0 620 10/16/2024
2.0.1 20,382 11/22/2023
2.0.0 155 11/21/2023
1.1.0 6,099 8/26/2023
1.0.2 1,691 7/31/2023
1.0.1 4,758 5/29/2023
1.0.0 2,095 5/8/2023