camel-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Willem Jiang <willem.ji...@gmail.com>
Subject Re: Issue in FILE consumer URI having startingDirectoryMustExist set to true
Date Tue, 25 Nov 2014 08:24:36 GMT
It’s strange your uri is options is start with “?&”. You can double check with it?
BTW, I just added a unit test[1] to file endpoint, it look like  startingDirectoryMustExist
option workd rightly.

[1]https://git-wip-us.apache.org/repos/asf?p=camel.git;a=commit;h=3697fbc9

--  
Willem Jiang

Red Hat, Inc.
Web: http://www.redhat.com
Blog: http://willemjiang.blogspot.com (English)
http://jnn.iteye.com (Chinese)
Twitter: willemjiang  
Weibo: 姜宁willem



On November 24, 2014 at 4:35:28 PM, Himanshu Mittal (himanshu.mittal313@gmail.com) wrote:
> Hi,
> I am observing one strange behavior with consumer route in camel FILE
> component
>  
> Here is how I am configuring my camel route
>  
> public void configure() throws Exception {
> onException(Exception.class)
> .handled(true)
> .to(ERROR_HANDLER);
>  
> from(camelURI).routeId(routeID).noAutoStartup()
> .doTry()
> .process(iTask)
> .to(CONSUMER_TASK)
> .doCatch(Exception.class)
> .to(ERROR_HANDLER)
> .end();
> }
>  
>  
> In case when polling directory ( "C:/camel/temp" )does not exist I am not
> able to handle the exception with camel URI configuration.
> It comes to ERROR_HANDLER when camelURI params are configured as :
> file://C:/camel/temp?
> &delay=10&useFixedDelay=true&initialDelay=10*&startingDirectoryMustExist=true*&consumer.bridgeErrorHandler=true&autoCreate=false*&startingDirectoryMustExist=true*&directoryMustExist=true&readLock=changed
 
>  
> BUT does not come to error handler when camelURI params are configured as
> 1)file://C:/camel/temp?&delay=10&useFixedDelay=true&initialDelay=10&consumer.bridgeErrorHandler=true&autoCreate=false*&startingDirectoryMustExist=true*&directoryMustExist=true&readLock=changed
 
>  
> 2)file://C:/camel/temp?&delay=10&useFixedDelay=true&initialDelay=10*&startingDirectoryMustExist=true*
 
> &consumer.bridgeErrorHandler=true&autoCreate=false
> &directoryMustExist=true&readLock=changed
>  
> 3)file://C:/camel/temp?&delay=10&useFixedDelay=true&initialDelay=10*&startingDirectoryMustExist=true*&autoCreate=false
 
> &directoryMustExist=true &consumer.bridgeErrorHandler=true &readLock=changed
 
>  
> I am not able to figure out the route cause how is the positioning of
> *startingDirectoryMustExist *affecting the camel route ?
>  
>  
>  
>  
> --
> View this message in context: http://camel.465427.n5.nabble.com/Issue-in-FILE-consumer-URI-having-startingDirectoryMustExist-set-to-true-tp5759521.html
 
> Sent from the Camel - Users mailing list archive at Nabble.com.
>  


Mime
View raw message