DotNetDiag.HealthChecks.IbmDb2 10.0.10

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

IBM Db2 Health Check

This health check verifies that an IBM Db2 database can be reached and can execute a lightweight query.

Defaults

By default, the health check opens a Db2 connection and executes SELECT 1 FROM SYSIBM.SYSDUMMY1.

void Configure(IHealthChecksBuilder builder)
{
    builder.AddIbmDb2("Server=db2.example.com:50000;Database=testdb;UID=db2inst1;PWD=password;");
}

Custom query and connection configuration

Use a custom query or configure the DB2Connection before it opens when your environment needs provider-specific settings.

void Configure(IHealthChecksBuilder builder)
{
    builder.AddIbmDb2(
        "Server=db2.example.com:50000;Database=testdb;UID=db2inst1;PWD=password;",
        healthQuery: "SELECT CURRENT DATE FROM SYSIBM.SYSDUMMY1",
        configure: connection =>
        {
            // Adjust DB2Connection settings here before the connection opens.
        });
}

Platform-specific IBM provider packages

IBM ships the Db2 .NET provider as platform-specific NuGet packages. This health check targets .NET 8 and .NET 10 and references the Linux AMD64 provider package used by the repository CI. Applications running on other platforms should follow IBM's package guidance for the matching provider package.

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 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 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
10.0.10 0 7/7/2026