Accounting message format

Accounting messages comprise a set of PCF fields that consist of a message descriptor and message data.

Message descriptor
  • An accounting message MQMD (message descriptor)
Accounting message data
  • An accounting message MQCFH (PCF header)
  • Accounting message data that is always returned
  • Accounting message data that is returned if available

The accounting message MQCFH (PCF header) contains information about the application, and the interval for which the accounting data was recorded.

Accounting message data comprises PCF parameters that store the accounting information. The content of accounting messages depends on the message category as follows:

MQI accounting message
MQI accounting message data consists of a number of PCF parameters, but no PCF groups.
Queue accounting message
Queue accounting message data consists of a number of PCF parameters, and in the range 1 through 100 QAccountingData PCF groups.

There is one QAccountingData PCF group for every queue that had accounting data collected. If an application accesses more than 100 queues, multiple accounting messages are generated. Each message has the SeqNumber in the MQCFH (PCF header) updated accordingly, and the last message in the sequence has the Control parameter in the MQCFH specified as MQCFC_LAST.