Hi

The file/ftp components offer options to move files to a error /
success folder out of the box.
So you do not need to do this with extra routes.

The ftp component
http://camel.apache.org/ftp2

Has 99% of the options from the file component
http://camel.apache.org/file2

See the options
- move
- moveFailed




On Fri, Nov 18, 2011 at 1:12 PM, kanmisc <kango...@gmail.com> wrote:
> Hi
>
> I have similar routes as below  -
>
> <route id="ftpIn">
>        <from uri="sftp://InputLlocation"; />
>        <bean ref="registrationProcess" />
>        <to uri="direct:moveSuccessFiles"/>
>        <stop/>
> </route>
>
> <route id="ftpMove1">
>        <from uri="direct:moveSuccessFiles"/>
>        <from uri="file://location1?filter=#successFileFilter"/>
>        <to uri="sftp://successLocation"; />
>        <to uri="direct:moveFailedFiles"/>
> </route>
>
> <route id="ftpMove2">
>        <from uri="direct:moveFailedFiles"/>
>        <from uri="file://location2?filter=#failureFileFilter"/>
>        <to uri="sftp://failedLocation"; />
> </route>
>
> After reading from the first route(/ftpIn/), /registrationProcess/ bean
> creates 2 different files. Then they need to be uploaded to 2 different ftp
> locations.
>
> In this case when uploading in route /ftpMove1/, it also uploads the content
> of body from the first route(/ftpIn/). And in route /ftpMove2/, it uploads
> along with body of /ftpIn/ and /ftpMove1/.
>
> I tried setting as below which is not solving -
> <setBody ><constant>null</constant></setBody>
>
> Is it possible to remove/reset the body before moving to the next route?
>
> Thanks
> Kannan
>
> --
> View this message in context: 
> http://camel.465427.n5.nabble.com/How-to-reset-the-body-content-before-routing-to-next-endpoint-tp5004107p5004107.html
> Sent from the Camel - Users mailing list archive at Nabble.com.
>



-- 
Claus Ibsen
-----------------
FuseSource
Email: cib...@fusesource.com
Web: http://fusesource.com
Twitter: davsclaus, fusenews
Blog: http://davsclaus.blogspot.com/
Author of Camel in Action: http://www.manning.com/ibsen/

Reply via email to