camel-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Claus Ibsen <claus.ib...@gmail.com>
Subject Re: Poll a directory and send the file name with notification message to queue
Date Thu, 28 Nov 2013 17:23:19 GMT
You can use noop=true which leaves the file untouched.

And Camel just stores the message body as java.io.File, so if you
don't access the body on demand, or just change the body to its name
only

from file
  setBody(header(Exchange.FILE_NAME))



On Thu, Nov 28, 2013 at 5:56 PM, rupak_sarkar <rupak.sarkar1@gmail.com> wrote:
> Hi,
>
> is it possible to use file component to poll for files in directories but
> NOT actually read the file?
> <the file size is quite big - so I don't want to read the file> - but I need
> a notification message (with the file name) and send that to queue.
>
> Is there a way to achieve this using File component? or any other component
> that will help me achieve this?
>
> Thanks
> Rupak
>
>
>
> --
> View this message in context: http://camel.465427.n5.nabble.com/Poll-a-directory-and-send-the-file-name-with-notification-message-to-queue-tp5744038.html
> Sent from the Camel - Users mailing list archive at Nabble.com.



-- 
Claus Ibsen
-----------------
Red Hat, Inc.
Email: cibsen@redhat.com
Twitter: davsclaus
Blog: http://davsclaus.com
Author of Camel in Action: http://www.manning.com/ibsen

Mime
View raw message