Hi

In relation to this post:
http://old.nabble.com/errorHandler-%2B-.handled%28false%29%29--in-Spring-DSL.-td28670904.html

I'm really stuck on my use case.

<from file>
<to translator>
<to jms>

1) If route fails I want to move the original file through some custom
processing steps and send it to a directory (and remove it from the source
directory (consume it)).
2) If route completes I want to move the original file to a backup
directory.

2) Could be solved either by using: 
<onCompletion onComeplete="true">
<to backupdir>
</onCompletion>

or by putting ?move=backup on the file endpoint.

The problem is then that 1) negates this by handling the exception. ?move=
and onCompletion then thinks that the route ended succesfully and go ahead
and move the file to the backup folder anyways.

So what to do? Don't handle the exception by using onException. This would
be ok too, but then the file will not be deleted/consumed from the source
directory such as the deadletterErrorHandler would do.

This seems like a really really simple thing to do but I guess I'm using a
wrong combination of components for it.

Any ideas?
-- 
View this message in context: 
http://old.nabble.com/Dead-Letter-Channel-and-errorHandling-usecase-help.-tp28681468p28681468.html
Sent from the Camel - Users mailing list archive at Nabble.com.

Reply via email to