BTW this is what the RFC says about this scenario: *Any HTTP/1.1 message containing an entity-body SHOULD include a > Content-Type header field defining the media type of that body. If and only > if the media type is not given by a Content-Type field, the recipient MAY > attempt to guess the media type via inspection of its content and/or the > name extension(s) of the URI used to identify the resource. If the media > type remains unknown, the recipient SHOULD treat it as type > "application/octet-stream".*
This is what we I have already done for response handling in the NHTTP transport (and we did it in a configurable manner). Earlier it used to pass an empty payload to the client when the responses did not have a Content-Type header. May be we should do the same for the requests? Thanks, Hiranya On Tue, Feb 16, 2010 at 9:49 AM, Hiranya Jayathilaka <[email protected]>wrote: > > > On Tue, Feb 16, 2010 at 6:24 AM, Ruwan Linton <[email protected]>wrote: > >> I think Synapse nhttp transport defaults to application/octet-stream which >> will result in the message to be built as binary, I think Hiranya did some >> fix around this sometime back, Hiranya*?? >> * > > > Nope. That was for responses only. > > Thanks, > Hiranya > > >> * >> Thanks, >> Ruwan >> * >> >> On Mon, Feb 15, 2010 at 5:22 PM, Asankha C. Perera <[email protected]>wrote: >> >>> Supun Kamburugamuva wrote: >>> > Does HTTPCore add a content type in case there is no Content-Type >>> > header in the request message? >>> No, I do not think it should either >>> >>> cheers >>> asankha >>> >>> -- >>> Asankha C. Perera >>> AdroitLogic, http://adroitlogic.org >>> >>> http://esbmagic.blogspot.com >>> >>> >>> >>> >>> >>> --------------------------------------------------------------------- >>> To unsubscribe, e-mail: [email protected] >>> For additional commands, e-mail: [email protected] >>> >>> >> >> >> -- >> Ruwan Linton >> Technical Lead & Product Manager; WSO2 ESB; http://wso2.org/esb >> >> WSO2 Inc.; http://wso2.org >> email: [email protected]; cell: +94 77 341 3097 >> blog: http://ruwansblog.blogspot.com >> > > > > -- > Hiranya Jayathilaka > Software Engineer; > > WSO2 Inc.; http://wso2.org > E-mail: [email protected]; Mobile: +94 77 633 3491 > Blog: http://techfeast-hiranya.blogspot.com > -- Hiranya Jayathilaka Software Engineer; WSO2 Inc.; http://wso2.org E-mail: [email protected]; Mobile: +94 77 633 3491 Blog: http://techfeast-hiranya.blogspot.com
