-
Notifications
You must be signed in to change notification settings - Fork 160
Integrate health monitoring into vMCP server #3101
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull request overview
This PR integrates health monitoring infrastructure into the vMCP server to enable periodic backend health checks with configurable intervals and thresholds. The implementation provides a new HTTP endpoint for querying backend health status, graceful degradation when health monitoring fails, and authentication bypass for health check requests.
Key Changes:
- Added health monitor lifecycle management (initialization, startup, and shutdown) in the vMCP server
- Introduced
/api/backends/healthHTTP endpoint to expose backend health status - Updated authentication strategies to skip authentication for health check requests
Reviewed changes
Copilot reviewed 5 out of 5 changed files in this pull request and generated 4 comments.
Show a summary per file
| File | Description |
|---|---|
| pkg/vmcp/server/server.go | Integrates health monitor into server lifecycle with configuration, initialization, start/stop management, new HTTP endpoint handler, and getter methods for health status |
| pkg/vmcp/server/health_monitoring_test.go | Comprehensive test coverage for health monitoring scenarios including disabled/enabled states, startup failures, HTTP endpoint behavior, and lifecycle management |
| pkg/vmcp/auth/strategies/tokenexchange.go | Updates token exchange authentication strategy to skip authentication for health check requests using context marker |
| pkg/vmcp/auth/strategies/header_injection.go | Updates header injection authentication strategy to skip authentication for health check requests using context marker |
| cmd/vmcp/app/commands.go | Configures health monitor from operational settings, mapping HealthCheckInterval and UnhealthyThreshold to health.MonitorConfig |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
80eaf93 to
6a3fcae
Compare
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #3101 +/- ##
==========================================
+ Coverage 57.11% 57.16% +0.05%
==========================================
Files 341 341
Lines 33949 34053 +104
==========================================
+ Hits 19389 19468 +79
- Misses 12951 12972 +21
- Partials 1609 1613 +4 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull request overview
Copilot reviewed 7 out of 7 changed files in this pull request and generated 3 comments.
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
a4eedc5 to
95dba05
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull request overview
Copilot reviewed 7 out of 7 changed files in this pull request and generated 6 comments.
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
95dba05 to
1851665
Compare
author taskbot <taskbot@users.noreply.github.com> 1766072123 +0100 committer taskbot <taskbot@users.noreply.github.com> 1766158585 +0100 Integrate health monitoring into vMCP server Integrates the health monitoring infrastructure (from previous into the vMCP server, enabling periodic backend health checks with configurable Related-to: #3036 intervals and thresholds. changes from review changes from review add missing method Apply suggestion from @Copilot Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
1851665 to
0c290a9
Compare
Integrates the health monitoring infrastructure (from previous into the vMCP server, enabling periodic backend health checks with configurable intervals and thresholds.
Related-to: #3036