camel-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From christian ohr <>
Subject Re: HL7 messages become unusable after convertBodyTo(String.class)
Date Fri, 24 Apr 2009 19:15:47 GMT


I guess the remark about the patch refers to the HL7 Decoder problem - I
haven't submitted one for the convertBodyTo() ... yet. 
The piece of code wasn't originally intended as patch, more of a proposal
how to resolve the issue. If the releases are not on Monday ;-) I'm
confident I can provide the full thing on time.


hzbarcea wrote:
> @Christian, the patch you submitted requires a bit of work to be  
> applied to Camel.  At least the "package bla;" needs to change, and  
> the apache license headers applied, a unit test and so forth.  I could  
> do this part if you don't have time.  However we would need a  sample  
> HL7 message that shows the problem as well.  I would appreciate if you  
> could address some of these issues and resubmit.
> We plan to release Camel 1.6.1 and 2.0-M2 next week, btw :)
> Cheers,
> Hadrian
> On Apr 24, 2009, at 12:09 PM, christian ohr wrote:
>> Hi, me again...
>> Another problem I came across:
>> when reading HL7 messages e.g. from a stream, they become unusable  
>> after
>> running though a convertBodyTo(String.class) converter for further
>> processing.
>> The reason is that the converter uses the readLine() method of a
>> BufferedReader which splits up at "\r" and/or "\n" characters, but  
>> then the
>> string is always aggregated with "\n". As HL7 segments MUST be  
>> separated by
>> "\r", you need to convert all "\n" into "\r" afterwards, which is  
>> pretty
>> annoying. Please also see
>> I will have a closer look at it and see if I can provide a patch next
>> week....
>> cheers
>> Christian
>> -- 
>> View this message in context:
>> Sent from the Camel - Users mailing list archive at

View this message in context:
Sent from the Camel - Users mailing list archive at

View raw message