排定的傳送日誌訊息格式

代理程式每次處理排定檔案傳送的要求時,都會將排程日誌訊息發佈至協調佇列管理程式 (在其 SYSTEM.FTE/Log/agent name/schedule ID topic)。 此訊息符合 ScheduleLog.xsd XML 綱目。

綱目

下列綱目說明在排程日誌 XML 訊息中有效的元素。

<xsd:schema xmlns:xsd="https://www.w3.org/2001/XMLSchema">
    <xsd:include schemaLocation="fteutils.xsd"/> 

    <xsd:element name="schedulelog">         
        <xsd:complexType>         	
            <xsd:sequence>         	    
                <xsd:element name="originator"       type="hostUserIDType"  
                             maxOccurs="1"           minOccurs="0"/>         		
                <xsd:element name="action"           type="actionType"      
                             maxOccurs="1"           minOccurs="1"/> 				
                <xsd:element name="schedule" 	      type="scheduleType"    
                             maxOccurs="1"           minOccurs="0"/> 				
                <xsd:element name="sourceAgent"      type="agentType"       
                             maxOccurs="1"           minOccurs="0"/>            		
                <xsd:element name="destinationAgent" type="agentClientType" 
                             maxOccurs="1"           minOccurs="0" /> 	        	
                <xsd:element name="status"           type="statusType"      
                             maxOccurs="1"           minOccurs="0"/>         		
                <xsd:element name="transferSet"      type="transferSetType" 
                             maxOccurs="1"           minOccurs="0"/>         		
                <xsd:element name="job"              type="jobType"         
                             maxOccurs="1"           minOccurs="0" />   		         	
            </xsd:sequence>         	
            <xsd:attribute name="version"   type="versionType" use="required"/> 			
            <xsd:attribute name="ID"        type="xsd:string"  use="required"/>         
        </xsd:complexType>     
    </xsd:element>           

    <xsd:complexType name="actionType"> 		
        <xsd:simpleContent>     		
            <xsd:extension base="actionEnumType">     			
                <xsd:attribute name="time" type="xsd:dateTime" use="required" />     		
            </xsd:extension>     	
        </xsd:simpleContent> 	
    </xsd:complexType> 	 	

    <xsd:simpleType name="actionEnumType"> 			
        <xsd:restriction base="xsd:token">     			
            <xsd:enumeration value="submit"/>     			
            <xsd:enumeration value="delete"/>     			
            <xsd:enumeration value="expire"/>     			
            <xsd:enumeration value="skipped"/>     		
        </xsd:restriction>
    </xsd:simpleType>          	

    <xsd:complexType name="transferSetType">         
        <xsd:sequence>             
            <xsd:element name="item"            type="itemType" 
                         maxOccurs="unbounded"  minOccurs="1" />         
        </xsd:sequence>         
        <xsd:attribute name="size" type="xsd:int" use="required" />         
        <xsd:attribute name="priority" type="priorityType" use="optional" />     
    </xsd:complexType>         	

    <xsd:complexType name="itemType"> 		
        <xsd:sequence> 			
            <xsd:element name="source"      type="fileSourceType" 
                         maxOccurs="1"      minOccurs="1" /> 			
            <xsd:element name="destination" type="fileDestinationType" 
                         maxOccurs="1"      minOccurs="1" /> 		
        </xsd:sequence> 		
        <xsd:attribute name="mode" type="modeType" use="required" /> 		
        <xsd:attribute name="checksumMethod" type="checkSumMethod" use="required" /> 	
    </xsd:complexType>     

</xsd:schema>

瞭解排程日誌訊息

以下說明在排程日誌訊息中使用的元素及屬性:

<schedulelog>
群組元素,說明提交的單一排定檔案傳送。
屬性 說明
version 指定此元素的版本,如 WebSphere® MQ Managed File Transfer所詳述。
ID 提交的排程檔案傳送的唯一 ID。
<originator>
群組元素,包含指定要求發送端的元素。
<hostName>
來源檔案所在系統的主機名稱。
<userID>
發出檔案傳送的使用者 ID。
<mqmdUserID>
在訊息描述子 (MQMD) 中提供的 IBM® WebSphere MQ 使用者 ID
<action>
針對符合 <schedulelog> 元素之 ID 屬性的排定傳送,指定要採取的動作。 此元素必須是下列其中一個值:
  • submit - 新建排定的傳送
  • delete - 取消排程傳送
  • expire - 即將處理排程傳送項目
  • skipped - 因為代理程式離線,無法啟動排定的傳送。 當代理程式變成可用時會記載此訊息,指出已跳過傳送。
屬性 說明
time 指定發佈日誌項目的日期和時間(以日期時間格式表示)。
<sourceAgent>
指定來源檔案所在系統上的代理程式名稱。
屬性 說明
代理程式 (agent) 指定代理程式的名稱。
QMgr 代理程式佇列管理程式的名稱。
<destinationAgent>
指定系統上要做為檔案傳送目的地的代理程式名稱。
屬性 說明
代理程式 (agent) 指定代理程式的名稱。
QMgr 代理程式佇列管理程式的名稱。
<status>
結果碼及補充訊息。
<transferSet>
指定您想要一起執行的檔案傳送群組。 在傳輸期間,<transferSet> 是包含 <item> 元素的群組元素。
屬性 說明
大小 指定傳送項目的數目。
priority 傳送的優先順序層次。 優先順序是範圍 0-9 中的值,其中 0 是最低優先順序。 預設優先順序層次是 0,依預設,傳送時會使用來源代理程式的優先順序層次。
<item>
群組元素,包含指定來源及目的地檔案名稱和位置的元素。
屬性 說明
mode 指定傳送模式為二進位或文字模式。
checksumMethod 指定產生訊息摘要以建立數位簽章的雜湊演算法類型。 允許的值是 MD5 或 none
<source>
群組元素,包含來源系統上檔案的 <file> 及 <checksum> 元素。
屬性 說明
recursive 指定當 <source> 元素是目錄或包含萬用字元時,在子目錄中遞迴地傳送檔案。
disposition 指定當 <source> 已順利傳送至其目的地時,對 <source> 元素採取的動作。 有效選項如下所示:
  • leave - 來源檔案維持不變。
  • delete - 順利傳送來源檔案之後,即從來源系統中刪除來源檔案。
<destination>
群組元素,包含目的地系統上檔案的 <file> 及 <checksum> 元素。
屬性 說明
類型 目的地的檔案或目錄的類型。 有效選項如下所示:
  • file - 指定檔案作為目的地
  • directory - 指定目錄作為目的地
exist 指定如果目的地系統上存在目的地檔案時要採取的動作。 有效選項如下所示:
  • error - 報告錯誤,且不傳送檔案。
  • overwrite - 改寫現有目的地檔案。
<file>
指定要傳送的檔案名稱。 請使用完整路徑,其格式與作業系統一致,例如 C:/from/here.txt。 請不要使用檔案 URI。
屬性 說明
encoding 文字檔傳送的編碼。
EOL 指定行尾標記。 允許的值如下:
  • LF - 僅限換行字元
  • CRLF - 換行 (carriage return/line feed) 字元序列
<job>
群組元素,包含指定工作詳細資料的元素。 <job> is a user-defined job name identifier that is added to the log message when the transfer has started. This <job> element is the same as the <job> element that is included in the transfer request message, which is described in the following topic: 檔案傳送要求訊息格式.
<name>
name 的值可以是任何字串。

範例

以下範例說明針對下列每一個排定的傳送動作,提供符合此綱目的 XML 訊息:以與標準傳送相同的方式,記載由排程啟動的傳送。 如需排程所啟動傳送的日誌訊息範例,請參閱 排程傳送日誌訊息範例