This forum is now a read-only archive. All commenting, posting, registration services have been turned off. Those needing community support and/or wanting to ask questions should refer to the Tag/Forum map, and to http://spring.io/questions for a curated list of stackoverflow tags that Pivotal engineers, and the community, monitor.

file outbound adapter - delete source file issue

The flow is to move a set of files (scanner result) from one location to another. so <int-file:inbound> and <int-file:outbound> with a bridge from inbound channel to outbound channel.

The test scenario is that, if the outbound directory doesnt have write permission I need to move those files to a error folder and leave it there ...

I have permErrorChannel defined and an outbound adapter listening to it to write to the error folder.

Any Exception of type MessageHandlingException I route <router> to permErrorChannel using a ref="errormessagetomessageconvertor" :
public Message<File> convert(MessageException error) {
i have checked the header filename exist and if not put that header as well here
}

I can see the files are copied into the error folder but I couldnt work out how to delete the original files. delete source flag is enabled out outbound writer

Also, tried to register the Transactionsync and tried to delete the file in there manually but always return false -

even I have tried the same deletion in an outbound intreceptor - but still return delete false.