This is an automated email from the ASF dual-hosted git repository.
davsclaus pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/camel.git
The following commit(s) were added to refs/heads/main by this push:
new 2b83394152e CAMEL-20994: camel-jbang - Include direct component when
using rest-dsl
2b83394152e is described below
commit 2b83394152ed0f3cddbfaeaed937c2a647d1b968
Author: Claus Ibsen <[email protected]>
AuthorDate: Tue Aug 6 07:26:23 2024 +0200
CAMEL-20994: camel-jbang - Include direct component when using rest-dsl
---
.../camel/main/download/DependencyDownloaderComponentResolver.java | 7 +++++++
1 file changed, 7 insertions(+)
diff --git
a/dsl/camel-kamelet-main/src/main/java/org/apache/camel/main/download/DependencyDownloaderComponentResolver.java
b/dsl/camel-kamelet-main/src/main/java/org/apache/camel/main/download/DependencyDownloaderComponentResolver.java
index 06bc65678ac..a6ea02a17e6 100644
---
a/dsl/camel-kamelet-main/src/main/java/org/apache/camel/main/download/DependencyDownloaderComponentResolver.java
+++
b/dsl/camel-kamelet-main/src/main/java/org/apache/camel/main/download/DependencyDownloaderComponentResolver.java
@@ -72,6 +72,13 @@ public final class DependencyDownloaderComponentResolver
extends DefaultComponen
if (answer instanceof PlatformHttpComponent) {
MainHttpServerFactory.setupHttpServer(camelContext, silent);
}
+ if ("rest".equals(name)) {
+ // include direct component when using rest-dsl
+ ComponentModel direct = catalog.componentModel("direct");
+ if (direct != null) {
+ downloadLoader(direct.getGroupId(), direct.getArtifactId(),
direct.getVersion());
+ }
+ }
if (answer == null) {
List<String> suggestion =
SuggestSimilarHelper.didYouMean(catalog.findComponentNames(), name);
if (suggestion != null && !suggestion.isEmpty()) {