Hi Brad

It's not surprise that RabbitMQ cannot natively send the Serializable
objects, as the server is not wrote in Java.
Please feel free to send a PR if you have something to show us.



Willem Jiang

Red Hat, Inc.

Web: http://www.redhat.com
Blog: http://willemjiang.blogspot.com (English)
          http://jnn.iteye.com  (Chinese)
Twitter: willemjiang
Weibo: 姜宁willem

On Fri, Apr 10, 2015 at 11:32 PM, unleashed85 <ca...@bradreitmeyer.com>
wrote:

> Williem,
> Would you like me to go ahead and move those classes? If so is it fine for
> the tests to stay in the components or would I also need a set of tests in
> camel-core?
>
>
> I'm running into another issue I could use some advice on. I'm trying to
> make the functionally equivalent to the camel-jms component which includes
> passing exceptions through. For example if the consumer side throws a
> NullPointerException I want the consumer to serialize the exception so the
> NullPointerException gets set on the exchange after the reply. My problem
> is
> that the com.rabbitmq.client only accepts byte[] and camel's
> DefaultTypeConverter wont convert a Serializable object to a byte[]. Thus
> it
> throws a NoTypeConversionAvailableException.
>
> 1) It seems odd that the camel-rabbitmq component cant natively send
> objects
> that implement Serializable. Am I missing a simple setting somewhere?
> 2) To make throwing exceptions work I ended up just writing the exception
> out to a byte[] with a ByteArrayOutputStream / ObjectOutputStream and
> setting a header to indicate there was an exception. Then when it gets a
> reply it checks that header and uses a ByteArrayInputStream /
> ObjectInputStream to deserialize. While this seems to work well, I assume
> there is a more generic way to do this?
>
> Thanks,
> Brad
>
>
>
> --
> View this message in context:
> http://camel.465427.n5.nabble.com/Adding-inOut-support-to-the-RabbitMQ-component-tp5764656p5765607.html
> Sent from the Camel Development mailing list archive at Nabble.com.
>

Reply via email to