Repository navigation
feat(vscode): support file and HTTP Kamelet catalogs - #1664
bartoszpop wants to merge 3 commits into
Conversation
|
Thanks for putting this together, @bartoszpop. The tests are great and the PR builds cleanly. We'd like to hold off on merging, though, and explain why #889 suggests cloning a Kamelets repository locally and pointing Karavan.kameletsPath at it. A local clone gives us the things a shared catalog needs, and Karavan doesn't have to implement any of them:
Loading from a URL can't offer authentication or versioning. Because Camel JBang can't use a URL, it also means splitting the configuration into two settings. The designer could then show Kamelets the runtime can't find, and existing setups would stop passing --local-kamelet-dir without anyone noticing. That said, two parts of this PR would be really welcome as a smaller, separate PR:
Thanks again, and happy to help with the follow-up! |
Support local files, directories and HTTP(S) catalogs with multi-document YAML validation, a 30-second remote timeout and explicit error reporting. Add catalog documentation and focused regression tests. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Expand extension-host variables using or in catalog sources. Report undefined variables without fetching, preserve literal values, and document URL and local-path usage. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
1615e61 to
bcc4d86
Compare
|
Thanks for the detailed feedback @mgubaidullin ! I've split the changes into #1666 and #1664, as suggested. Your points are all valid, and I understand the concerns. However, I'd like to highlight a few considerations:
Please consider the points above to support editor-only use case as well. Of course, I respect your decision in that regard. |
Fixes #889
Summary
Extend
Karavan.kameletsPathto load editor Kamelet catalogs from local directories, individual YAML files, and HTTP(S) URLs.Configuration and migration
Karavan.kameletsPathis now editor-only, including directory sources. It is never passed to Camel JBang or downloaded into the integration project.Use the new
camel.localKameletDirsetting for--local-kamelet-dirduring run/export, including runtime run and deploy. It accepts only an existing local directory.Existing users relying on
Karavan.kameletsPathfor runtime Kamelets must also setcamel.localKameletDir. Reopen the designer after changing the editor catalog setting.Validation
npm run test:kamelets.npm run package.Regression coverage includes the shipped 250-Kamelet catalog with both line endings, multi-document sources, HTTP redirects and failures, timeout handling, runtime-setting validation, and reversible Custom only filtering.