No responses -- Am I doing this completely wrong? 

    On Friday, June 8, 2018 6:07 PM, Steve Hiller <sh...@bellsouth.net> wrote:
 

 Hi All,

I recently watched Claus' talk called "Developing cloud-ready Camel 
microservices". I am trying to do the following:

rest("/candidate")
  .post("applyx")
  .consumes(MediaType.APPLICATION_JSON_VALUE)
  .type(Candidate.class)
  .to("direct:passwordlessApply")
;


from("direct:passwordlessApply")
  .setExchangePattern(ExchangePattern.InOnly)
  .to("http4:{{service:candidate-service}}/api/candidate/applyx")
;


where {{service:candidate-service}} also consumes the Candidate class.

However, I am seeing the following exception:

org.apache.camel.InvalidPayloadException: No body available of type: 
java.io.InputStream but has value: 
com.rusa.adapter.mobile.candidate.domain.Candidate@58af86ed...
Caused by: [org.apache.camel.NoTypeConversionAvailableException - No type 
converter available to convert from type: 
com.rusa.adapter.mobile.candidate.domain.Candidate to the required type: 
java.io.InputStream with value 
com.rusa.adapter.mobile.candidate.domain.Candidate@58af86ed...
Caused by: org.apache.camel.NoTypeConversionAvailableException: No type 
converter available to convert from type: 
com.rusa.adapter.mobile.candidate.domain.Candidate to the required type: 
java.io.InputStream with value 
com.rusa.adapter.mobile.candidate.domain.Candidate@58af86ed

Any help is most appreciated.

Thanks,

Steve


   

Reply via email to