docs(health): align shared-contract to shipped API + per-lib CLAUDE.md + cleanup
- Contract: DatabaseHealthCheck<TContext> ctor now shows IServiceProvider (resolves IDbContextFactory<TContext> when registered, else a scoped TContext; pool-safe) - Contract: RequireActiveNode gains retryAfterSeconds = 5 default parameter - Packages: remove dangling AspNetCore.HealthChecks.UI.Client PackageVersion (no csproj referenced it) - Tests: fix CS8625 in RoleLessCases — use object?[] so null role rows compile warning-free under Nullable=enable - Add ZB.MOM.WW.Health/CLAUDE.md (packages, responsibilities, consumer matrix, build/test/pack commands, status + pointer to components/health/)
This commit is contained in:
@@ -91,7 +91,8 @@ public interface IActiveNodeGate
|
||||
public static class ActiveNodeGateExtensions
|
||||
{
|
||||
public static IEndpointConventionBuilder RequireActiveNode(
|
||||
this IEndpointConventionBuilder builder);
|
||||
this IEndpointConventionBuilder builder,
|
||||
int retryAfterSeconds = 5);
|
||||
}
|
||||
|
||||
/// Checks that a downstream gRPC channel is reachable.
|
||||
@@ -221,8 +222,9 @@ namespace ZB.MOM.WW.Health.EntityFrameworkCore;
|
||||
public sealed class DatabaseHealthCheck<TContext> : IHealthCheck
|
||||
where TContext : DbContext
|
||||
{
|
||||
// Resolves IDbContextFactory<TContext> when registered, else a scoped TContext; pool-safe.
|
||||
public DatabaseHealthCheck(
|
||||
IDbContextFactory<TContext> factory,
|
||||
IServiceProvider serviceProvider,
|
||||
DatabaseHealthCheckOptions<TContext>? options = null);
|
||||
|
||||
public Task<HealthCheckResult> CheckHealthAsync(
|
||||
|
||||
Reference in New Issue
Block a user