Conversation
Signed-off-by: Samuel K <skevetter@pm.me>
Signed-off-by: Samuel K <skevetter@pm.me>
📝 WalkthroughWalkthroughThis pull request refactors the provider management system by introducing a ProviderParams struct to encapsulate configuration parameters, consolidating multiple provider-loading paths into centralized workflows (LoadAllProviders), and adding new functions for provider lookup, installation, and source resolution (FindProvider, AddProvider, UpdateProvider, etc.). New provider source resolution logic is added to handle internal, URL-based, file-based, and GitHub-hosted providers. Changes
Sequence DiagramsequenceDiagram
participant Client as Caller
participant LAP as LoadAllProviders
participant LCP as loadConfiguredProviders
participant LUP as loadUnconfiguredProviders
participant Resolver as Provider Source Resolver
participant Downloader as Binary Downloader
Client->>LAP: LoadAllProviders(devPodConfig, log)
LAP->>LCP: Load from devPodConfig
LCP-->>LAP: configured providers map
LAP->>LUP: Discover from filesystem
LUP-->>LAP: unconfigured providers map
LAP->>LAP: Merge maps
alt Provider needs source resolved
LAP->>Resolver: Resolve source (internal/URL/file/GitHub)
Resolver->>Downloader: Download if needed
Downloader-->>Resolver: raw provider bytes
Resolver-->>LAP: resolved provider config
end
LAP-->>Client: map[string]*ProviderWithOptions
Estimated code review effort🎯 4 (Complex) | ⏱️ ~50 minutes 🚥 Pre-merge checks | ✅ 2 | ❌ 1❌ Failed checks (1 warning)
✅ Passed checks (2 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing touches
🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
Summary by CodeRabbit
Refactor
Bug Fixes
✏️ Tip: You can customize this high-level summary in your review settings.