• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

stacklok / toolhive / 19098918115
51%

Build:
DEFAULT BRANCH: main
Ran 05 Nov 2025 10:32AM UTC
Jobs 1
Files 346
Run time 3min
Badge
Embed ▾
README BADGES
x

If you need to use a raster PNG badge, change the '.svg' to '.png' in the link

Markdown

Textile

RDoc

HTML

Rst

05 Nov 2025 10:26AM UTC coverage: 48.307% (+0.07%) from 48.235%
19098918115

push

github

web-flow
Implement outgoing authentication strategies for vMCP (#2451)

* Reorganize incoming auth factory into subfolder to prevent an import cycle

Move incoming authentication factory from pkg/vmcp/auth/ to
pkg/vmcp/auth/factory/ subfolder to improve code organization.
This separates factory code from core authentication types and
middleware.

* Refactor outgoing auth to separate registry from strategy

Rename OutgoingAuthenticator to OutgoingAuthRegistry to better reflect
its responsibility as a strategy registry rather than an authenticator.

The interface now focuses solely on strategy management (registration
and retrieval), while authentication is performed directly by Strategy
implementations.

This separation improves performance by eliminating indirection in the
hot path (per-request authentication) and clarifies the single
responsibility of each component: the registry manages strategies,
strategies perform authentication.

* Add factory package to resolve auth import cycle

Introduces pkg/vmcp/auth/factory to break the circular dependency
between pkg/vmcp/auth and pkg/vmcp/auth/strategies.

The import cycle occurred because:
- auth package needed to import strategies to instantiate them
- strategies package imported auth for Identity and context helpers

The factory package sits at the composition layer and can import both
auth (for interfaces) and strategies (for implementations) without
creating cycles.

* Integrate authentication registry into HTTP backend client

Refactors HTTPBackendClient to accept an OutgoingAuthRegistry and
apply authentication strategies to all backend requests via a new
authRoundTripper middleware.

Authentication is now resolved and validated once at client creation
time rather than per-request, improving performance and enabling
early error detection for misconfigurations.

The authRoundTripper clones requests to preserve immutability before
applying authentication, ensuring thread-safety and preventing
unintended side... (continued)

201 of 299 new or added lines in 11 files covered. (67.22%)

12 existing lines in 3 files now uncovered.

21929 of 45395 relevant lines covered (48.31%)

37.28 hits per line

New Missed Lines in Diff

Lines Coverage ∆ File
2
93.94
pkg/vmcp/auth/strategies/header_injection.go
2
57.38
-1.09% pkg/vmcp/config/validator.go
3
90.91
pkg/vmcp/auth/outgoing_registry.go
6
91.43
pkg/vmcp/auth/factory/outgoing.go
8
52.52
-1.14% pkg/vmcp/config/yaml_loader.go
11
0.0
0.0% cmd/vmcp/app/commands.go
18
27.11
12.37% pkg/vmcp/client/client.go
19
74.77
-15.93% pkg/vmcp/aggregator/cli_discoverer.go
29
0.0
pkg/vmcp/client/mocks/mock_outgoing_registry.go

Uncovered Existing Lines

Lines Coverage ∆ File
2
56.0
-0.24% pkg/workloads/manager.go
3
72.39
-1.12% pkg/ignore/processor.go
7
57.38
-1.09% pkg/vmcp/config/validator.go
Jobs
ID Job ID Ran Files Coverage
1 19098918115.1 05 Nov 2025 10:32AM UTC 346
48.31
GitHub Action Run
Source Files on build 19098918115
  • Tree
  • List 346
  • Changed 9
  • Source Changed 7
  • Coverage Changed 8
Coverage ∆ File Lines Relevant Covered Missed Hits/Line
  • Back to Repo
  • Github Actions Build #19098918115
  • 03302b2c on github
  • Prev Build on main (#19096390503)
  • Next Build on main (#19102368340)
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2025 Coveralls, Inc