MQ message properties set by MFT on messages written to destination queues

When transferring from file to message, Managed File Transfer can set IBM MQ message properties on the first message written to the destination queue. Additional IBM MQ message properties are set when a file to message transfer has failed.

IBM MQ message properties allow an application to select messages to process, or to retrieve information about a message without accessing MQ Message Descriptor (MQMD) or MQRFH2 headers. See Message properties.


Standard properties

We can use the -qmp parameter on the fteCreateTransfer command or the fteCreateTemplate command to specify whether IBM MQ message properties are set on the first message written to the destination queue by the transfer. For an example of how to use this parameter, see the topic Example: Setting IBM MQ message properties on a file-to-message transfer

The IBM MQ message properties contain transfer metadata. The message property names are prefixed with usr.WMQFTE. The usr. prefix makes these message properties available to JMS applications.

    usr.WMQFTETransferId
    The unique hexadecimal transfer ID.

    usr.WMQFTETransferMode
    The type of file transfer: binary mode or text mode.

    usr.WMQFTESourceAgent
    The name of the source agent.

    usr.WMQFTEDestinationAgent
    The name of the destination agent.

    usr.WMQFTEFileName
    The name of the source file.

    usr.WMQFTEFileSize
    The size of the source file in bytes.

    usr.WMQFTEFileLastModified
    The last modified time of the source file. This value is in units of milliseconds, measured from 00:00:00 UTC, January 1, 1970.

    usr.WMQFTEFileIndex
    The index of the current file in the list of files that are being transferred. The first file in the list has index 0.

    usr.WMQFTEMqmdUser
    The MQMD user ID of the user that submitted the transfer request.


Failure properties

When a file to message transfer fails after the destination agent has written at least one message to the destination queue, Managed File Transfer writes a blank message to the destination queue. If the -qmp parameter is set to true, this blank message has two IBM MQ message properties set. For an example of a file to message transfer failure, see Failure of a file-to-message transfer.

When a file to message transfer fails completely, Managed File Transfer writes a blank message to the destination queue. If the -qmp parameter is set to true, and the length of the message data is greater than the maxInputOutputMessageLength value, the following error message is displayed at the command line.
Name WMQFTEResultCode
Value 40 
Name WMQFTESupplement 
Value BFGTR0072E: The transfer failed to complete due to the exception BFGIO0205E:The message data length 1290843 being written
to the output queue "M2F@q2" is greater than the maximum allowed 1048576. 

The IBM MQ message properties contain information about the failure. As with the standard message properties, the message property names are prefixed with usr.WMQFTE and are available to JMS applications.

    usr.WMQFTEReturnCode
    The return code of the transfer. For a list of possible values for this return code, see the topic Return codes for MFT.

    usr.WMQFTESupplement
    A supplementary message describing in more detail why the transfer failed.


User-defined properties

Metadata specified using the -md parameter with the fteCreateTransfer command can be set as IBM MQ message properties. If the -qmp parameter is set to true, any metadata specified by the user will be added to the message header of the first message.

The metadata name is prefixed by usr.. For example, if the metadata is department=accounts, the IBM MQ message header is set to usr.department=accounts.

You cannot use metadata to specify headers that begin with usr.WMQFTE or usr.com.ibm.wmqfte. If you specify metadata with a name beginning with WMQFTE or com.ibm.wmqfte this metadata is not used in the message properties and is ignored.

Parent topic: Managed File Transfer administration reference


Related reference


Related information