ASG
IBM
Zystems
Cressida
Icon
Netflexity
 
  MQSeries.net
Search  Search       Tech Exchange      Education      Certifications      Library      Info Center      SupportPacs      LinkedIn  Search  Search                                                                   FAQ  FAQ   Usergroups  Usergroups
 
Register  ::  Log in Log in to check your private messages
 
RSS Feed - WebSphere MQ Support RSS Feed - Message Broker Support

MQSeries.net Forum Index » IBM MQ File Transfer Edition » Ant file with multiple files

Post new topic  Reply to topic
 Ant file with multiple files « View previous topic :: View next topic » 
Author Message
matuwe
PostPosted: Mon Jul 16, 2012 1:41 am    Post subject: Ant file with multiple files Reply with quote

Master

Joined: 05 Dec 2007
Posts: 296

Hi

I need to create a monitor that transfers a multiple files, but only when it receives a .trig file it should start moving all other files. The source application should export multiple files so my monitor should only start when that last .trig file is exported.

I have created the ant file with two filespec fte:move but for some odd reason only the .trig file is moved and not the other files.

Does my monitor need to know about the other files or just the trigger file? or only the Ant file should know?

Sample data

Test1.txt
Test2.txt
test3.txt.trig


Please help Thanks
Back to top
View user's profile Send private message
mqsiuser
PostPosted: Mon Jul 16, 2012 3:30 am    Post subject: Re: Ant file with multiple files Reply with quote

Yatiri

Joined: 15 Apr 2008
Posts: 637
Location: Germany

In ANT you can include multiple files like this:

Code:
   <fileset dir="${folder}" includes="**/*.txt" />
   <fileset dir="${folder}" includes="**/*.trig" />


which you just embed in other tags (if this is supported by them), or you create a loop like this:

Code:
   <for param="file">
      <path>
         <fileset dir="${folder}" includes="**/*.txt" />
         <fileset dir="${folder}" includes="**/*.trig" />
      </path>
      <sequential>
         <propertyregex override="yes" property="filename" input="@{file}" regexp=".*[/\\](.+\.txt)" select= "\1" />                                                               
         [more commands here (using $filename as variable)]
      </sequential>
   </for>


Use eclipse as you IDE to have code completion (for ant)... you can also debug you ant-scripts there.
Back to top
View user's profile Send private message
matuwe
PostPosted: Mon Jul 16, 2012 4:08 am    Post subject: Reply with quote

Master

Joined: 05 Dec 2007
Posts: 296

Thanks

I will try it right away.
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic  Reply to topic Page 1 of 1

MQSeries.net Forum Index » IBM MQ File Transfer Edition » Ant file with multiple files
Jump to:  



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
Protected by Anti-Spam ACP
 
 


Theme by Dustin Baccetti
Powered by phpBB © 2001, 2002 phpBB Group

Copyright © MQSeries.net. All rights reserved.