limit - Move files from the import directory into archive using Apache Camel -


i have requirement move files import directory monitored camel directory. used move , movefailed options of camel in route.

i have maxfilesallowedinarchive parameter in properties files , if file limit exceeded, oldest file has deleted.

how can make custom move , movefailed control number of files moved , keep latest files in archive?

camel doesn't have component operates off of filesystem meta data (such counts , dates), can implement using customer processor uses new java paths , files api's.

create timer/quartz route calls customer processor. in customer processor, list files in "move" , "movefailed" directory count contents (and sort date). if maxfilesallowsinarchive exceeded, delete x number of files folders.


Comments

Popular posts from this blog

javascript - Laravel datatable invalid JSON response -

java - Exception in thread "main" org.springframework.context.ApplicationContextException: Unable to start embedded container; -

sql server 2008 - My Sql Code Get An Error Of Msg 245, Level 16, State 1, Line 1 Conversion failed when converting the varchar value '8:45 AM' to data type int -