camel-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From alexey-s <alex...@mail.ru>
Subject Re: Scheduled SFTP consumer
Date Mon, 21 Oct 2013 12:59:57 GMT
Maybe my example will help.
I use RoutePolicy.

CronScheduledRoutePolicy ftpDocReadRoutePolicy = new
CronScheduledRoutePolicy();
ftpDocReadRoutePolicy.setRouteStartTime(routePolicyStartTime);
ftpDocReadRoutePolicy.setRouteStopTime(routePolicyStopTime);
ftpDocReadRoutePolicy.setRouteStopGracePeriod(routePolicyStopGracePeriod);
		
from("{{ftp.doc.url}}" +
	"?noop=true" +
	"&binary=true" +
	"&passiveMode=true" +
	"&recursive=true" +
	"&stepwise=false" +
	"&disconnect=true" +
	"&delay=600000" +
	"&localWorkDirectory={{exchange.localStore}}" +
	"&idempotent=true" +
	"{{ftp.add_params}}")
.id("exchangeDocReadRoute")
.autoStartup(false)
.routePolicy(ftpDocReadRoutePolicy)
	.shutdownRunningTask(ShutdownRunningTask.CompleteAllTasks)
.to("file:{{exchange.store}}");




--
View this message in context: http://camel.465427.n5.nabble.com/Scheduled-SFTP-consumer-tp5741976p5741979.html
Sent from the Camel - Users mailing list archive at Nabble.com.

Mime
View raw message