Apache-Camel: How to put more than one Ical File in exchange -


i have processor puts unmarshaled ical file in custom object. after list of object saved exchange. after need put second ical exchange. problem cant use "from" 2 times in route. how can solve this?

code processing 1 ical following:

from("file://src/test/resources?filename=calendar.ics&delete=false&noop=true") .unmarshal("ical") .process(icstobeanprocessor) .end(); 

perhaps can improve design bit. instead of specifying filenames use directory instead. process files present in directory , set them in header properties. like

from("file://src/test/resources?delete=false&noop=true") .unmarshal("ical") .process(icstobeanprocessor) // in icstobeanprocessor set header property content.filename output of unmarshaller bean .end(); 

also can more specific using regex specifying filenames. case pick files ends "ics". see http://camel.apache.org/file.html more details.


Comments

Popular posts from this blog

Android layout hidden on keyboard show -

google app engine - 403 Forbidden POST - Flask WTForms -

c - Why would PK11_GenerateRandom() return an error -8023? -