Results 1 to 3 of 3

Thread: file outbound adapter - delete source file issue

  1. #1

    Default file outbound adapter - delete source file issue

    I couldnt work out what i am doing wrong.

    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.

    any help ?

  2. #2
    Join Date
    May 2007
    Location
    Netherlands
    Posts
    614

    Default

    Could you attach/link to your test project? I'm a bit lost figuring out exactly what you're doing.

  3. #3

    Default

    attached the test prg. the test scenario is to move the source files to the error folder - but not working.
    Attached Files Attached Files

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •