Hi Anton,

And just to be sure this is a Camel CDI problem, could you add a:

convertBodyTo(SupportRequest.class)

in your Camel route, like:

public void configure() {

   from(ticketEndpoint) // returns a Ticket
   .convertBodyTo(SupportRequest.class)
   .to("jpa:my.domain.SupportRequest&persistenceUnit=camel"); // attempt
to persist SupportRequest
   }

and give that a try.

Thanks,

Antonin

> On 13 Apr 2016, at 12:58, Antonin Stefanutti <anto...@stefanutti.fr> wrote:
> 
> Hi Anto,
> 
> Type converter annotated with @Converter are automatically discovered by 
> Camel CDI and added to the Camel context.
> 
> You can find an example here: 
> https://github.com/apache/camel/blob/337a6756480354afea7531a1a4216de9d232f211/components/camel-cdi/src/test/java/org/apache/camel/cdi/converter/InjectedTypeConverter.java#L27
> 
> So your type converter class just needs to be a class discovered by the CDI 
> container as documented in 
> http://docs.jboss.org/cdi/spec/1.2/cdi-spec.html#type_discovery_steps.
> 
> Could you activate Weld DEBUG log and provide us the container bootstrap logs?
> 
> Antonin
> 
>> On 13 Apr 2016, at 12:54, Anton <kurren...@gmail.com> wrote:
>> 
>> Hi John
>> 
>> Thanks for your reply.
>> 
>> Im using Weld.
>> Im using Camel 2.17.0
>> 
>> My beans.xml looks like this:
>> 
>> <?xml version="1.0" encoding="UTF-8"?>
>> <beans/>
>> 
>> 
>> I tried adding AppScoped, but it did not make any difference.
> 

Reply via email to