camel-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Gustavo Franke <franke.gust...@gmail.com>
Subject Re: issue moving files to ftp
Date Tue, 19 Oct 2010 14:03:37 GMT
Yes I did, this line calls the logic that does that  from("file://" +
localWorkFolder + "?noop=true").beanRef("parser","convert"); and I can
see in /tmp/camelout those files proper generated. I've started this
thread because of the only goofy thing here is when moving to the FTP.

Plus I've found that if I manually create the file and then run the
app, it works fine... is there a way to ensure that the file is
created before copying to the ftp or like?

I'm using windows and filezilla server right now, but this process
will run in a Unix-like environment.

On 10/18/10, Willem Jiang <willem.jiang@gmail.com> wrote:
> Did you wrote the file into /tmp/camelout ?
> I didn't find any route which will put the files into /tmp/camelout
> directory.
>
> On 10/19/10 5:56 AM, Gustavo Franke wrote:
>> Here's what I have in my RouteBuilder
>>
>> public void configure() {
>>          String localWorkFolder = "/tmp/camel";
>>
>> from("ftp://gustavo@localhost:21/Test?password=gustavo&move=.processed").to("file://"
>> + localWorkFolder);
>>          from("file://" + localWorkFolder +
>> "?noop=true").beanRef("parser",
>> "convert");
>>          from("file:///tmp/camelout").to("ftp://gustavo
>> @localhost:21/Test/out?password=gustavo&fileName=${file:onlyname}");
>>      }
>>
>> I'm not sure if I am missing some thing but on the java app side the files
>> are generated properly, those files should be copied to the ftp.
>> But for some reason, on the ftp side the files are generated but its
>> content
>> is missing or corrupt, and I'm completely clueless regarding to this.
>>
>> If I don't explicit the&fileName=${file:onlyname} I get this error "Error
>> writing file [Test/out/C:\tmp\camel\myFile.txt]" being Test/out the remote
>> folder and C:\tmp\camel\myFile.txt path of the file. That's the reason why
>> I
>> added the&fileName=${file:onlyname} but I don't know why the content is
>> missing.
>>
>> Any help would be great.
>> Thanks,
>> Gustavo
>>
>
>
> --
> Willem
> ----------------------------------
> Open Source Integration: http://www.fusesource.com
> Blog:    http://willemjiang.blogspot.com (English)
>           http://jnn.javaeye.com (Chinese)
> Twitter: http://twitter.com/willemjiang
>

Mime
View raw message