You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@servicemix.apache.org by JanReynaerts <ja...@urbidata.nl> on 2008/03/18 14:43:30 UTC

Preserving or configuring content-type of http-header

I have a servicemix configuration with 3 components: 
- a http-consumer component
- a http-provider component
- a jsr-181 component. In the jsr181 component I use a proxy, that exposes a
wsdl (generated by XFire) 

Messages are sent from the http-consumer component through the jsr-181
component to the http-provider component. I want to preserve the
content-type from the incoming message. To do this I use the parameters
wantHeadersFromHttpIntoExchange and
wantContentTypeHeaderFromExchangeIntoHttpRequest. However in the
jsr181-component the content-type gets lost. Is it possible to preserve the
content-type of a message during his route through servicemix?

Or if not, is it possible to configure the content-type in a http-provider
component? 

Regards, Jan Reynaerts



-- 
View this message in context: http://www.nabble.com/Preserving-or-configuring-content-type-of-http-header-tp16121496s12049p16121496.html
Sent from the ServiceMix - User mailing list archive at Nabble.com.


Re: Preserving or configuring content-type of http-header

Posted by Thomas Termin <tt...@blue-elephant-systems.com>.
You could open a jira issue and attach a patch, if you don't mind.

Cheers
Thomas

JanReynaerts wrote:
> Thanks for your quick answer. I need it as soon as possible. The nicest
> solution is when the content-type is preserved by the jsr-181 component.
> 
> For the time being, I copied the code of the
> servicemix-http-3.2.1-installer.zip, and I changed the content-type
> hardcoded, but this of course is just a work-around.
> 
> The http-component can be made configurable I thought by introducing a new
> parameter fi "SetContentType". If the parameter isn't present the
> http-component works in the old way, so nothing changes for the existing
> http-components. And it will only be a fix for those http-components that
> use this new parameter( and so not for all).
> Regards, Jan Reynaerts
> 
> 
> 
> tterm wrote:
> 
>>JanReynaerts wrote:
>>
>>>I have a servicemix configuration with 3 components: 
>>>- a http-consumer component
>>>- a http-provider component
>>>- a jsr-181 component. In the jsr181 component I use a proxy, that
>>>exposes a
>>>wsdl (generated by XFire) 
>>>
>>>Messages are sent from the http-consumer component through the jsr-181
>>>component to the http-provider component. I want to preserve the
>>>content-type from the incoming message. To do this I use the parameters
>>>wantHeadersFromHttpIntoExchange and
>>>wantContentTypeHeaderFromExchangeIntoHttpRequest. However in the
>>>jsr181-component the content-type gets lost. Is it possible to preserve
>>>the
>>>content-type of a message during his route through servicemix?
>>
>>It should in my opinion. If I will find some time, I will look into
>>this. Sorry that I didn't answer last time again.
>>
>>
>>>Or if not, is it possible to configure the content-type in a
>>>http-provider
>>>component? 
>>
>>It is not but I could implement this. But it is fix then for all
>>http-provider endpoints.
>>
>>But maybe the others can say something, why the porperties get lost in
>>this component. How fast do you need this?
>>
>>Cheers
>>Thomas
>>
>>
>>
>>
>>
>>-- 
>>Thomas Termin
>>_______________________________
>>blue elephant systems GmbH
>>Wollgrasweg 49
>>D-70599 Stuttgart
>>
>>Tel    :  (+49) 0711 - 45 10 17 676
>>Fax    :  (+49) 0711 - 45 10 17 573
>>WWW    :  http://www.blue-elephant-systems.com
>>Email  :  Thomas.Termin@blue-elephant-systems.com
>>
>>blue elephant systems GmbH
>>Firmensitz      : Wollgrasweg 49, D-70599 Stuttgart
>>Registergericht : Amtsgericht Stuttgart, HRB 24106
>>Geschäftsführer : Holger Dietrich, Thomas Gentsch, Joachim Hoernle
>>
>>
>>
> 
> 


-- 
Thomas Termin
_______________________________
blue elephant systems GmbH
Wollgrasweg 49
D-70599 Stuttgart

Tel    :  (+49) 0711 - 45 10 17 676
Fax    :  (+49) 0711 - 45 10 17 573
WWW    :  http://www.blue-elephant-systems.com
Email  :  Thomas.Termin@blue-elephant-systems.com

blue elephant systems GmbH
Firmensitz      : Wollgrasweg 49, D-70599 Stuttgart
Registergericht : Amtsgericht Stuttgart, HRB 24106
Geschäftsführer : Holger Dietrich, Thomas Gentsch, Joachim Hoernle


Re: Preserving or configuring content-type of http-header

Posted by JanReynaerts <ja...@urbidata.nl>.
Thanks for your quick answer. I need it as soon as possible. The nicest
solution is when the content-type is preserved by the jsr-181 component.

For the time being, I copied the code of the
servicemix-http-3.2.1-installer.zip, and I changed the content-type
hardcoded, but this of course is just a work-around.

The http-component can be made configurable I thought by introducing a new
parameter fi "SetContentType". If the parameter isn't present the
http-component works in the old way, so nothing changes for the existing
http-components. And it will only be a fix for those http-components that
use this new parameter( and so not for all).
Regards, Jan Reynaerts



tterm wrote:
> 
> JanReynaerts wrote:
>> I have a servicemix configuration with 3 components: 
>> - a http-consumer component
>> - a http-provider component
>> - a jsr-181 component. In the jsr181 component I use a proxy, that
>> exposes a
>> wsdl (generated by XFire) 
>> 
>> Messages are sent from the http-consumer component through the jsr-181
>> component to the http-provider component. I want to preserve the
>> content-type from the incoming message. To do this I use the parameters
>> wantHeadersFromHttpIntoExchange and
>> wantContentTypeHeaderFromExchangeIntoHttpRequest. However in the
>> jsr181-component the content-type gets lost. Is it possible to preserve
>> the
>> content-type of a message during his route through servicemix?
> It should in my opinion. If I will find some time, I will look into
> this. Sorry that I didn't answer last time again.
> 
>> Or if not, is it possible to configure the content-type in a
>> http-provider
>> component? 
> It is not but I could implement this. But it is fix then for all
> http-provider endpoints.
> 
> But maybe the others can say something, why the porperties get lost in
> this component. How fast do you need this?
> 
> Cheers
> Thomas
> 
> 
> 
> 
> 
> -- 
> Thomas Termin
> _______________________________
> blue elephant systems GmbH
> Wollgrasweg 49
> D-70599 Stuttgart
> 
> Tel    :  (+49) 0711 - 45 10 17 676
> Fax    :  (+49) 0711 - 45 10 17 573
> WWW    :  http://www.blue-elephant-systems.com
> Email  :  Thomas.Termin@blue-elephant-systems.com
> 
> blue elephant systems GmbH
> Firmensitz      : Wollgrasweg 49, D-70599 Stuttgart
> Registergericht : Amtsgericht Stuttgart, HRB 24106
> Geschäftsführer : Holger Dietrich, Thomas Gentsch, Joachim Hoernle
> 
> 
> 

-- 
View this message in context: http://www.nabble.com/Preserving-or-configuring-content-type-of-http-header-tp16121496s12049p16121960.html
Sent from the ServiceMix - User mailing list archive at Nabble.com.


Re: Preserving or configuring content-type of http-header

Posted by Thomas Termin <tt...@blue-elephant-systems.com>.
JanReynaerts wrote:
> I have a servicemix configuration with 3 components: 
> - a http-consumer component
> - a http-provider component
> - a jsr-181 component. In the jsr181 component I use a proxy, that exposes a
> wsdl (generated by XFire) 
> 
> Messages are sent from the http-consumer component through the jsr-181
> component to the http-provider component. I want to preserve the
> content-type from the incoming message. To do this I use the parameters
> wantHeadersFromHttpIntoExchange and
> wantContentTypeHeaderFromExchangeIntoHttpRequest. However in the
> jsr181-component the content-type gets lost. Is it possible to preserve the
> content-type of a message during his route through servicemix?
It should in my opinion. If I will find some time, I will look into
this. Sorry that I didn't answer last time again.

> Or if not, is it possible to configure the content-type in a http-provider
> component? 
It is not but I could implement this. But it is fix then for all
http-provider endpoints.

But maybe the others can say something, why the porperties get lost in
this component. How fast do you need this?

Cheers
Thomas





-- 
Thomas Termin
_______________________________
blue elephant systems GmbH
Wollgrasweg 49
D-70599 Stuttgart

Tel    :  (+49) 0711 - 45 10 17 676
Fax    :  (+49) 0711 - 45 10 17 573
WWW    :  http://www.blue-elephant-systems.com
Email  :  Thomas.Termin@blue-elephant-systems.com

blue elephant systems GmbH
Firmensitz      : Wollgrasweg 49, D-70599 Stuttgart
Registergericht : Amtsgericht Stuttgart, HRB 24106
Geschäftsführer : Holger Dietrich, Thomas Gentsch, Joachim Hoernle