camel-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Claus Ibsen (JIRA)" <j...@apache.org>
Subject [jira] Commented: (CAMEL-1428) SftpConsumer : GenericFileRenameProcessStrategy - String index out of bounds
Date Mon, 09 Mar 2009 11:27:40 GMT

    [ https://issues.apache.org/activemq/browse/CAMEL-1428?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=50337#action_50337
] 

Claus Ibsen commented on CAMEL-1428:
------------------------------------

Paddy can you do me a favor

Adding the tracer to your route. Just add the code below in your route builder, before the
from(getFTP...)
{code}
                getContext().addInterceptStrategy(new Tracer());
{code}

This will log at INFO level the message as they are routed.

I would like to see what all the headers got resolve to, in that last bug of yours, eg using:
${file:parent}/.done/${file:name}

PS: I am wondering if Camel should default add the pre and postfix so you as an end user just
sets:
move=.done

And then Camel will add the ${file:parent} and ${file:onlyname} itself. Then its easier for
end users to work with.

> SftpConsumer : GenericFileRenameProcessStrategy - String index out of bounds
> ----------------------------------------------------------------------------
>
>                 Key: CAMEL-1428
>                 URL: https://issues.apache.org/activemq/browse/CAMEL-1428
>             Project: Apache Camel
>          Issue Type: Bug
>          Components: camel-ftp
>    Affects Versions: 2.0.0
>         Environment: Windows XP
>            Reporter: Paddy Daly
>            Assignee: Claus Ibsen
>             Fix For: 2.0-M1
>
>         Attachments: camel-error.txt, camel-error2.txt, camel-error3.txt, camel-error4.txt
>
>
> While trying to consume a file via SFTP and using the moveExpression to move the file
into a done folder a renameException is thrown.
> In GenericFile the relativeFileName reads something like the following.   /incoming/test/file1.txt
> When it tries to call this code and exception is thrown because File.separator is '\'
in a windows environment.
> String relative = relativeFileName.substring(0, relativeFileName.lastIndexOf(File.separator));

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


Mime
View raw message