Quantcast
Channel: Apache Timeline
Viewing all articles
Browse latest Browse all 5648

Splitting Message from Ftp Consumer

$
0
0
Hi all,

I’m getting an strange behaviour splitting a message body coming from a ftp
consumer. Below route works perfectly when I use a local file consumer
(line commented). I get a log message per file input line, and I can
process the content later correctly.

But when I change to the ftp I get the file information data:

[fromFtp2SOAP] INFO - Line: -rw-r--r-- 1 513 512 83 Dec
05 09:55 simpleTextData.txt

The log line with “ftp:${body}” present correctly the full text content of
the file.

I have tried with and without localWorkDirectory option, with same result.

Any clue? Thanks in advance.
<route id="fromFtp2SOAP">
<from uri="ftp://user:pass [ at ] host
/postalBox/inBox?fileName=simpleTextData.txt&localWorkDirectory=temp"/>
<!-- from
uri="file:temp/inBox?noop=true&fileName=simpleTextData.txt"/ -->
<log loggingLevel="INFO" message="ftp: ${body}"/>
<split streaming="true">
<tokenize token="\n"/>
<log loggingLevel="INFO" message="Line: ${body}"/>
<to uri="direct:continue"/>
</split>
</route>

Viewing all articles
Browse latest Browse all 5648

Trending Articles