2011-05-06 33 views
1

是否可以在MQFTE中调用poststst和presrc调用中的antscript?是否可以在MQFTE的postdst和presrc调用中调用antscript?

+0

是,请参阅:http://stackoverflow.com/questions/5430730/mq-fte-and-ant-script – 2011-05-06 13:17:59

+0

@martin clayton您能否提供我的语法。 – trilawney 2011-05-09 08:43:39

+0

我没有任何测试的方法,但基于http://publib.boulder.ibm.com/infocenter/wmqfte/v7r0/index.jsp?topic=/com.ibm.wmqfte.doc/上的文档nested_pa​​rams.htm我认为像'' – 2011-05-09 10:00:51

回答

2

下面是一个例子:

<request version="4.00" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="FileTransfer.xsd"> 
<managedTransfer> 
    <originator> 
     <hostName>$hostName</hostName> 
     <userID>$userID</userID> 
    </originator> 
    <sourceAgent QMgr="$sourceQM" agent="$sourceAgent"/> 
    <destinationAgent QMgr="$destQM" agent="$destAgent"/> 
    <transferSet priority="5"> 
     <metaDataSet> 
     <metaData key="some_key">Some value</metaData> 
     </metaDataSet> 
     <postSourceCall> 
     <command name="example.xml" retryCount="0" retryWait="0" successRC="0" type="antscript"> 
      <property name="ant.FILEPATH" value="$filepath"/> 
      <property name="antSrcAgent" value="$sourceAgent"/> 
     </command> 
     </postSourceCall> 
     <item checksumMethod="MD5" mode="binary"> 
     <source disposition="delete" recursive="false"> 
      <file>$filepath</file> 
     </source> 
     <destination exist="error" type="directory"> 
      <file>$destFile</file> 
     </destination> 
     </item> 
    </transferSet> 
    <job> 
     <name>Example FTE job</name> 
    </job> 
    </managedTransfer> 
</request> 

传递到Ant脚本的属性是任意名称。你可以通过这种方式传递任何属性。我使用postSourceCall,但可以将其更改为postDest,preSource等。

相关问题