dmitriipisarev opened a new issue, #6213:
URL: https://github.com/apache/camel-k/issues/6213

   ### What happened?
   
   I'm trying to use custom servlet component 'servlet-custom' in xml route 
definition 
   
   ```yaml
   apiVersion: camel.apache.org/v1
   kind: Integration
   metadata:
     annotations:
       camel.apache.org/operator.id: camel-k
     creationTimestamp: null
     name: custom-servlet
   spec:
     sources:
     - content: |-
         <?xml version="1.0" encoding="UTF-8"?>
         <routes xmlns="http://camel.apache.org/schema/spring";>
         <route>
             <from 
uri="servlet-custom:testt?chunked=true&amp;httpMethodRestrict=GET&amp;httpBinding=handlingHttpBinding&amp;tagsProvider=#68ddb568-2f56-4366-b700-ea2f6148a1d2"/>
             <step id="68ddb568-2f56-4366-b700-ea2f6148a1d2">
             ...
             </step>
             <toD uri="direct:1ff34788-2e6a-49ae-9e70-7718e71c868c"/>
         </route>
         <route>
             <from uri="direct:1ff34788-2e6a-49ae-9e70-7718e71c868c"/>
             ...
             <process id="2e616193-2916-4977-b808-732e0bb0680b" 
ref="myProcessor"/>
         </route>
         </routes>
       name: custom-servlet.xml
     traits:
       builder:
         baseImage: host.docker.internal:5000/my-app-image:15
       jvm:
         jar: /app/my-runnable.jar
         options: ['-Dspring.profiles.active=development', 
'-Dfile.encoding=UTF-8', '-Xmx832m']
       kamelets:
         enabled: false  
   status: {}
   
   ```
   
   and getting the following error:
   
   ```
   Cannot reconcile Integration custom-servlet: error during trait 
customization: dependencies trait execution failed: component not found for uri 
"servlet-custom:testt?chunked=true&httpMethodRestrict=GET&httpBinding=handlingHttpBinding&tagsProvider=#68ddb568-2f56-4366-b700-ea2f6148a1d2"
 in camel catalog runtime version 3.15.3
   ```
   
   - Custom component `servlet-custom` is included to /app/my-runnable.jar 
(which starts correctly if `servlet-custom` is absent in DSL)
   - If I try to add custom component as a dependency - i see that xml DSL 
validation starts BEFORE resolving maven dependencies
   ```yaml
   ...
   spec:
     dependencies:
     - mvn:my.camel:custom-components:0.2
   ...
   ```
   
   The question: how camel-k should be configured to use custom components 
declared in base image
   
   ### Steps to reproduce
   
   _No response_
   
   ### Relevant log output
   
   ```shell
   
   ```
   
   ### Camel K version
   
   _No response_


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@camel.apache.org.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org

Reply via email to