You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@camel.apache.org by "astelmashenko (via GitHub)" <gi...@apache.org> on 2023/02/02 14:02:24 UTC

[GitHub] [camel-k] astelmashenko opened a new issue, #4027: Canelk does not automatically add dependency JacksonXML

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

   Here is a route:
   ```yaml
   - route:
       from:
         uri: rest:post:/
         steps:
           - to:
               uri: log:info
           - unmarshal:
               jackson-xml:
                 unmarshalType: java.util.Map
           - marshal:
               json:
                 library: Jackson
           - setHeader:
               name: ce-source
               expression:
                 constant:
                   expression: camel-integration
           - setHeader:
               name: ce-type
               expression:
                 constant:
                   expression: camel.integration.event
           - setHeader:
               name: ce-id
               expression:
                 simple:
                   expression: ${date:now}
           - to:
               uri: log:info
               parameters:
                 showAll: false
                 showHeaders: true
                 showBody: true
   ```
   
   It fails to load with error:
   ```
   Unmarshal[org.apache.camel.model.dataformat.JacksonXMLDataFormat@3f4f5330] <<< in route: Route(route1)[From[rest:post:/] -> [To[http://transform-orde/... because of Data format 'jacksonXml' could not be created. Ensure that the data format is valid and the associated Camel component is present on the classpath
   ```
   
   On JacksonXML page there is dependency section https://camel.apache.org/components/3.18.x/dataformats/jacksonXml-dataformat.html#_dependencies it says that we have to add it to use it. 
   
   Few questions:
   - is it a bug?
   - if it is by design, then how can we pre-configure default route-dependencies? we use operator, and we allow customer provide only yaml files and do not allow do `kamel run`
   


-- 
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-unsubscribe@camel.apache.org.apache.org

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


[GitHub] [camel-k] github-actions[bot] commented on issue #4027: Camel K does not automatically add dependency JacksonXML

Posted by "github-actions[bot] (via GitHub)" <gi...@apache.org>.
github-actions[bot] commented on issue #4027:
URL: https://github.com/apache/camel-k/issues/4027#issuecomment-1535550860

   This issue has been automatically marked as stale due to 90 days of inactivity. 
   It will be closed if no further activity occurs within 15 days.
   If you think that’s incorrect or the issue should never stale, please simply write any comment.
   Thanks for your contributions!


-- 
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-unsubscribe@camel.apache.org

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


[GitHub] [camel-k] squakez commented on issue #4027: Camel K does not automatically add dependency JacksonXML

Posted by "squakez (via GitHub)" <gi...@apache.org>.
squakez commented on issue #4027:
URL: https://github.com/apache/camel-k/issues/4027#issuecomment-1413832079

   You're right, I've just checked the yaml inspector and we only discover `json`. We have limited inspection capability right now, so, the only possibility is to include this manually. See #1266 


-- 
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-unsubscribe@camel.apache.org

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


[GitHub] [camel-k] astelmashenko commented on issue #4027: Camel K does not automatically add dependency JacksonXML

Posted by "astelmashenko (via GitHub)" <gi...@apache.org>.
astelmashenko commented on issue #4027:
URL: https://github.com/apache/camel-k/issues/4027#issuecomment-1413819433

   I tried jacksonxml does not work, it results in:
   ```
   Unsupported field: jacksonxml
    in file:/etc/camel/sources/camel-k-embedded-flow.yaml, line 8, column 13:
                   unmarshalType: java.util.Map
   ```
   If I use jackson-xml and jacksonXml it works the same: there is no dependency if I do not specify it manually. List of dependencies _without_ `-d camel:jacksonxml`  is:
   ```
     dependencies:
     - camel:core
     - camel:jackson
     - camel:log
     - camel:rest
     - mvn:org.apache.camel.k:camel-k-runtime
     - mvn:org.apache.camel.quarkus:camel-quarkus-yaml-dsl
   ``` 


-- 
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-unsubscribe@camel.apache.org

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


[GitHub] [camel-k] squakez commented on issue #4027: Camel K does not automatically add dependency JacksonXML

Posted by "squakez (via GitHub)" <gi...@apache.org>.
squakez commented on issue #4027:
URL: https://github.com/apache/camel-k/issues/4027#issuecomment-1413881523

   Yes, the way we manage dependencies is different. We are already discussing how to harmonize that, thanks for the feedback!


-- 
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-unsubscribe@camel.apache.org

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


[GitHub] [camel-k] github-actions[bot] closed issue #4027: Camel K does not automatically add dependency JacksonXML

Posted by "github-actions[bot] (via GitHub)" <gi...@apache.org>.
github-actions[bot] closed issue #4027: Camel K does not automatically add dependency JacksonXML
URL: https://github.com/apache/camel-k/issues/4027


-- 
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-unsubscribe@camel.apache.org

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


[GitHub] [camel-k] astelmashenko commented on issue #4027: Camel K does not automatically add dependency JacksonXML

Posted by "astelmashenko (via GitHub)" <gi...@apache.org>.
astelmashenko commented on issue #4027:
URL: https://github.com/apache/camel-k/issues/4027#issuecomment-1413831105

   One more thing to take into account, it does not reproduce with jbang, only on k8s env.


-- 
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-unsubscribe@camel.apache.org

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


[GitHub] [camel-k] squakez commented on issue #4027: Camel K does not automatically add dependency JacksonXML

Posted by "squakez (via GitHub)" <gi...@apache.org>.
squakez commented on issue #4027:
URL: https://github.com/apache/camel-k/issues/4027#issuecomment-1413806219

   I think it's a syntax error: try with `jacksonxml` instead of `jackson-xml`.


-- 
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-unsubscribe@camel.apache.org

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


[GitHub] [camel-k] tadayosi commented on issue #4027: Camel K does not automatically add dependency JacksonXML

Posted by "tadayosi (via GitHub)" <gi...@apache.org>.
tadayosi commented on issue #4027:
URL: https://github.com/apache/camel-k/issues/4027#issuecomment-1414967849

   @astelmashenko As Pasquale explained, it's the current limitation in the source inspection capability of Camel K.
   
   As a workaround, you can explicitly add the dependency to your integraion like this:
   ```
   kamel run -d camel:jacksonxml <your integration>
   ```


-- 
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-unsubscribe@camel.apache.org

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


[GitHub] [camel-k] astelmashenko commented on issue #4027: Camel K does not automatically add dependency JacksonXML

Posted by "astelmashenko (via GitHub)" <gi...@apache.org>.
astelmashenko commented on issue #4027:
URL: https://github.com/apache/camel-k/issues/4027#issuecomment-1415559187

   @tadayosi , thanks that's exactly how we fixed it.


-- 
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-unsubscribe@camel.apache.org

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