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-spring-boot.git


The following commit(s) were added to refs/heads/main by this push:
     new 8c63464d588 Regen
8c63464d588 is described below

commit 8c63464d588b810a84883eb24f3463c84ea5b9db
Author: Claus Ibsen <[email protected]>
AuthorDate: Mon Apr 13 17:05:06 2026 +0200

    Regen
---
 .../camel/springboot/catalog/components/exec.json  | 26 +++++---
 .../camel-exec-starter/src/main/docs/exec.json     | 31 +++++++++
 .../springboot/ExecComponentAutoConfiguration.java |  2 +-
 .../springboot/ExecComponentConfiguration.java     | 74 ++++++++++++++++++++++
 .../exec/springboot/ExecComponentConverter.java    | 65 +++++++++++++++++++
 ...rk.boot.autoconfigure.AutoConfiguration.imports |  3 +-
 6 files changed, 189 insertions(+), 12 deletions(-)

diff --git 
a/catalog/camel-catalog-provider-springboot/src/main/resources/org/apache/camel/springboot/catalog/components/exec.json
 
b/catalog/camel-catalog-provider-springboot/src/main/resources/org/apache/camel/springboot/catalog/components/exec.json
index 79cc92acbc3..04ba9b98f81 100644
--- 
a/catalog/camel-catalog-provider-springboot/src/main/resources/org/apache/camel/springboot/catalog/components/exec.json
+++ 
b/catalog/camel-catalog-provider-springboot/src/main/resources/org/apache/camel/springboot/catalog/components/exec.json
@@ -25,7 +25,12 @@
   },
   "componentProperties": {
     "lazyStartProducer": { "index": 0, "kind": "property", "displayName": 
"Lazy Start Producer", "group": "producer", "label": "producer", "required": 
false, "type": "boolean", "javaType": "boolean", "deprecated": false, 
"autowired": false, "secret": false, "defaultValue": false, "description": 
"Whether the producer should be started lazy (on the first message). By 
starting lazy you can use this to allow CamelContext and routes to startup in 
situations where a producer may otherwise fail [...]
-    "autowiredEnabled": { "index": 1, "kind": "property", "displayName": 
"Autowired Enabled", "group": "advanced", "label": "advanced", "required": 
false, "type": "boolean", "javaType": "boolean", "deprecated": false, 
"autowired": false, "secret": false, "defaultValue": true, "description": 
"Whether autowiring is enabled. This is used for automatic autowiring options 
(the option must be marked as autowired) by looking up in the registry to find 
if there is a single instance of matching t [...]
+    "timeout": { "index": 1, "kind": "property", "displayName": "Timeout", 
"group": "producer", "label": "", "required": false, "type": "integer", 
"javaType": "long", "deprecated": false, "autowired": false, "secret": false, 
"description": "The timeout, in milliseconds, after which the executable should 
be terminated. If execution has not completed within the timeout, the component 
will send a termination request." },
+    "workingDir": { "index": 2, "kind": "property", "displayName": "Working 
Dir", "group": "producer", "label": "", "required": false, "type": "string", 
"javaType": "java.lang.String", "deprecated": false, "autowired": false, 
"secret": false, "description": "The directory in which the command should be 
executed. If null, the working directory of the current process will be used." 
},
+    "allowControlHeaders": { "index": 3, "kind": "property", "displayName": 
"Allow Control Headers", "group": "advanced", "label": "advanced", "required": 
false, "type": "boolean", "javaType": "boolean", "deprecated": false, 
"autowired": false, "secret": false, "defaultValue": false, "description": 
"Whether to allow to use Camel headers or not (default false). Enabling this 
allows to specify dynamic command line arguments via message header. However 
this can be seen as a potential securi [...]
+    "autowiredEnabled": { "index": 4, "kind": "property", "displayName": 
"Autowired Enabled", "group": "advanced", "label": "advanced", "required": 
false, "type": "boolean", "javaType": "boolean", "deprecated": false, 
"autowired": false, "secret": false, "defaultValue": true, "description": 
"Whether autowiring is enabled. This is used for automatic autowiring options 
(the option must be marked as autowired) by looking up in the registry to find 
if there is a single instance of matching t [...]
+    "binding": { "index": 5, "kind": "property", "displayName": "Binding", 
"group": "advanced", "label": "advanced", "required": false, "type": "object", 
"javaType": "org.apache.camel.component.exec.ExecBinding", "deprecated": false, 
"autowired": false, "secret": false, "description": "To use a custom 
org.apache.commons.exec.ExecBinding for advanced use-cases." },
+    "commandExecutor": { "index": 6, "kind": "property", "displayName": 
"Command Executor", "group": "advanced", "label": "advanced", "required": 
false, "type": "object", "javaType": 
"org.apache.camel.component.exec.ExecCommandExecutor", "deprecated": false, 
"autowired": false, "secret": false, "description": "To use a custom 
org.apache.commons.exec.ExecCommandExecutor that customizes the command 
execution. The default command executor utilizes the commons-exec library, 
which adds a shut [...]
   },
   "headers": {
     "CamelExecCommandExecutable": { "index": 0, "kind": "header", 
"displayName": "", "group": "in", "label": "in", "required": false, "javaType": 
"String", "deprecated": false, "deprecationNote": "", "autowired": false, 
"secret": false, "description": "The name of the system command that will be 
executed. Overrides executable in the URI.", "constantName": 
"org.apache.camel.component.exec.ExecBinding#EXEC_COMMAND_EXECUTABLE" },
@@ -42,14 +47,15 @@
   "properties": {
     "executable": { "index": 0, "kind": "path", "displayName": "Executable", 
"group": "producer", "label": "", "required": true, "type": "string", 
"javaType": "java.lang.String", "deprecated": false, "deprecationNote": "", 
"autowired": false, "secret": false, "description": "Sets the executable to be 
executed. The executable must not be empty or null." },
     "args": { "index": 1, "kind": "parameter", "displayName": "Args", "group": 
"producer", "label": "", "required": false, "type": "string", "javaType": 
"java.lang.String", "deprecated": false, "autowired": false, "secret": false, 
"description": "The arguments may be one or many whitespace-separated tokens." 
},
-    "binding": { "index": 2, "kind": "parameter", "displayName": "Binding", 
"group": "producer", "label": "", "required": false, "type": "object", 
"javaType": "org.apache.camel.component.exec.ExecBinding", "deprecated": false, 
"autowired": false, "secret": false, "description": "A reference to a 
org.apache.commons.exec.ExecBinding in the Registry." },
-    "commandExecutor": { "index": 3, "kind": "parameter", "displayName": 
"Command Executor", "group": "producer", "label": "", "required": false, 
"type": "object", "javaType": 
"org.apache.camel.component.exec.ExecCommandExecutor", "deprecated": false, 
"autowired": false, "secret": false, "description": "A reference to a 
org.apache.commons.exec.ExecCommandExecutor in the Registry that customizes the 
command execution. The default command executor utilizes the commons-exec 
library, which a [...]
-    "commandLogLevel": { "index": 4, "kind": "parameter", "displayName": 
"Command Log Level", "group": "producer", "label": "", "required": false, 
"type": "enum", "javaType": "org.apache.camel.LoggingLevel", "enum": [ "TRACE", 
"DEBUG", "INFO", "WARN", "ERROR", "OFF" ], "deprecated": false, "autowired": 
false, "secret": false, "defaultValue": "DEBUG", "description": "Logging level 
to be used for commands during execution. The default value is DEBUG. Possible 
values are TRACE, DEBUG, INFO, [...]
-    "exitValues": { "index": 5, "kind": "parameter", "displayName": "Exit 
Values", "group": "producer", "label": "", "required": false, "type": "string", 
"javaType": "java.lang.String", "deprecated": false, "autowired": false, 
"secret": false, "description": "The exit values of successful executions. If 
the process exits with another value, an exception is raised. Comma-separated 
list of exit values. And empty list (the default) sets no expected exit values 
and disables the check." },
-    "outFile": { "index": 6, "kind": "parameter", "displayName": "Out File", 
"group": "producer", "label": "", "required": false, "type": "string", 
"javaType": "java.lang.String", "deprecated": false, "autowired": false, 
"secret": false, "description": "The name of a file, created by the executable, 
that should be considered as its output. If no outFile is set, the standard 
output (stdout) of the executable will be used instead." },
-    "timeout": { "index": 7, "kind": "parameter", "displayName": "Timeout", 
"group": "producer", "label": "", "required": false, "type": "duration", 
"javaType": "long", "deprecated": false, "autowired": false, "secret": false, 
"description": "The timeout, in milliseconds, after which the executable should 
be terminated. If execution has not completed within the timeout, the component 
will send a termination request." },
-    "useStderrOnEmptyStdout": { "index": 8, "kind": "parameter", 
"displayName": "Use Stderr On Empty Stdout", "group": "producer", "label": "", 
"required": false, "type": "boolean", "javaType": "boolean", "deprecated": 
false, "autowired": false, "secret": false, "defaultValue": false, 
"description": "A boolean indicating that when stdout is empty, this component 
will populate the Camel Message Body with stderr. This behavior is disabled 
(false) by default." },
-    "workingDir": { "index": 9, "kind": "parameter", "displayName": "Working 
Dir", "group": "producer", "label": "", "required": false, "type": "string", 
"javaType": "java.lang.String", "deprecated": false, "autowired": false, 
"secret": false, "description": "The directory in which the command should be 
executed. If null, the working directory of the current process will be used." 
},
-    "lazyStartProducer": { "index": 10, "kind": "parameter", "displayName": 
"Lazy Start Producer", "group": "producer (advanced)", "label": 
"producer,advanced", "required": false, "type": "boolean", "javaType": 
"boolean", "deprecated": false, "autowired": false, "secret": false, 
"defaultValue": false, "description": "Whether the producer should be started 
lazy (on the first message). By starting lazy you can use this to allow 
CamelContext and routes to startup in situations where a produ [...]
+    "commandLogLevel": { "index": 2, "kind": "parameter", "displayName": 
"Command Log Level", "group": "producer", "label": "", "required": false, 
"type": "enum", "javaType": "org.apache.camel.LoggingLevel", "enum": [ "TRACE", 
"DEBUG", "INFO", "WARN", "ERROR", "OFF" ], "deprecated": false, "autowired": 
false, "secret": false, "defaultValue": "DEBUG", "description": "Logging level 
to be used for commands during execution. The default value is DEBUG. Possible 
values are TRACE, DEBUG, INFO, [...]
+    "exitValues": { "index": 3, "kind": "parameter", "displayName": "Exit 
Values", "group": "producer", "label": "", "required": false, "type": "string", 
"javaType": "java.lang.String", "deprecated": false, "autowired": false, 
"secret": false, "description": "The exit values of successful executions. If 
the process exits with another value, an exception is raised. Comma-separated 
list of exit values. And empty list (the default) sets no expected exit values 
and disables the check." },
+    "outFile": { "index": 4, "kind": "parameter", "displayName": "Out File", 
"group": "producer", "label": "", "required": false, "type": "string", 
"javaType": "java.lang.String", "deprecated": false, "autowired": false, 
"secret": false, "description": "The name of a file, created by the executable, 
that should be considered as its output. If no outFile is set, the standard 
output (stdout) of the executable will be used instead." },
+    "timeout": { "index": 5, "kind": "parameter", "displayName": "Timeout", 
"group": "producer", "label": "", "required": false, "type": "integer", 
"javaType": "long", "deprecated": false, "autowired": false, "secret": false, 
"description": "The timeout, in milliseconds, after which the executable should 
be terminated. If execution has not completed within the timeout, the component 
will send a termination request." },
+    "useStderrOnEmptyStdout": { "index": 6, "kind": "parameter", 
"displayName": "Use Stderr On Empty Stdout", "group": "producer", "label": "", 
"required": false, "type": "boolean", "javaType": "boolean", "deprecated": 
false, "autowired": false, "secret": false, "defaultValue": false, 
"description": "A boolean indicating that when stdout is empty, this component 
will populate the Camel Message Body with stderr. This behavior is disabled 
(false) by default." },
+    "workingDir": { "index": 7, "kind": "parameter", "displayName": "Working 
Dir", "group": "producer", "label": "", "required": false, "type": "string", 
"javaType": "java.lang.String", "deprecated": false, "autowired": false, 
"secret": false, "description": "The directory in which the command should be 
executed. If null, the working directory of the current process will be used." 
},
+    "lazyStartProducer": { "index": 8, "kind": "parameter", "displayName": 
"Lazy Start Producer", "group": "producer (advanced)", "label": 
"producer,advanced", "required": false, "type": "boolean", "javaType": 
"boolean", "deprecated": false, "autowired": false, "secret": false, 
"defaultValue": false, "description": "Whether the producer should be started 
lazy (on the first message). By starting lazy you can use this to allow 
CamelContext and routes to startup in situations where a produc [...]
+    "allowControlHeaders": { "index": 9, "kind": "parameter", "displayName": 
"Allow Control Headers", "group": "advanced", "label": "advanced", "required": 
false, "type": "boolean", "javaType": "boolean", "deprecated": false, 
"autowired": false, "secret": false, "defaultValue": false, "description": 
"Whether to allow to use Camel headers or not (default false). Enabling this 
allows to specify dynamic command line arguments via message header. However 
this can be seen as a potential secur [...]
+    "binding": { "index": 10, "kind": "parameter", "displayName": "Binding", 
"group": "advanced", "label": "advanced", "required": false, "type": "object", 
"javaType": "org.apache.camel.component.exec.ExecBinding", "deprecated": false, 
"autowired": false, "secret": false, "description": "To use a custom 
org.apache.commons.exec.ExecBinding for advanced use-cases." },
+    "commandExecutor": { "index": 11, "kind": "parameter", "displayName": 
"Command Executor", "group": "advanced", "label": "advanced", "required": 
false, "type": "object", "javaType": 
"org.apache.camel.component.exec.ExecCommandExecutor", "deprecated": false, 
"autowired": false, "secret": false, "description": "To use a custom 
org.apache.commons.exec.ExecCommandExecutor that customizes the command 
execution. The default command executor utilizes the commons-exec library, 
which adds a sh [...]
   }
 }
diff --git a/components-starter/camel-exec-starter/src/main/docs/exec.json 
b/components-starter/camel-exec-starter/src/main/docs/exec.json
index 99f8ad43b6e..d992f1ac4b1 100644
--- a/components-starter/camel-exec-starter/src/main/docs/exec.json
+++ b/components-starter/camel-exec-starter/src/main/docs/exec.json
@@ -13,6 +13,13 @@
     }
   ],
   "properties": [
+    {
+      "name": "camel.component.exec.allow-control-headers",
+      "type": "java.lang.Boolean",
+      "description": "Whether to allow to use Camel headers or not (default 
false). Enabling this allows to specify dynamic command line arguments via 
message header. However this can be seen as a potential security vulnerability 
if the header is coming from a malicious user, so use this with care.",
+      "sourceType": 
"org.apache.camel.component.exec.springboot.ExecComponentConfiguration",
+      "defaultValue": false
+    },
     {
       "name": "camel.component.exec.autowired-enabled",
       "type": "java.lang.Boolean",
@@ -20,6 +27,18 @@
       "sourceType": 
"org.apache.camel.component.exec.springboot.ExecComponentConfiguration",
       "defaultValue": true
     },
+    {
+      "name": "camel.component.exec.binding",
+      "type": "org.apache.camel.component.exec.ExecBinding",
+      "description": "To use a custom org.apache.commons.exec.ExecBinding for 
advanced use-cases. The option is a org.apache.camel.component.exec.ExecBinding 
type.",
+      "sourceType": 
"org.apache.camel.component.exec.springboot.ExecComponentConfiguration"
+    },
+    {
+      "name": "camel.component.exec.command-executor",
+      "type": "org.apache.camel.component.exec.ExecCommandExecutor",
+      "description": "To use a custom 
org.apache.commons.exec.ExecCommandExecutor that customizes the command 
execution. The default command executor utilizes the commons-exec library, 
which adds a shutdown hook for every executed command. The option is a 
org.apache.camel.component.exec.ExecCommandExecutor type.",
+      "sourceType": 
"org.apache.camel.component.exec.springboot.ExecComponentConfiguration"
+    },
     {
       "name": "camel.component.exec.customizer.enabled",
       "type": "java.lang.Boolean",
@@ -37,6 +56,18 @@
       "description": "Whether the producer should be started lazy (on the 
first message). By starting lazy you can use this to allow CamelContext and 
routes to startup in situations where a producer may otherwise fail during 
starting and cause the route to fail being started. By deferring this startup 
to be lazy then the startup failure can be handled during routing messages via 
Camel's routing error handlers. Beware that when the first message is processed 
then creating and starting the [...]
       "sourceType": 
"org.apache.camel.component.exec.springboot.ExecComponentConfiguration",
       "defaultValue": false
+    },
+    {
+      "name": "camel.component.exec.timeout",
+      "type": "java.lang.Long",
+      "description": "The timeout, in milliseconds, after which the executable 
should be terminated. If execution has not completed within the timeout, the 
component will send a termination request.",
+      "sourceType": 
"org.apache.camel.component.exec.springboot.ExecComponentConfiguration"
+    },
+    {
+      "name": "camel.component.exec.working-dir",
+      "type": "java.lang.String",
+      "description": "The directory in which the command should be executed. 
If null, the working directory of the current process will be used.",
+      "sourceType": 
"org.apache.camel.component.exec.springboot.ExecComponentConfiguration"
     }
   ],
   "hints": [],
diff --git 
a/components-starter/camel-exec-starter/src/main/java/org/apache/camel/component/exec/springboot/ExecComponentAutoConfiguration.java
 
b/components-starter/camel-exec-starter/src/main/java/org/apache/camel/component/exec/springboot/ExecComponentAutoConfiguration.java
index e2c97c52a32..7b3b5689620 100644
--- 
a/components-starter/camel-exec-starter/src/main/java/org/apache/camel/component/exec/springboot/ExecComponentAutoConfiguration.java
+++ 
b/components-starter/camel-exec-starter/src/main/java/org/apache/camel/component/exec/springboot/ExecComponentAutoConfiguration.java
@@ -42,7 +42,7 @@ import org.springframework.context.annotation.Lazy;
 @Conditional(ConditionalOnCamelContextAndAutoConfigurationBeans.class)
 
@EnableConfigurationProperties({ComponentConfigurationProperties.class,ExecComponentConfiguration.class})
 @ConditionalOnHierarchicalProperties({"camel.component", 
"camel.component.exec"})
-@AutoConfigureAfter(CamelAutoConfiguration.class)
+@AutoConfigureAfter({CamelAutoConfiguration.class, 
ExecComponentConverter.class})
 public class ExecComponentAutoConfiguration {
 
     @Autowired
diff --git 
a/components-starter/camel-exec-starter/src/main/java/org/apache/camel/component/exec/springboot/ExecComponentConfiguration.java
 
b/components-starter/camel-exec-starter/src/main/java/org/apache/camel/component/exec/springboot/ExecComponentConfiguration.java
index eb7f005be9a..2ce6e0a2df9 100644
--- 
a/components-starter/camel-exec-starter/src/main/java/org/apache/camel/component/exec/springboot/ExecComponentConfiguration.java
+++ 
b/components-starter/camel-exec-starter/src/main/java/org/apache/camel/component/exec/springboot/ExecComponentConfiguration.java
@@ -16,6 +16,8 @@
  */
 package org.apache.camel.component.exec.springboot;
 
+import org.apache.camel.component.exec.ExecBinding;
+import org.apache.camel.component.exec.ExecCommandExecutor;
 import org.apache.camel.spring.boot.ComponentConfigurationPropertiesCommon;
 import org.springframework.boot.context.properties.ConfigurationProperties;
 
@@ -45,6 +47,24 @@ public class ExecComponentConfiguration
      * and prolong the total processing time of the processing.
      */
     private Boolean lazyStartProducer = false;
+    /**
+     * The timeout, in milliseconds, after which the executable should be
+     * terminated. If execution has not completed within the timeout, the
+     * component will send a termination request.
+     */
+    private Long timeout;
+    /**
+     * The directory in which the command should be executed. If null, the
+     * working directory of the current process will be used.
+     */
+    private String workingDir;
+    /**
+     * Whether to allow to use Camel headers or not (default false). Enabling
+     * this allows to specify dynamic command line arguments via message 
header.
+     * However this can be seen as a potential security vulnerability if the
+     * header is coming from a malicious user, so use this with care.
+     */
+    private Boolean allowControlHeaders = false;
     /**
      * Whether autowiring is enabled. This is used for automatic autowiring
      * options (the option must be marked as autowired) by looking up in the
@@ -54,6 +74,20 @@ public class ExecComponentConfiguration
      * etc.
      */
     private Boolean autowiredEnabled = true;
+    /**
+     * To use a custom org.apache.commons.exec.ExecBinding for advanced
+     * use-cases. The option is a org.apache.camel.component.exec.ExecBinding
+     * type.
+     */
+    private ExecBinding binding;
+    /**
+     * To use a custom org.apache.commons.exec.ExecCommandExecutor that
+     * customizes the command execution. The default command executor utilizes
+     * the commons-exec library, which adds a shutdown hook for every executed
+     * command. The option is a
+     * org.apache.camel.component.exec.ExecCommandExecutor type.
+     */
+    private ExecCommandExecutor commandExecutor;
 
     public Boolean getLazyStartProducer() {
         return lazyStartProducer;
@@ -63,6 +97,30 @@ public class ExecComponentConfiguration
         this.lazyStartProducer = lazyStartProducer;
     }
 
+    public Long getTimeout() {
+        return timeout;
+    }
+
+    public void setTimeout(Long timeout) {
+        this.timeout = timeout;
+    }
+
+    public String getWorkingDir() {
+        return workingDir;
+    }
+
+    public void setWorkingDir(String workingDir) {
+        this.workingDir = workingDir;
+    }
+
+    public Boolean getAllowControlHeaders() {
+        return allowControlHeaders;
+    }
+
+    public void setAllowControlHeaders(Boolean allowControlHeaders) {
+        this.allowControlHeaders = allowControlHeaders;
+    }
+
     public Boolean getAutowiredEnabled() {
         return autowiredEnabled;
     }
@@ -70,4 +128,20 @@ public class ExecComponentConfiguration
     public void setAutowiredEnabled(Boolean autowiredEnabled) {
         this.autowiredEnabled = autowiredEnabled;
     }
+
+    public ExecBinding getBinding() {
+        return binding;
+    }
+
+    public void setBinding(ExecBinding binding) {
+        this.binding = binding;
+    }
+
+    public ExecCommandExecutor getCommandExecutor() {
+        return commandExecutor;
+    }
+
+    public void setCommandExecutor(ExecCommandExecutor commandExecutor) {
+        this.commandExecutor = commandExecutor;
+    }
 }
\ No newline at end of file
diff --git 
a/components-starter/camel-exec-starter/src/main/java/org/apache/camel/component/exec/springboot/ExecComponentConverter.java
 
b/components-starter/camel-exec-starter/src/main/java/org/apache/camel/component/exec/springboot/ExecComponentConverter.java
new file mode 100644
index 00000000000..d5d6ab5b1f3
--- /dev/null
+++ 
b/components-starter/camel-exec-starter/src/main/java/org/apache/camel/component/exec/springboot/ExecComponentConverter.java
@@ -0,0 +1,65 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.camel.component.exec.springboot;
+
+import java.util.LinkedHashSet;
+import java.util.Set;
+import org.springframework.beans.factory.annotation.Autowired;
+import 
org.springframework.boot.context.properties.ConfigurationPropertiesBinding;
+import org.springframework.context.ApplicationContext;
+import org.springframework.context.annotation.Configuration;
+import org.springframework.core.convert.TypeDescriptor;
+import org.springframework.core.convert.converter.GenericConverter;
+import org.springframework.stereotype.Component;
+
+/**
+ * Generated by camel-package-maven-plugin - do not edit this file!
+ */
+@Configuration(proxyBeanMethods = false)
+@ConfigurationPropertiesBinding
+@Component
+public class ExecComponentConverter implements GenericConverter {
+
+    @Autowired
+    private ApplicationContext applicationContext;
+
+    public Set<ConvertiblePair> getConvertibleTypes() {
+        Set<ConvertiblePair> answer = new LinkedHashSet<>();
+        answer.add(new ConvertiblePair(String.class, 
org.apache.camel.component.exec.ExecBinding.class));
+        answer.add(new ConvertiblePair(String.class, 
org.apache.camel.component.exec.ExecCommandExecutor.class));
+        return answer;
+    }
+
+    public Object convert(
+            Object source,
+            TypeDescriptor sourceType,
+            TypeDescriptor targetType) {
+        if (source == null) {
+            return null;
+        }
+        String ref = source.toString();
+        if (!ref.startsWith("#")) {
+            return null;
+        }
+        ref = ref.startsWith("#bean:") ? ref.substring(6) : ref.substring(1);
+        switch (targetType.getName()) {
+            case "org.apache.camel.component.exec.ExecBinding": return 
applicationContext.getBean(ref, 
org.apache.camel.component.exec.ExecBinding.class);
+            case "org.apache.camel.component.exec.ExecCommandExecutor": return 
applicationContext.getBean(ref, 
org.apache.camel.component.exec.ExecCommandExecutor.class);
+        }
+        return null;
+    }
+}
\ No newline at end of file
diff --git 
a/components-starter/camel-exec-starter/src/main/resources/META-INF/spring/org.springframework.boot.autoconfigure.AutoConfiguration.imports
 
b/components-starter/camel-exec-starter/src/main/resources/META-INF/spring/org.springframework.boot.autoconfigure.AutoConfiguration.imports
index b5f412aa5fa..fb7ba1f1115 100644
--- 
a/components-starter/camel-exec-starter/src/main/resources/META-INF/spring/org.springframework.boot.autoconfigure.AutoConfiguration.imports
+++ 
b/components-starter/camel-exec-starter/src/main/resources/META-INF/spring/org.springframework.boot.autoconfigure.AutoConfiguration.imports
@@ -15,4 +15,5 @@
 ## limitations under the License.
 ## ---------------------------------------------------------------------------
 
-org.apache.camel.component.exec.springboot.ExecComponentAutoConfiguration
\ No newline at end of file
+org.apache.camel.component.exec.springboot.ExecComponentAutoConfiguration
+org.apache.camel.component.exec.springboot.ExecComponentConverter

Reply via email to