Enhance DataEngine health checks to use component health endpoints with fallback#99
Merged
Merged
Conversation
This reverts commit dd01f18.
…ests for exception types
…ed clarity and maintainability
…and HttpRequestBaseUrlProvider class
…ow InvalidDependencyException for null inputs
…rgumentException instead of InvalidDependencyException
Dependency Review✅ No vulnerabilities or license issues or OpenSSF Scorecard issues found.Scanned FilesNone |
mm-kgi
marked this pull request as ready for review
April 27, 2026 12:44
Contributor
There was a problem hiding this comment.
Pull request overview
This PR updates DataEngine’s external dependency health checks to prefer component-specific health endpoints (e.g., /actuator/health, /healthz) and fall back to the existing business API probes when a health endpoint isn’t configured.
Changes:
- Add
healthEndpointsupport to configured service instances (template repositories/registries and plugins). - Update health check implementations to probe
healthEndpointwhen present, otherwise use the existing?limit=1business endpoint fallback. - Extend unit/module test configurations and unit tests to cover the new endpoint-selection behavior.
Reviewed changes
Copilot reviewed 12 out of 12 changed files in this pull request and generated 3 comments.
Show a summary per file
| File | Description |
|---|---|
| source/AAS.TwinEngine.Plugin.TestPlugin/Example/docker-compose.yml | Adds plugin and template component healthEndpoint env vars for the example setup. |
| example/docker-compose.yml | Adds healthEndpoint env vars for plugin and template components in the main example compose. |
| source/AAS.TwinEngine.DataEngine/appsettings.json | Adds healthEndpoint defaults for plugins and template components. |
| source/AAS.TwinEngine.DataEngine/appsettings.development.json | Adds healthEndpoint defaults for plugins and template components in development settings. |
| source/AAS.TwinEngine.DataEngine/ServiceConfiguration/Config/TemplateManagementConfig.cs | Extends ServiceInstance with HealthEndpoint configuration. |
| source/AAS.TwinEngine.DataEngine/Infrastructure/Monitoring/TemplateRepositoryHealthCheck.cs | Uses configured health endpoints with fallback for template repository checks. |
| source/AAS.TwinEngine.DataEngine/Infrastructure/Monitoring/TemplateRegistryHealthCheck.cs | Uses configured health endpoints with fallback for template registry checks. |
| source/AAS.TwinEngine.DataEngine/Infrastructure/Monitoring/PluginAvailabilityHealthCheck.cs | Uses per-plugin configured health endpoints with fallback to default healthz. |
| source/AAS.TwinEngine.DataEngine.UnitTests/Infrastructure/Monitoring/TemplateRepositoryHealthCheckTests.cs | Adds tests to verify configured vs fallback endpoint behavior. |
| source/AAS.TwinEngine.DataEngine.UnitTests/Infrastructure/Monitoring/TemplateRegistryHealthCheckTests.cs | Adds tests to verify configured vs fallback endpoint behavior. |
| source/AAS.TwinEngine.DataEngine.UnitTests/Infrastructure/Monitoring/PluginAvailabilityHealthCheckTests.cs | Adds tests to verify custom/default plugin health endpoint selection. |
| source/AAS.TwinEngine.DataEngine.ModuleTests/TestData/v2-config/appsettings.json | Updates module test config to include healthEndpoint entries. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
|
Test & Coverage ReportTest Results Summary
Code CoverageUnit Tests Coverage
Minimum allowed line rate is Module Tests Coverage
|
mm-asha
approved these changes
Apr 29, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.



Overview
This PR improves the reliability of DataEngine health checks by prioritizing dedicated component health endpoints instead of relying on business API calls.
Previously, health checks used business GET endpoints (e.g., Template Registry/Repository APIs), which could fail in secured environments due to authentication/authorization requirements, leading to false-negative health statuses.
Key Changes
Health Endpoint Preference
/actuator/healthis supported and used as the preferred probe endpoint.Fallback Mechanism
Configuration Handling