You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@camel.apache.org by sscharff <st...@systemfeld.de> on 2011/08/10 17:37:24 UTC

Problems with the splitter

It won't split and I don't know why - these are my words for the start here.

I created a unit test with Camel and the FakeFtpServer. This ist the
configure-Method in my RouteBuilder:

 @Override
 public void configure() throws Exception {
    from(fromUri).
        log("route complete content: ${body}").
        split(body().tokenize("@")).
        log("route line: ${body}").
        end();
 }

and see following log entries:

route1 INFO  route complete content: a@b@c
route1 INFO  route line: -rwxrwxrwx  1 none     none                   5 Aug
10  2011 file.txt

If I take the char 'o' as my tokenizer, it split the string "-rwxrwxrwx  1
none     none                   5 Aug 10  2011 file.txt" into parts. 

Why takes the splitter not the "real" body? 


chears*stephan



--
View this message in context: http://camel.465427.n5.nabble.com/Problems-with-the-splitter-tp4686262p4686262.html
Sent from the Camel Development mailing list archive at Nabble.com.

Re: Problems with the splitter

Posted by sscharff <st...@systemfeld.de>.
Hi Claus - sorry for that! 

--
View this message in context: http://camel.465427.n5.nabble.com/Problems-with-the-splitter-tp4686262p4688825.html
Sent from the Camel Development mailing list archive at Nabble.com.

Re: Problems with the splitter

Posted by Claus Ibsen <cl...@gmail.com>.
Hi

Please use the @user mailing list for questions on using Apache Camel.


On Wed, Aug 10, 2011 at 5:37 PM, sscharff <st...@systemfeld.de> wrote:
> It won't split and I don't know why - these are my words for the start here.
>
> I created a unit test with Camel and the FakeFtpServer. This ist the
> configure-Method in my RouteBuilder:
>
>  @Override
>  public void configure() throws Exception {
>    from(fromUri).
>        log("route complete content: ${body}").
>        split(body().tokenize("@")).
>        log("route line: ${body}").
>        end();
>  }
>
> and see following log entries:
>
> route1 INFO  route complete content: a@b@c
> route1 INFO  route line: -rwxrwxrwx  1 none     none                   5 Aug
> 10  2011 file.txt
>
> If I take the char 'o' as my tokenizer, it split the string "-rwxrwxrwx  1
> none     none                   5 Aug 10  2011 file.txt" into parts.
>
> Why takes the splitter not the "real" body?
>
>
> chears*stephan
>
>
>
> --
> View this message in context: http://camel.465427.n5.nabble.com/Problems-with-the-splitter-tp4686262p4686262.html
> Sent from the Camel Development mailing list archive at Nabble.com.
>



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