json - Apache Camel HTTP / HTTP4 ignores Content-Type header -


i'm trying send http call through apache camel using camel-http.

when set header content-type ignores header , doesn't include in call.

i have tried set header has follows:

exchange.getout().setheader('content-type', 'application/json'),

and

exchange.getout().setheader(exchange.content_type, 'application/json');

i have tried using camel-http , camel-http4 , doesn't work of them.

since have to, mandatorily, send content-type header, how can force camel-http include it?


note: i'm setting other headers same way correctly send call, it's content-type 1 doesn't work

you need following set content-type:

<setheader headername="content-type">          <constant>application/json</constant>  </setheader> 

this work set content-type.


Comments

Popular posts from this blog

javascript - AngularJS custom datepicker directive -

javascript - jQuery date picker - Disable dates after the selection from the first date picker -