|
RSS Feed - WebSphere MQ Support
|
RSS Feed - Message Broker Support
|
 |
|
Question on FileInput & Email node in Broker V6.1 |
« View previous topic :: View next topic » |
Author |
Message
|
kirankinnu |
Posted: Tue Apr 08, 2008 11:01 am Post subject: Question on FileInput & Email node in Broker V6.1 |
|
|
 Centurion
Joined: 12 Jun 2004 Posts: 128 Location: Chicago, IL
|
Hello Folks,
We are using FileInput node. We do not want duplicate files to be processed. Is there a way to implement this without using a database.
I do have 1 more question on Email node. The Email node is currently working if I mention whom to send the mail to. Is there a way that I could dynamically change the ToAddress without redeploying the code.
Thank You,
Kiran |
|
Back to top |
|
 |
jefflowrey |
Posted: Tue Apr 08, 2008 11:04 am Post subject: |
|
|
Grand Poobah
Joined: 16 Oct 2002 Posts: 19981
|
|
Back to top |
|
 |
kirankinnu |
Posted: Tue Apr 08, 2008 11:13 am Post subject: |
|
|
 Centurion
Joined: 12 Jun 2004 Posts: 128 Location: Chicago, IL
|
Jeff,
Thank you for your reply.
Duplicate with the same file name.
I was thinking more in the fashion of changing some config file rather than making a database call prior to Email node and setting the EmailOutputHeader.
Regards,
Kiran |
|
Back to top |
|
 |
jefflowrey |
Posted: Tue Apr 08, 2008 11:34 am Post subject: |
|
|
Grand Poobah
Joined: 16 Oct 2002 Posts: 19981
|
You can use FileInput to read a configfile... and then save that in a shared variable...and set the To Field from that....
Or you can set the To field from a UserDefinedProperty.
I don't believe you can do anything with the FileInput nodes to prevent it from a) fully processing some file, b) later on, fully processing some other file with the exact same name. Unless you do something to store the names of files you have processed, and then decide whether to process the contents of the file or not.
You don't have to worry about it fully processing the same file twice at the same time, though. _________________ I am *not* the model of the modern major general. |
|
Back to top |
|
 |
mqpaul |
Posted: Wed Apr 09, 2008 4:24 am Post subject: There's no easy way to stop processing duplicate files |
|
|
 Acolyte
Joined: 14 Jan 2008 Posts: 66 Location: Hursley, UK
|
Quote: |
We are using FileInput node. We do not want duplicate files to be processed. Is there a way to implement this without using a database. |
IMHO database is the best way. The problem is how to determine a duplicate file; in your case, you want unique file names. Is this "unique forever", or just "unique this month"? Whichever, you need a table of files already processed; for "unique this month" you clear that list monthly, or regularly delete rows more than 31 days old, or whatever your business needs.
Trying to do it with the FileInput node directly won't work; it would need to know which files have previously been processed, which would need a database entry, and we're back to your starting point.
You might think you could use the "move to archive" processing combined with not setting "Replace duplicate archives", but that won't work. Archive processing takes place after the downstream processing has finished, so it's too late to prevent the file being processed.
An alternative can be to process the file twice, and rely on downstream flows to reject duplicate transactions. For example, if files contain unique order numbers, the downstream order process could reject duplicates. Of course, this is the same a using a database, just the database is the one used by the order processing, and it rejects duplicate order numbers instead of duplicate file names. _________________ Paul |
|
Back to top |
|
 |
|
|
 |
|
Page 1 of 1 |
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum
|
|
|
|