Skip to content

Conversation

@yrobla
Copy link
Contributor

@yrobla yrobla commented Jan 12, 2026

Add K8sReporter implementation that enables vMCP runtime to report operational status to VirtualMCPServer.Status subresource when running in Kubernetes. This completes the StatusReporter abstraction with both CLI (NoOpReporter) and Kubernetes modes.

Large PR Justification

This is an atomic PR, including test coverage. It cannot be split because it provides a complete and independent functionality.

Closes: #3149

Add K8sReporter implementation that enables vMCP runtime to report
operational status to VirtualMCPServer.Status subresource when running
in Kubernetes. This completes the StatusReporter abstraction with both
CLI (NoOpReporter) and Kubernetes modes.

Closes: #3149
@github-actions github-actions bot added the size/XL Extra large PR: 1000+ lines changed label Jan 12, 2026
Copy link
Contributor

@github-actions github-actions bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Large PR Detected

This PR exceeds 1000 lines of changes and requires justification before it can be reviewed.

How to unblock this PR:

Add a section to your PR description with the following format:

## Large PR Justification

[Explain why this PR must be large, such as:]
- Generated code that cannot be split
- Large refactoring that must be atomic
- Multiple related changes that would break if separated
- Migration or data transformation

Alternative:

Consider splitting this PR into smaller, focused changes (< 1000 lines each) for easier review and reduced risk.

See our Contributing Guidelines for more details.


This review will be automatically dismissed once you add the justification section.

@codecov
Copy link

codecov bot commented Jan 12, 2026

Codecov Report

❌ Patch coverage is 59.11950% with 65 lines in your changes missing coverage. Please review.
✅ Project coverage is 56.97%. Comparing base (e520544) to head (4968daf).

Files with missing lines Patch % Lines
pkg/vmcp/status/k8s_reporter.go 59.57% 54 Missing and 3 partials ⚠️
pkg/vmcp/status/factory.go 66.66% 5 Missing ⚠️
cmd/vmcp/app/commands.go 0.00% 3 Missing ⚠️
Additional details and impacted files
@@              Coverage Diff               @@
##           issue-3147    #3251      +/-   ##
==============================================
+ Coverage       56.96%   56.97%   +0.01%     
==============================================
  Files             352      354       +2     
  Lines           34978    35023      +45     
==============================================
+ Hits            19924    19954      +30     
- Misses          13396    13410      +14     
- Partials         1658     1659       +1     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

Copy link
Contributor

Copilot AI left a 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 implements K8sReporter to enable vMCP runtime to report operational status to VirtualMCPServer.Status subresource when running in Kubernetes. The implementation completes the StatusReporter abstraction pattern with automatic detection between CLI (NoOpReporter) and Kubernetes (K8sReporter) modes based on environment variables.

Changes:

  • Added K8sReporter implementation with periodic status reporting to Kubernetes API
  • Created factory pattern for automatic reporter selection based on environment
  • Added comprehensive unit tests and E2E tests for status reporting functionality

Reviewed changes

Copilot reviewed 7 out of 7 changed files in this pull request and generated 2 comments.

Show a summary per file
File Description
pkg/vmcp/status/k8s_reporter.go Core K8sReporter implementation with status update and lifecycle management
pkg/vmcp/status/k8s_reporter_test.go Unit tests for K8sReporter functionality
pkg/vmcp/status/factory.go Factory pattern for environment-based reporter selection
pkg/vmcp/status/factory_test.go Unit tests for factory logic and environment detection
cmd/vmcp/app/commands.go Integration of factory-based reporter creation in serve command
cmd/thv-operator/controllers/virtualmcpserver_deployment.go RBAC permissions for status subresource updates
test/e2e/thv-operator/virtualmcp/virtualmcp_status_reporting_test.go End-to-end tests validating status reporting in Kubernetes

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@yrobla yrobla self-assigned this Jan 12, 2026
@github-actions github-actions bot added size/XL Extra large PR: 1000+ lines changed and removed size/XL Extra large PR: 1000+ lines changed labels Jan 12, 2026
@github-actions github-actions bot dismissed their stale review January 12, 2026 09:55

Large PR justification has been provided. Thank you!

@github-actions
Copy link
Contributor

✅ Large PR justification has been provided. The size review has been dismissed and this PR can now proceed with normal review.

Copy link
Contributor

Copilot AI left a 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 no new comments.


💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@github-actions github-actions bot added size/XL Extra large PR: 1000+ lines changed and removed size/XL Extra large PR: 1000+ lines changed labels Jan 12, 2026
@github-actions github-actions bot added size/XL Extra large PR: 1000+ lines changed and removed size/XL Extra large PR: 1000+ lines changed labels Jan 12, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

size/XL Extra large PR: 1000+ lines changed

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants