3.3.5.2 Preparing a Change Notification Message Version 0x01
The directory service MUST create a Change Notification Message (section 2.2.4) that includes Notification Updates (section 2.2.6) as follows:
The Command field MUST be set to 0x00 to indicate that a queue object was created in the directory service; or it MUST be set to 0x01 to indicate that a queue or machine object was updated; or it MUST be set to 0x02 to indicate that a queue object was deleted.
The UseGuid field MUST be set to 0x00 if the Command field is set to 0x00 to indicate that the PathName field is being used. For other values of the Command field, the UseGuid field MUST be set to 0x01 to indicate that the GuidIdentifier field is being used.
The PathName field MUST be set to a null-terminated value if the UseGuid field is set to 0x00 and MUST be omitted if the UseGuid field is set to 0x01.
If the UseGuid field is set to 0x01, the GuidIdentifier field MUST be set to the GUID of either the queue object or the machine object that was changed.
The GuidMasterId field MUST be set to the GUID of the directory service that originated the change notification message.
The NumberOfProperties field MUST be set to the number of properties contained within each Notification Update.
The PropertyId array field MUST be filled with property identifiers, and its number of elements MUST be equal to the NumberOfProperties field. The set of property identifiers varies as follows:
If the Command field is set to 0x00 (created) and the created object is a queue object, the following property identifiers MUST be included within the PropertyId array field in any order:
PROPID_Q_TYPE ([MS-MQMQ] section 2.3.1.2)
PROPID_Q_INSTANCE ([MS-MQMQ] section 2.3.1.1)
PROPID_Q_BASEPRIORITY ([MS-MQMQ] section 2.3.1.6)
PROPID_Q_JOURNAL ([MS-MQMQ] section 2.3.1.4)
PROPID_Q_QUOTA ([MS-MQMQ] section 2.3.1.5)
PROPID_Q_JOURNAL_QUOTA ([MS-MQMQ] section 2.3.1.7)
PROPID_Q_CREATE_TIME ([MS-MQMQ] section 2.3.1.9)
PROPID_Q_MODIFY_TIME ([MS-MQMQ] section 2.3.1.10
PROPID_Q_SCOPE ([MS-MQMQ] section 2.3.1.14)
PROPID_Q_SECURITY ([MS-MQMQ] section 2.3.1.25)
PROPID_Q_PATHNAME ([MS-MQMQ] section 2.3.1.3)
PROPID_Q_LABEL ([MS-MQMQ] section 2.3.1.8)
PROPID_Q_AUTHENTICATE ([MS-MQMQ] section 2.3.1.11)
PROPID_Q_PRIV_LEVEL ([MS-MQMQ] section 2.3.1.12)
PROPID_Q_TRANSACTION ([MS-MQMQ] section 2.3.1.13)
This property MUST NOT be included. The receiving queue manager MUST ignore this property if received:
PROPID_Q_ADS_PATH ([MS-MQMQ] section 2.3.1.24)
If the Command field is set to 0x01 (updated) and the modified object is a queue object, the following property MUST be included within the PropertyId array field:
PROPID_Q_QMID ([MS-MQMQ] section 2.3.1.15)
The rest of the PropertyId array field MUST be filled with the identifiers of the properties that were modified for the queue object specified in the GuidIdentifier field.
These properties can be modified:
PROPID_Q_JOURNAL ([MS-MQMQ] section 2.3.1.4)
PROPID_Q_QUOTA
PROPID_Q_BASEPRIORITY
PROPID_Q_JOURNAL_QUOTA
PROPID_Q_SECURITY
PROPID_Q_AUTHENTICATE
PROPID_Q_PRIV_LEVEL
If the Command field is set to 0x01 (updated) and the modified object is a machine object, the following properties MUST be included within the PropertyId array field in any order:
PROPID_QM_MACHINE_ID ([MS-MQMQ] section 2.3.2.2)
PROPID_QM_FOREIGN ([MS-MQMQ] section 2.3.2.18)
The rest of the PropertyId array field MUST be filled with the identifiers of the properties that were modified for the machine object specified in the GuidIdentifier field.
These properties can be modified:
PROPID_QM_QUOTA ([MS-MQMQ] section 2.3.2.10)
PROPID_QM_JOURNAL_QUOTA ([MS-MQMQ] section 2.3.2.14)
PROPID_QM_SECURITY ([MS-MQMQ] section 2.3.2.36)
The following properties can be included but are ignored on the Server side of this protocol.<11>
PROPID_QM_ADDRESS ([MS-MQMQ] section 2.3.2.5)
PROPID_QM_CNS ([MS-MQMQ] section 2.3.2.6
PROPID_QM_MACHINE_TYPE ([MS-MQMQ] section 2.3.2.15)
PROPID_QM_OS ([MS-MQMQ] section 2.3.2.19)
If the Command field is set to 0x02 (deleted) and the modified object is a queue object, the PropertyId array field MUST be filled as follows:
PropertyId[0] = PROPID_D_SCOPE ([MS-MQMQ] section 2.3.13.3)
PropertyId[1] = PROPID_D_OBJTYPE ([MS-MQMQ] section 2.3.13.4)
Each PropertyValue array field element MUST be filled according to the rules specified in this document and in [MS-MQMQ] for the value of the corresponding PropertyId array field element. In addition, the following PropertyValue array field elements MUST be set according to the following rules:
If the Command field is set to 0x02 (deleted) and the modified object is a queue object, the PropertyValue array field elements MUST be filled as follows:
PropertyValue[0] = MQDS_ENTERPRISESCOPE ([MS-MQMQ] section 2.3.13.3)
PropertyValue[1] = MQDS_QUEUE ([MS-MQMQ] section 2.3.13.4)
The Change Notification Message MUST be created as follows. The Version field MUST be set to 0x01. The NumberOfUpdateNotifications field MUST be set to the number of Notification Update instances to be included in the Data field. A directory service can send more than one notification message at a time. The Data field MUST be filled with the Notification Update instances that MUST be created as specified in this section.
Finally, the Change Notification Message MUST be included within a Message ([MS-MQDMPR] section 3.1.1.12) ADM element instance and MUST be sent through MSMQ to the destination queue manager, as specified in section 3.3.5.3.