Camel fails to rename/delete the source file

2022-03-07 Thread Reto Peter
I am trying to convert an EDIFACT file into an XML file. The conversion is done with smooks. The conversion works fine. The target file is successfully converted and also written to the disk. The problem arises after when Camel try to move the file to the .camel subdir. The source file is copied t

Re: Camel fails to rename/delete the source file

2022-03-07 Thread Claus Ibsen
Hi That is because you do something in the custom processor that locks the file. You need to make sure you close the file / input stream etc that you may be doing. On Mon, Mar 7, 2022 at 9:14 AM Reto Peter wrote: > > I am trying to convert an EDIFACT file into an XML file. > > The conversion is

RE: Camel fails to rename/delete the source file

2022-03-07 Thread Reto Peter
Hi Claus Thanks for the fast answer! Well, this is the smooks processor, not my custom processor. Does that mean, the Camel file component does give the file access to the next component and not just the file content? Sorry, I am a Camel beginner. Regards Reto -Original Message- From: C

Re: Camel fails to rename/delete the source file

2022-03-07 Thread Claus Ibsen
Hi Yes it depends what smooks does, but you can change the message body from a file / input stream and read it into memory as a string and then give that to smooks. Then smooks dont have anything to worry about closing file handles / resources So try add before the processor .convertBodyTo(Strin

RE: Camel fails to rename/delete the source file

2022-03-07 Thread Reto Peter
Hi Super. That works!!! -Original Message- From: Claus Ibsen Sent: Monday, March 7, 2022 6:03 PM To: users@camel.apache.org Subject: Re: Camel fails to rename/delete the source file Hi Yes it depends what smooks does, but you can change the message body from a file / input stream and

[ANNOUNCEMENT] Apache Camel K 1.8.2 released

2022-03-07 Thread Andrea Cosentino
The Camel community announces the immediate availability of Apache Camel K 1.8.2. You can find more information in the release notes[1]. The artifacts are published and ready for you to download either from the Apache mirrors or from the Github repository [1]. Many thanks to all who made this rel