I have a message which has -
Header 
    "To" - "a...@sdf.com,x...@dsfsdf.com,s...@serr.com"
Body
    Hello

onthis message I tried -
   
from("jms:queue:new.test1").splitter(header("To").tokenize(",")).to("jms:queue:new.test2");

and I was expecting 3 entries on test2 queue
Header 
    "To" - "a...@sdf.com"
Body
    Hello

Header 
    "To" - "x...@dsfsdf.com"
Body
    Hello

Header 
    "To" - "s...@serr.com"
Body
    Hello


But instead I got 3 messages on test2 queue like
Header 
    "To" - "a...@sdf.com,x...@dsfsdf.com,s...@serr.com"
Body
    a...@sdf.com

Header 
    "To" - "a...@sdf.com,x...@dsfsdf.com,s...@serr.com"
Body
    x...@dsfsdf.com

Header 
    "To" - "a...@sdf.com,x...@dsfsdf.com,s...@serr.com"
Body
    s...@serr.com

So I guess, I am doing it and even understanding it wrong.

Can anyone here guide me how to handle this situation.

Thanks and Regards,



-- 
View this message in context: 
http://www.nabble.com/Split-using-tokenize-on-header-tp23445496p23445496.html
Sent from the Camel - Users mailing list archive at Nabble.com.

Reply via email to