The remote queue manager cannot report errors such as failing to put a message on a queue when you make your MQI call, but it can send you a report message to say how it has processed your message.
Within your application you can create (MQPUT) report messages as well as select the option to receive them (in which case they will be sent by either another application or by a queue manager).
Report messages provide a mechanism for an application to inform another application that it is unable to deal with the message that was sent. However, the Report field must initially be analyzed to determine whether or not the application that sent the message is interested in being informed of any problems. Having determined that a report message is required, you have to decide:
Use the Feedback field to indicate the reason for the report message being generated. Put your report messages on an application's reply-to queue. Refer to WebSphere MQ Application Programming Reference for further information.
When you send a message to another application, you will not be informed of any problems unless you complete the Report field to indicate the feedback you require. The options available to you are in WebSphere MQ Application Programming Reference.
Queue managers always put report messages on an application's reply-to queue and it is recommended that your own applications do the same. When you use the report message facility you must specify the name of your reply-to queue in the message descriptor of your message; otherwise, the MQPUT call fails.
Your application should contain procedures that monitor your reply-to queue and process any messages that arrive on it. Remember that a report message can contain all the original message, the first 100 bytes of the original message, or none of the original message.
The queue manager sets the Feedback field of the report message to indicate the reason for the error; for example, the target queue does not exist. Your programs should do the same.
For more information on report messages, see Report messages.