No to all - its how its designed. For new lines you need to add that into the message. The message is appended as-is.
Take a look at the stream component that can keep the file open. http://camel.apache.org/stream On Mon, Oct 12, 2015 at 4:34 AM, Sashika <sashik...@gmail.com> wrote: > Hi, > > I have a use case to use camel file component as a producer to write files. > In fact to append incoming messages to single file. > > What I observed so far is camel does not keep the file open. Instead it > open the file, append the content and closes the file. This is repeated for > every single message received making it harder to deal with high message > rates. > > I have the following questions in this regard. Hope someone can help me out > > - Is this the correct behavior or can we keep the file open so whatever > the new messages coming in can be just appended > - Is this the right pattern for this use case?. Or else can I use > wiretap, or log pattern effectively instead of file? > - When appending to a single file, the file component does not impose a > new line. Instead it appends the new message in a single line. Any reason > for that? > - Also observed the very first message is missing in the appended file. > The file will contain only the second message and on wards. Is this a bug? > > Thanks in advance > Sashika -- Claus Ibsen ----------------- http://davsclaus.com @davsclaus Camel in Action 2nd edition: https://www.manning.com/books/camel-in-action-second-edition