![]() | ![]() |
|
08-03-2010 02:10 PM
I have a need for a transactional 'message to file' transfer that triggers the transfer on arrival in the target queue (as soon as the message arrives in the queue, MIM writes the file to a Windows file system). I know how to trigger this from a source FILE using a directory monitor (using a dirmon and writing to a file or a queue), but am not sure how to trigger from a MESSAGE arriving in a queue. Using 8.5.0.206
Solved! Go to Solution.
08-03-2010 04:35 PM
Mark,
One option is to utilize MQ triggering. You can configure a specific queue to be trigger an a specific application for message that comes in. In your case, that application can be a bat file which contains a ftf request. Take a look at the MQ Documentation on how to implement triggering on a queue.
08-03-2010 04:48 PM - last edited on 09-15-2010 03:31 PM
There are sample queue to file transfers supplied at installation (in the Process Monitor, go to Managed File Transfers | Requests | Samples | Queue To File). Use those and the documentation to build a sample request in the Process Monitor.
- Let's say you called your Queue to File Request "QueueToFile". It reads from MYAPPQUEUE and writes to a file.
- Create the application queue. Set MQ triggering on and set to every, e.g.:
$ runmqsc
1: define qlocal(MYAPPQUEUE) TRIGGER TRIGTYPE(EVERY) PROCESS(MYPROCESS)
- Create the initiation queue
$ runmqsc
1: define qlocal(MYTRIGGERQUEUE)
- Create a sample batch program that executes the request
Contents of c:\temp\startftf.bat:
ftf -ofile xmdir://QueueToFile
- Create the process definiton
$ runmqsc
1: define process(MYPROCESS) APPLICID(c:\temp\startftf.bat)
- Start the trigger monitor
$ runmqtrm -q MYTRIGGERQUEUE
That should be it. When a message lands on MYAPPQUEUE, the queue to file transfer is executed.
08-03-2010 04:53 PM - last edited on 08-03-2010 05:05 PM
Note you can put the trigger monitor in the Launcher.xml to run it in the Component Manager for even more control through MIM.
08-05-2010 09:00 AM
Thanks Ethan- worked very nicely! One additional comment- the APPLICATION TYPE needs to be defined in the MQ Process (in this case, Windows). Here's the command and the options:
APPLTYPE (apptype)
Appltype can be:
CICS-------+
+-DEF--------+
+-DOS--------+
+-IMS--------+
+-MVS--------+
+-NOTESAGENT-+
+-NSK--------+
+-OPENVMS----+
+-OS2--------+
+-OS400------+
+-UNIX-------+
+-WINDOWS----+
+-WINDOWSNT--+
'-WLM--------'
mvh
![]() |
![]() |
![]() |
|
|
![]() |
![]() |
![]() |
















