[ 
https://issues.apache.org/jira/browse/CAMEL-16906?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17419841#comment-17419841
 ] 

Claus Ibsen commented on CAMEL-16906:
-------------------------------------

Okay we should revert this as this causes unforseen problem because we use 
fallback converters in those json libraries. So that means they end up taking 
any kind of Java object and convert to InputStream. Even objects the json 
parser would not support.

> Platform-http components fail when using unmarshal
> --------------------------------------------------
>
>                 Key: CAMEL-16906
>                 URL: https://issues.apache.org/jira/browse/CAMEL-16906
>             Project: Camel
>          Issue Type: Bug
>          Components: camel-platform-http-vertx
>    Affects Versions: 3.11.1, 3.12.0
>            Reporter: Pasquale Congiusti
>            Assignee: Pasquale Congiusti
>            Priority: Major
>             Fix For: 3.11.3, 3.12.0
>
>
> When we run a route which is using platform-http component and we try to 
> unmarshal to json (and I suspect also any other dataformat), there is a 
> failure due to a missing conversion type.
> For example:
> {code}
>     from("platform-http:/hello?httpMethodRestrict=GET").
>       setBody(simple("{\"hello\": \"world\"}"))
>       .unmarshal().json();
> {code}
> Will fail because there is a [mandatory conversion from Map to 
> ByteBuffer|https://github.com/apache/camel/blob/main/components/camel-platform-http-vertx/src/main/java/org/apache/camel/component/platform/http/vertx/VertxPlatformHttpSupport.java#L183]
>  that is failing.
> {code}
> [1] 2021-08-31 13:41:58,676 ERROR [io.qua.ver.htt.run.QuarkusErrorHandler] 
> (vert.x-eventloop-thread-1) HTTP Request to /hello failed, error id: 
> 3ea4fdb8-931c-4d59-b8e6-376dc6a34e09-1: 
> org.apache.camel.NoTypeConversionAvailableException: No type converter 
> available to convert from type: java.util.LinkedHashMap to the required type: 
> java.nio.ByteBuffer with value {hello=world}
> {code}



--
This message was sent by Atlassian Jira
(v8.3.4#803005)

Reply via email to