Conversation
…ecks - Implement AuthTelemetry for tracking authentication failures and missing tenant claims. - Create CacheTelemetry to monitor output cache invalidations and outcomes. - Introduce ConflictTelemetry for recording concurrency and domain conflicts. - Add HealthCheckMetricsPublisher to publish health check results as metrics. - Develop HttpRouteResolver to resolve normalized route templates for HTTP requests. - Enhance ObservabilityConventions with shared names and tags for metrics. - Implement StartupTelemetry to track startup phase activities and failures. - Create ValidationTelemetry for recording validation failures in MVC actions. - Add RabbitMqHealthCheck to verify RabbitMQ broker connectivity. - Update project files to include internals visibility for testing. - Add unit tests for new observability features and health checks. - Remove obsolete ErrorOrValidationMiddlewareTests.
…olution - Introduced `DesignTimeConnectionStringResolver` to resolve connection strings for design-time DbContext creation. - Added `DesignTimeDbContextDefaults` to provide null-object collaborators for EF Core design-time factories. - Refactored `SoftDeleteProcessor` to streamline soft delete operations with a context object. - Updated `TenantAuditableDbContext` to utilize a new `TenantAuditableDbContextDependencies` record for better dependency management. - Enhanced logging capabilities with new tests for API exception handling and log data classifications. - Implemented batch command handler tests for category and product features to ensure robust validation and persistence logic. - Improved output cache behavior tests to validate stable responses on repeated reads. - Added redaction configuration tests to verify HMAC key resolution logic.
There was a problem hiding this comment.
Pull request overview
This PR expands the shared “observability + infrastructure” surface across services by introducing standardized telemetry/logging/redaction primitives, health checks, and EF Core design-time helpers, plus refactors to batch validation and persistence scaffolding.
Changes:
- Add shared OpenTelemetry conventions/facades (auth/cache/conflict/validation/startup) and request-context middleware + Serilog enrichers/redaction support.
- Add shared health-check conventions/registrations, including new RabbitMQ and MongoDB health checks and health-check → metric publishing.
- Refactor EF Core DbContext dependency wiring (new
TenantAuditableDbContextDependencies) and streamline batch validation handlers/tests.
Reviewed changes
Copilot reviewed 120 out of 120 changed files in this pull request and generated 4 comments.
Show a summary per file
| File | Description |
|---|---|
| tests/SharedKernel.Tests/Observability/TelemetryApiSurfaceResolverTests.cs | Adds tests for request-path → API surface classification. |
| tests/SharedKernel.Tests/Observability/StartupTelemetryTests.cs | Verifies startup migration telemetry tagging on failures. |
| tests/SharedKernel.Tests/Observability/RabbitMqHealthCheckTests.cs | Tests RabbitMQ connection string resolution + health failure path. |
| tests/SharedKernel.Tests/Observability/ObservabilityExtensionsTests.cs | Tests OTLP endpoint selection, resource attributes, and default options behavior. |
| tests/SharedKernel.Tests/Observability/HttpRouteResolverTests.cs | Adds tests for route template resolution and version token replacement. |
| tests/SharedKernel.Tests/Observability/HealthChecksServiceCollectionExtensionsTests.cs | Tests shared health check registration behaviors. |
| tests/SharedKernel.Tests/Observability/HealthCheckMetricsPublisherTests.cs | Tests health-check publisher status snapshot behavior. |
| tests/SharedKernel.Tests/Observability/CacheTelemetryTests.cs | Tests cache invalidation activity tags. |
| tests/SharedKernel.Tests/Middleware/RequestContextMiddlewareTests.cs | Adds tests for correlation/trace headers and metrics tags. |
| tests/SharedKernel.Tests/Middleware/ErrorOrValidationMiddlewareTests.cs | Removes tests for deleted Wolverine validation middleware. |
| tests/SharedKernel.Tests/Logging/RedactionConfigurationTests.cs | Adds tests for HMAC key resolution + DI registration. |
| tests/SharedKernel.Tests/Logging/LogDataClassificationsTests.cs | Tests classification attributes mapping to expected taxonomy. |
| tests/SharedKernel.Tests/Logging/ApiExceptionHandlerLogsTests.cs | Tests logger-message templates and parameter classifications. |
| tests/SharedKernel.Tests/Logging/ActivityTraceEnricherTests.cs | Tests Serilog enricher adds TraceId/SpanId from Activity. |
| tests/ProductCatalog.Tests/Health/MongoDbHealthCheckTests.cs | Tests MongoDB health check healthy/unhealthy outcomes. |
| tests/ProductCatalog.Tests/Features/Product/Commands/ProductBatchCommandHandlerTests.cs | Adds batch handler tests for product create/update validation/persistence/link syncing. |
| tests/ProductCatalog.Tests/Features/Category/Commands/CategoryBatchCommandHandlerTests.cs | Adds batch handler tests for category create/update validation/persistence. |
| tests/Integration.Tests/Infrastructure/ServiceStartupSmokeTests.cs | Improves health assertion diagnostics by including response body/service name. |
| tests/Integration.Tests/Infrastructure/OutputCacheBehaviorTests.cs | Updates output-cache tests to assert stable repeated responses (vs. Age). |
| tests/Integration.Tests/Factories/ServiceFactoryBase.cs | Broadens external health-check removal to match “mongo” variations. |
| tests/Identity.Tests/Logging/IdentitySecurityLogsTests.cs | Adds reflection-based tests ensuring logging parameter classifications. |
| src/SharedKernel/SharedKernel.Messaging/SharedKernel.Messaging.csproj | Enables InternalsVisibleTo for tests and adds framework reference. |
| src/SharedKernel/SharedKernel.Messaging/HealthChecks/RabbitMqHealthCheck.cs | Implements RabbitMQ broker reachability health check. |
| src/SharedKernel/SharedKernel.Messaging/Conventions/RabbitMqConventionExtensions.cs | Extracts connection string resolution helper (internal) and reuses it. |
| src/SharedKernel/SharedKernel.Infrastructure/SharedKernel.Infrastructure.csproj | Adds test visibility, framework reference, and logging/redaction package dependencies. |
| src/SharedKernel/SharedKernel.Infrastructure/Repositories/RepositoryBase.cs | Removes outdated comments above write-method overrides. |
| src/SharedKernel/SharedKernel.Infrastructure/Persistence/TenantAuditableDbContextDependencies.cs | Adds record to group DbContext collaborators for DI/design-time usage. |
| src/SharedKernel/SharedKernel.Infrastructure/Persistence/TenantAuditableDbContext.cs | Refactors DbContext ctor to take dependency record and uses it internally. |
| src/SharedKernel/SharedKernel.Infrastructure/Persistence/SoftDelete/SoftDeleteProcessor.cs | Refactors soft-delete recursion to use an operation context record. |
| src/SharedKernel/SharedKernel.Infrastructure/Persistence/DesignTimeDbContextDefaults.cs | Adds null-object defaults for design-time DbContext creation. |
| src/SharedKernel/SharedKernel.Infrastructure/Persistence/DesignTimeConnectionStringResolver.cs | Adds design-time connection string resolution from appsettings/env/CLI args. |
| src/SharedKernel/SharedKernel.Infrastructure/Observability/ValidationTelemetry.cs | Implements IValidationMetrics for validation-related counters. |
| src/SharedKernel/SharedKernel.Infrastructure/Observability/TelemetryApiSurfaceResolver.cs | Adds API surface classification helper based on path prefixes. |
| src/SharedKernel/SharedKernel.Infrastructure/Observability/StartupTelemetry.cs | Adds startup-step activity helper (migration telemetry). |
| src/SharedKernel/SharedKernel.Infrastructure/Observability/ObservabilityConventions.cs | Introduces canonical activity/meter names, tags, metrics, and constants. |
| src/SharedKernel/SharedKernel.Infrastructure/Observability/HttpRouteResolver.cs | Adds normalized route resolver for traces/tags (incl. API version token replacement). |
| src/SharedKernel/SharedKernel.Infrastructure/Observability/HealthCheckMetricsPublisher.cs | Publishes health-check results via observable gauge. |
| src/SharedKernel/SharedKernel.Infrastructure/Observability/HealthCheckConventions.cs | Adds shared health check names and tag categories. |
| src/SharedKernel/SharedKernel.Infrastructure/Observability/ConflictTelemetry.cs | Adds conflict/concurrency counters for exception handling. |
| src/SharedKernel/SharedKernel.Infrastructure/Observability/CacheTelemetry.cs | Adds output-cache metrics + invalidation activity helpers. |
| src/SharedKernel/SharedKernel.Infrastructure/Observability/AuthTelemetry.cs | Adds auth-failure metrics + activity creation with tags. |
| src/SharedKernel/SharedKernel.Infrastructure/Logging/RedactionConfiguration.cs | Adds HMAC key resolution logic (env var preferred). |
| src/SharedKernel/SharedKernel.Infrastructure/Logging/LogDataClassifications.cs | Adds compliance taxonomy + classification attributes. |
| src/SharedKernel/SharedKernel.Infrastructure/Logging/ActivityTraceEnricher.cs | Adds Serilog enricher to include W3C TraceId/SpanId in logs. |
| src/SharedKernel/SharedKernel.Application/Options/Security/RedactionOptions.cs | Adds options model for redaction configuration. |
| src/SharedKernel/SharedKernel.Application/Options/ObservabilityOptions.cs | Adds options model for exporter toggles and endpoints. |
| src/SharedKernel/SharedKernel.Application/Middleware/ErrorOrValidationMiddleware.cs | Removes Wolverine FluentValidation middleware implementation. |
| src/SharedKernel/SharedKernel.Application/Http/RequestContextConstants.cs | Adds shared header/context/log-property constants for request context. |
| src/SharedKernel/SharedKernel.Application/Batch/Rules/IValidationMetrics.cs | Adds application-layer abstraction for validation metrics. |
| src/SharedKernel/SharedKernel.Application/Batch/Rules/FluentValidationBatchRule.cs | Updates batch validation rule to record validation metrics. |
| src/SharedKernel/SharedKernel.Api/SharedKernel.Api.csproj | Adds health check + telemetry/redaction deps and references messaging project. |
| src/SharedKernel/SharedKernel.Api/OutputCaching/TenantAwareOutputCachePolicy.cs | Adds cache hit/outcome telemetry and sets Age header on hits. |
| src/SharedKernel/SharedKernel.Api/OutputCaching/OutputCacheInvalidationService.cs | Adds cache invalidation activity + duration metric recording. |
| src/SharedKernel/SharedKernel.Api/Middleware/RequestContextMiddleware.cs | Adds per-request correlation/trace/timing headers + Serilog context + metrics tags. |
| src/SharedKernel/SharedKernel.Api/Filters/Validation/FluentValidationActionFilter.cs | Records validation metrics for MVC model validation failures. |
| src/SharedKernel/SharedKernel.Api/Extensions/WebApplicationPipelineExtensions.cs | Adds request context pipeline and shared health-check endpoint mapping. |
| src/SharedKernel/SharedKernel.Api/Extensions/SharedServiceRegistration.cs | Registers grouped DbContext deps, validation telemetry, and shared controllers setup. |
| src/SharedKernel/SharedKernel.Api/Extensions/SerilogExtensions.cs | Adds ActivityTraceEnricher to shared Serilog host configuration. |
| src/SharedKernel/SharedKernel.Api/Extensions/RequestContextPipelineExtensions.cs | Adds middleware + Serilog request logging configuration with custom log levels. |
| src/SharedKernel/SharedKernel.Api/Extensions/OutputCachingExtensions.cs | Updates output cache policy registration to DI-based policy + builder configuration. |
| src/SharedKernel/SharedKernel.Api/Extensions/ObservabilityExtensions.cs | Major refactor for OTLP/Aspire exporters, resources, views, and built-in meter subscriptions. |
| src/SharedKernel/SharedKernel.Api/Extensions/LoggingRedactionExtensions.cs | Adds redaction setup (HMAC + erasing redactors) and enables logger redaction. |
| src/SharedKernel/SharedKernel.Api/Extensions/KeycloakAuthExtensions.cs | Records auth telemetry for missing tenant claim and authentication failures. |
| src/SharedKernel/SharedKernel.Api/Extensions/HostExtensions.cs | Wraps DB migration in startup telemetry scope with failure tagging. |
| src/SharedKernel/SharedKernel.Api/Extensions/HealthChecksServiceCollectionExtensions.cs | Adds shared health check registration helpers (Postgres/Redis/RabbitMQ). |
| src/SharedKernel/SharedKernel.Api/ExceptionHandling/ApiExceptionHandlerLogs.cs | Adds source-generated logger messages with classifications. |
| src/SharedKernel/SharedKernel.Api/ExceptionHandling/ApiExceptionHandler.cs | Records conflict telemetry and switches to source-generated logs. |
| src/Services/Webhooks/Webhooks.Infrastructure/Persistence/WebhooksDbContextDesignTimeFactory.cs | Uses shared design-time connection string resolver. |
| src/Services/Webhooks/Webhooks.Api/Program.cs | Registers Postgres + RabbitMQ health checks. |
| src/Services/Webhooks/Webhooks.Api/appsettings.Production.json | Adds redaction configuration section. |
| src/Services/Webhooks/Webhooks.Api/appsettings.json | Adds redaction configuration section. |
| src/Services/Reviews/Reviews.Infrastructure/Persistence/ReviewsDbContextDesignTimeFactory.cs | Uses design-time connection resolver + default dependency record. |
| src/Services/Reviews/Reviews.Infrastructure/Persistence/ReviewsDbContext.cs | Updates DbContext to accept dependency record. |
| src/Services/Reviews/Reviews.Api/Program.cs | Uses shared controllers, health checks, and removes Wolverine FluentValidation wiring. |
| src/Services/Reviews/Reviews.Api/appsettings.Production.json | Adds redaction configuration section. |
| src/Services/Reviews/Reviews.Api/appsettings.json | Adds redaction configuration section. |
| src/Services/ProductCatalog/ProductCatalog.Infrastructure/Persistence/ProductCatalogDbContextDesignTimeFactory.cs | Uses design-time connection resolver + default dependency record. |
| src/Services/ProductCatalog/ProductCatalog.Infrastructure/Persistence/ProductCatalogDbContext.cs | Updates DbContext to accept dependency record. |
| src/Services/ProductCatalog/ProductCatalog.Infrastructure/Persistence/MongoDbContext.cs | Adds IMongoDbHealthProbe and implements it on MongoDbContext. |
| src/Services/ProductCatalog/ProductCatalog.Application/Features/Product/Commands/UpdateProductsValidator.cs | Removes dedicated validate/load helper (inlined into handler load step). |
| src/Services/ProductCatalog/ProductCatalog.Application/Features/Product/Commands/UpdateProductsCommand.cs | Refactors compound-handler load step to use batch rule + metrics and bulk loading logic. |
| src/Services/ProductCatalog/ProductCatalog.Application/Features/Product/Commands/CreateProductsCommand.cs | Switches to DI-provided batch rule (records validation metrics). |
| src/Services/ProductCatalog/ProductCatalog.Application/Features/Category/Commands/UpdateCategoriesCommand.cs | Splits into Wolverine load/handle steps and switches to DI batch rule. |
| src/Services/ProductCatalog/ProductCatalog.Application/Features/Category/Commands/CreateCategoriesCommand.cs | Switches to DI-provided batch rule (records validation metrics). |
| src/Services/ProductCatalog/ProductCatalog.Api/Program.cs | Uses shared controllers, richer health checks (incl. Mongo), registers health probe, removes Wolverine FluentValidation. |
| src/Services/ProductCatalog/ProductCatalog.Api/Health/MongoDbHealthCheck.cs | Adds MongoDB health check implementation. |
| src/Services/ProductCatalog/ProductCatalog.Api/appsettings.Production.json | Adds redaction configuration section. |
| src/Services/ProductCatalog/ProductCatalog.Api/appsettings.json | Adds redaction configuration section. |
| src/Services/Notifications/Notifications.Infrastructure/Persistence/NotificationsDbContextDesignTimeFactory.cs | Uses shared design-time connection string resolver. |
| src/Services/Notifications/Notifications.Api/Program.cs | Registers Postgres + RabbitMQ health checks. |
| src/Services/Notifications/Notifications.Api/appsettings.Production.json | Adds redaction configuration section. |
| src/Services/Notifications/Notifications.Api/appsettings.json | Adds redaction configuration section. |
| src/Services/Identity/Identity.Infrastructure/Security/Tenant/TenantClaimValidatorLogs.cs | Adds source-generated logs with parameter classifications. |
| src/Services/Identity/Identity.Infrastructure/Security/Tenant/TenantClaimValidator.cs | Switches to source-generated logs. |
| src/Services/Identity/Identity.Infrastructure/Security/Keycloak/KeycloakAdminTokenProvider.cs | Switches token failure logging to source-generated log method. |
| src/Services/Identity/Identity.Infrastructure/Security/Keycloak/KeycloakAdminServiceLogs.cs | Adds source-generated logs for Keycloak admin operations + token provider. |
| src/Services/Identity/Identity.Infrastructure/Security/Keycloak/KeycloakAdminService.cs | Switches to source-generated logs. |
| src/Services/Identity/Identity.Infrastructure/Persistence/IdentityDbContextDesignTimeFactory.cs | Uses design-time resolver + default dependency record. |
| src/Services/Identity/Identity.Infrastructure/Persistence/IdentityDbContext.cs | Updates DbContext to accept dependency record. |
| src/Services/Identity/Identity.Api/Program.cs | Uses shared controllers, shared health checks, removes Wolverine FluentValidation. |
| src/Services/Identity/Identity.Api/appsettings.Production.json | Adds redaction configuration section. |
| src/Services/Identity/Identity.Api/appsettings.json | Adds redaction configuration section. |
| src/Services/FileStorage/FileStorage.Infrastructure/Persistence/FileStorageDbContextDesignTimeFactory.cs | Uses design-time resolver + default dependencies/normalization service. |
| src/Services/FileStorage/FileStorage.Infrastructure/Persistence/FileStorageDbContext.cs | Updates DbContext to accept dependency record + normalization service. |
| src/Services/FileStorage/FileStorage.Api/Program.cs | Registers shared health checks including Redis and RabbitMQ. |
| src/Services/FileStorage/FileStorage.Api/appsettings.Production.json | Adds redaction configuration section. |
| src/Services/FileStorage/FileStorage.Api/appsettings.json | Adds redaction configuration section. |
| src/Services/BackgroundJobs/BackgroundJobs.Infrastructure/Queue/JobProcessingBackgroundService.cs | Avoids repeated JSON serialization by caching completed result payload. |
| src/Services/BackgroundJobs/BackgroundJobs.Infrastructure/Persistence/BackgroundJobsDbContextDesignTimeFactory.cs | Uses shared design-time connection string resolver. |
| src/Services/BackgroundJobs/BackgroundJobs.Api/Program.cs | Adds richer health checks (incl. scheduler/coordination deps) and uses shared controllers. |
| src/Services/BackgroundJobs/BackgroundJobs.Api/appsettings.Production.json | Adds redaction configuration section. |
| src/Services/BackgroundJobs/BackgroundJobs.Api/appsettings.json | Adds redaction configuration section. |
| src/Gateway/Gateway.Api/Program.cs | Uses shared health-check endpoint mapping. |
| src/Gateway/Gateway.Api/appsettings.Production.json | Adds redaction configuration section. |
| src/Gateway/Gateway.Api/appsettings.json | Adds redaction configuration section. |
| global.json | Updates SDK version/roll-forward strategy. |
| Directory.Packages.props | Adds Serilog package version. |
| APITemplate.slnx | Updates solution comment to reflect microservices-only. |
| APITemplate.Microservices.code-workspace | Adds dedicated VS Code workspace configuration. |
| .vscode/settings.json | Sets default solution settings and excludes monolith from search/explorer. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
| public static partial void UnhandledException( | ||
| this ILogger logger, | ||
| Exception exception, | ||
| int statusCode, | ||
| [SensitiveData] string errorCode, | ||
| string traceId | ||
| ); |
There was a problem hiding this comment.
traceId is unclassified here, but the new unit tests assert it carries a PersonalDataAttribute. Either annotate traceId with the expected classification (or update the tests if traceId is intentionally unclassified) so logging/redaction behavior is consistent and tests match the implementation.
| if ( | ||
| IsOtlpExporterEnabled(options, environment) | ||
| && !string.IsNullOrWhiteSpace(options.Otlp.Endpoint) | ||
| ) | ||
| { | ||
| endpoints.Add(options.Otlp.Endpoint); | ||
| } |
There was a problem hiding this comment.
When IsOtlpExporterEnabled() resolves to true (default in containers) but options.Otlp.Endpoint is empty (the default), GetEnabledOtlpEndpoints() returns no OTLP endpoints, resulting in no OTLP exporters being registered at all. Consider providing a sensible default endpoint (as the previous implementation did) or failing fast/logging clearly when OTLP is enabled but no endpoint is configured to avoid silently running without telemetry in production.
| public ValueTask ServeFromCacheAsync( | ||
| OutputCacheContext context, | ||
| CancellationToken cancellationToken | ||
| ) => ValueTask.CompletedTask; | ||
| ) | ||
| { | ||
| context.HttpContext.Response.Headers.Age = "0"; | ||
| CacheTelemetry.RecordCacheHit(context); | ||
| return ValueTask.CompletedTask; |
There was a problem hiding this comment.
ServeFromCacheAsync forcibly sets the HTTP Age header to 0. This is not the actual cached response age and can override any Age value set by the output-caching middleware, producing misleading responses and potentially breaking downstream cache behavior/diagnostics. Prefer omitting manual Age handling (or using a custom header like X-Cache: HIT) and rely on telemetry (CacheTelemetry) for cache-hit tracking.
| internal static IReadOnlyDictionary<string, int> SnapshotStatuses() => Statuses; | ||
|
|
There was a problem hiding this comment.
SnapshotStatuses() returns the live ConcurrentDictionary instance. Even though it's IReadOnlyDictionary, callers can still downcast and mutate, making tests (and any future internal consumers) able to accidentally affect global metric state. Consider returning a defensive copy (e.g., Statuses.ToDictionary(...)) or a read-only wrapper to keep the snapshot immutable.
There was a problem hiding this comment.
Code Review
This pull request introduces a comprehensive observability and infrastructure overhaul, featuring HMAC-based log redaction, centralized request context middleware for correlation and tracing, and expanded OpenTelemetry metrics. The changes standardize health checks across services, refactor database context dependencies into shared components, and implement source-generated logging with data classification for improved performance and compliance. Feedback was provided regarding the removal of redundant options validation in the redaction setup and addressing potential lifecycle issues with static telemetry gauges.
| RedactionOptions redactionOptions = GetRedactionOptions(configuration); | ||
| Validator.ValidateObject( | ||
| redactionOptions, | ||
| new ValidationContext(redactionOptions), | ||
| validateAllProperties: true | ||
| ); |
There was a problem hiding this comment.
The manual retrieval and validation of RedactionOptions here is redundant since AddValidatedOptions is called just above (or ValidateDataAnnotations in the else block). While it's necessary to have the options instance to resolve the HMAC key for the redactor registration, you should ideally resolve it from the IServiceProvider within the AddRedaction builder if possible, or ensure that this manual validation logic stays perfectly in sync with the options registration logic.
| private static readonly ObservableGauge<int> Gauge = | ||
| ObservabilityConventions.SharedHealthMeter.CreateObservableGauge( | ||
| TelemetryMetricNames.HealthStatus, | ||
| ObserveStatuses | ||
| ); |
There was a problem hiding this comment.
The Gauge is declared as static, and it's initialized by calling CreateObservableGauge on SharedHealthMeter. Since SharedHealthMeter is also static, this is technically safe. However, if the Meter were ever changed to be instance-based (e.g., for better testability), this static initialization would cause issues with duplicate metric registrations or memory leaks in some telemetry providers. Consider moving the gauge registration into the constructor or an initialization method if the meter lifecycle changes.
- Updated Program.cs to use AddControllers instead of AddSharedControllers and added FluentValidation support in Wolverine. - Removed Redaction settings from appsettings.json in both Reviews and Webhooks services. - Modified ReviewsDbContext to include new dependencies for auditing and soft delete functionality. - Simplified health check registration in Webhooks service. - Updated DbContextDesignTimeFactory to use hardcoded connection strings for local development. - Refactored ApiExceptionHandler to improve logging and removed observability dependencies. - Cleaned up HostExtensions and KeycloakAuthExtensions by removing observability-related code. - Streamlined ObservabilityExtensions by removing unnecessary configurations and simplifying OpenTelemetry setup. - Adjusted OutputCachingExtensions to ensure proper service registration. - Removed unused observability and telemetry code from various files. - Introduced ErrorOrValidationMiddleware for handling validation errors in Wolverine handlers. - Enhanced SoftDeleteProcessor to improve soft delete logic and reduce complexity. - Updated TenantAuditableDbContext to use new dependency injection patterns. - Cleaned up RepositoryBase to clarify write method responsibilities. - Removed unnecessary project references and updated package dependencies in SharedKernel projects.
… string resolution
…ing redaction options configuration
…tion and cache metrics handling
… handling and updating test repository mock behavior
…ption catch for RabbitMQ channel issues
…Q channel and aggregate exceptions
…ify async disposal in tests
… to target specific error source
DesignTimeConnectionStringResolverto resolve connection strings for design-time DbContext creation.DesignTimeDbContextDefaultsto provide null-object collaborators for EF Core design-time factories.SoftDeleteProcessorto streamline soft delete operations with a context object.TenantAuditableDbContextto utilize a newTenantAuditableDbContextDependenciesrecord for better dependency management.