You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@camel.apache.org by Mohammad Shadab Ali <Mo...@genpact.com> on 2013/09/12 09:41:58 UTC
Add xml extension to filename in file producer
Hi,
File producer uses a unique id as file name when filename header is not set, with no extension. My requirement is to add xml extension to the file in producer. Is there a way to configure this in the file producer.
Thanks for your help.
Regards,
Shadab
________________________________
*** This e-mail (and any attachments), is confidential and may be privileged. It may be read, copied and used only
by intended recipients. Unauthorized access to this e-mail (or attachments) and disclosure or copying of its
contents or any action taken in reliance on it is unlawful. Unintended recipients must notify the sender immediately
by e-mail/phone & delete it from their system without making any copies or disclosing it to a third person.***
This e-mail (and any attachments), is confidential and may be privileged. It may be read, copied and used only
by intended recipients. Unauthorized access to this e-mail (or attachments) and disclosure or copying of its
contents or any action taken in reliance on it is unlawful. Unintended recipients must notify the sender immediately
by e-mail/phone & delete it from their system without making any copies or disclosing it to a third person.
Re: Add xml extension to filename in file producer
Posted by Claus Ibsen <cl...@gmail.com>.
Hi
Just set a header with the file name you want, for example the keep
using he message id,
setHeader(Exchange.FILE_NAME, constant("${id}.xml"))
On Thu, Sep 12, 2013 at 9:41 AM, Mohammad Shadab Ali
<Mo...@genpact.com> wrote:
> Hi,
>
> File producer uses a unique id as file name when filename header is not set, with no extension. My requirement is to add xml extension to the file in producer. Is there a way to configure this in the file producer.
>
> Thanks for your help.
>
>
> Regards,
> Shadab
>
>
> ________________________________
> *** This e-mail (and any attachments), is confidential and may be privileged. It may be read, copied and used only
> by intended recipients. Unauthorized access to this e-mail (or attachments) and disclosure or copying of its
> contents or any action taken in reliance on it is unlawful. Unintended recipients must notify the sender immediately
> by e-mail/phone & delete it from their system without making any copies or disclosing it to a third person.***
>
> This e-mail (and any attachments), is confidential and may be privileged. It may be read, copied and used only
> by intended recipients. Unauthorized access to this e-mail (or attachments) and disclosure or copying of its
> contents or any action taken in reliance on it is unlawful. Unintended recipients must notify the sender immediately
> by e-mail/phone & delete it from their system without making any copies or disclosing it to a third person.
>
--
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