You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@camel.apache.org by sshiampp <ss...@gmail.com> on 2017/03/10 05:55:06 UTC

Intermittent issue, Camel-FTP : GenericFileOperationFailedException: Error writing file

I'm transferring some TXT files to a FTP location every 15 mins throught day.
It woks fine almost all times but sometimes I get
"org.apache.camel.component.file.GenericFileOperationFailedException: Error
writing file [Destination/directory/filename.txt]" and the file gets stuck
in processing directory. I analysed around 50 same types of error which came
in past and I'm not able to create any pattern why it's happening. I can
assure you guys that FTP location is fine and have no problem communicating
with it.

I'm thinking of upgrading to latest version, maybe it is fixed in later
versions but I have a large setup and we'll have to re-test every component
for impact analysis.
Anyone having any info on this issue ?



--
View this message in context: http://camel.465427.n5.nabble.com/Intermittent-issue-Camel-FTP-GenericFileOperationFailedException-Error-writing-file-tp5795212.html
Sent from the Camel - Users mailing list archive at Nabble.com.

Re: Intermittent issue, Camel-FTP : GenericFileOperationFailedException: Error writing file

Posted by sshivampp <ss...@gmail.com>.
I have configured the error handler but somehow the code doesn't land in
catch when this exception occurs and file gets stuck in "processing"
directory.

                           .doCatch(Exception.class)
                                .process(new Processor() {
                                    @Override
                                    public void process(Exchange exchange)
throws Exception {
                                       
                                    }
                                })
                                .to("sourceDirectory/error"))



--
View this message in context: http://camel.465427.n5.nabble.com/Intermittent-issue-Camel-FTP-GenericFileOperationFailedException-Error-writing-file-tp5795212p5795227.html
Sent from the Camel - Users mailing list archive at Nabble.com.

Re: Intermittent issue, Camel-FTP : GenericFileOperationFailedException: Error writing file

Posted by Claus Ibsen <cl...@gmail.com>.
Yes you can configure Camel's error handler to retry with the redelivery options

On Fri, Mar 10, 2017 at 8:44 AM, sshivampp <ss...@gmail.com> wrote:
> Thanks for quick reply !
> Sorry I missed to inform the version I'm using. It's 2.12.1.
>
> And about  "re-connect on each file".I will be having lots of files to
> process every 15 mins. I think reconnecting every time may create an extra
> overhead.
>
> I'm thinking of re-processing those files at my next run. Will it be good if
> I move my files back from "processing" or "error" directory to source
> directory.
>
> Can in any way Rollback strategy simplify my work here ?
>
> Please suggest.
>
>
>
> --
> View this message in context: http://camel.465427.n5.nabble.com/Intermittent-issue-Camel-FTP-GenericFileOperationFailedException-Error-writing-file-tp5795212p5795222.html
> Sent from the Camel - Users mailing list archive at Nabble.com.



-- 
Claus Ibsen
-----------------
http://davsclaus.com @davsclaus
Camel in Action 2: https://www.manning.com/ibsen2

Re: Intermittent issue, Camel-FTP : GenericFileOperationFailedException: Error writing file

Posted by sshivampp <ss...@gmail.com>.
Thanks for quick reply !
Sorry I missed to inform the version I'm using. It's 2.12.1.

And about  "re-connect on each file".I will be having lots of files to
process every 15 mins. I think reconnecting every time may create an extra
overhead.

I'm thinking of re-processing those files at my next run. Will it be good if
I move my files back from "processing" or "error" directory to source
directory.

Can in any way Rollback strategy simplify my work here ?

Please suggest.



--
View this message in context: http://camel.465427.n5.nabble.com/Intermittent-issue-Camel-FTP-GenericFileOperationFailedException-Error-writing-file-tp5795212p5795222.html
Sent from the Camel - Users mailing list archive at Nabble.com.

Re: Intermittent issue, Camel-FTP : GenericFileOperationFailedException: Error writing file

Posted by Claus Ibsen <cl...@gmail.com>.
Its hard to diagnose and find out the problem.

Maybe if you set disconnect=true to not reuse connections it would
force camel to re-connect on each file it writes, and maybe that
helps.

But upgrading to latest is always a good idea in such cases. As I
think you run on a very old Camel version.

On Fri, Mar 10, 2017 at 6:55 AM, sshiampp <ss...@gmail.com> wrote:
> I'm transferring some TXT files to a FTP location every 15 mins throught day.
> It woks fine almost all times but sometimes I get
> "org.apache.camel.component.file.GenericFileOperationFailedException: Error
> writing file [Destination/directory/filename.txt]" and the file gets stuck
> in processing directory. I analysed around 50 same types of error which came
> in past and I'm not able to create any pattern why it's happening. I can
> assure you guys that FTP location is fine and have no problem communicating
> with it.
>
> I'm thinking of upgrading to latest version, maybe it is fixed in later
> versions but I have a large setup and we'll have to re-test every component
> for impact analysis.
> Anyone having any info on this issue ?
>
>
>
> --
> View this message in context: http://camel.465427.n5.nabble.com/Intermittent-issue-Camel-FTP-GenericFileOperationFailedException-Error-writing-file-tp5795212.html
> Sent from the Camel - Users mailing list archive at Nabble.com.



-- 
Claus Ibsen
-----------------
http://davsclaus.com @davsclaus
Camel in Action 2: https://www.manning.com/ibsen2