[IBM i]

CHGMQMTOP (Change MQ Topic)

Where allowed to run
All environments (*ALL)
Threadsafe
Yes

The Change MQ Topic (CHGMQMTOP) command changes the specified attributes of an existing MQ topic object.

Parameters

Table 1. Command parameters
Keyword Description Choices Notes
TOPNAME Topic name Character value Required, Key, Positional 1
MQMNAME Message Queue Manager name Character value, *DFT Optional, Key, Positional 2
TEXT Text 'description' Character value, *BLANK, *SAME Optional, Positional 3
TOPICSTR Topic string Character value, *BLANK, *SAME Optional, Positional 4
DURSUB Durable subscriptions *SAME, *ASPARENT, *YES, *NO Optional, Positional 5
MGDDURMDL Durable model queue Character value, *NONE, *SAME Optional, Positional 6
MGDNDURMDL Non-durable model queue Character value, *NONE, *SAME Optional, Positional 7
PUBENBL Publish *SAME, *ASPARENT, *YES, *NO Optional, Positional 8
SUBENBL Subscribe *SAME, *ASPARENT, *YES, *NO Optional, Positional 9
DFTPTY Default message priority 0-9, *SAME, *ASPARENT Optional, Positional 10
DFTMSGPST Default message persistence *SAME, *ASPARENT, *YES, *NO Optional, Positional 11
DFTPUTRESP Default Put Response *SAME, *ASPARENT, *SYNC, *ASYNC Optional, Positional 12
WILDCARD Wildcard behavior *SAME, *PASSTHRU, *BLOCK Optional, Positional 13
PMSGDLV Persistent message delivery *SAME, *ASPARENT, *ALL, *ALLDUR, *ALLAVAIL Optional, Positional 14
NPMSGDLV Non-persistent message deliver *SAME, *ASPARENT, *ALL, *ALLDUR, *ALLAVAIL Optional, Positional 15
CUSTOM Custom attribute Character value, *BLANK, *SAME Optional, Positional 16

Topic name (TOPNAME)

The name of the topic object to be changed.

The possible values are:

topic-name
Specify the name of the topic object. The maximum length of the string is 48 bytes.

Message Queue Manager name (MQMNAME)

Specifies the name of the Queue Manager.

The possible values are:

*DFT
Use the default Queue Manager.
queue-manager-name
The name of a Queue Manager.

Text 'description' (TEXT)

Specifies text that briefly describes the topic object.

Note: The field length is 64 bytes and the maximum number of characters is reduced if the system is using a double-byte character set (DBCS).

The possible values are:

*SAME
The attribute is unchanged.
*BLANK
The text is set to a blank string.
description
Specify no more than 64 characters enclosed in apostrophes.

Topic string (TOPICSTR)

Specifies the topic string represented by this topic object definition.

The possible values are:

*SAME
The attribute is unchanged.
topic-string
Specify a maximum of 256 bytes for the topic string.

Note: Topic strings of greater than 256 bytes can be specified using MQSC.

Durable subscriptions (DURSUB)

Specifies whether applications are permitted to make durable subscriptions on this topic.

The possible values are:

*SAME
The attribute is unchanged.
*ASPARENT
Whether durable subscriptions can be made on this topic is based on the setting of the first parent administrative node found in the topic tree relating to this topic.
*YES
Durable subscriptions can be made on this topic.
*NO
Durable subscriptions cannot be made on this topic.

Durable model queue (MGDDURMDL)

Specifies the name of the model queue to be used for durable subscriptions which request the queue manager manage the destination of publications.

The possible values are:

*SAME
The attribute is unchanged.
durable-model-queue
Specify the name of the model queue.

Non-durable model queue (MGDNDURMDL)

Specifies the name of the model queue to be used for non-durable subscriptions which request the queue manager manage the destination of publications.

The possible values are:

*SAME
The attribute is unchanged.
non-durable-model-queue
Specify the name of the model queue.

Publish (PUBENBL)

Specifies whether messages can be published to the topic.

The possible values are:

*SAME
The attribute is unchanged.
*ASPARENT
Whether messages can be published to this topic is based on the setting of the first parent administrative node found in the topic tree relating to this topic.
*YES
Messages can be published to the topic.
*NO
Messages cannot be published to the topic.

Subscribe (SUBENBL)

Specifies whether applications are to be permitted to subscribe to this topic.

The possible values are:

*SAME
The attribute is unchanged.
*ASPARENT
Whether applications can subscribe to this topic is based on the setting of the first parent administrative node found in the topic tree relating to this topic.
*YES
Subscriptions can be made to this topic.
*NO
Applications cannot subscribe to this topic.

Default message priority (DFTPTY)

Specifies the default priority of messages published to the topic.

The possible values are:

*SAME
The attribute is unchanged.
*ASPARENT
The default priority is based on the setting of the first parent administrative node found in the topic tree relating to this topic.
priority-value
Specify a value ranging from 0 through 9.

Default message persistence (DFTMSGPST)

Specifies the message persistence to be used when applications specify the MQPER_PERSISTENCE_AS_TOPIC_DEF option.

The possible values are:

*SAME
The attribute is unchanged.
*ASPARENT
The default persistence is based on the setting of the first parent administrative node found in the topic tree relating to this topic.
*YES
Messages on this queue survive a restart of the queue manager.
*NO
Messages on this queue are lost across a restart of the queue manager.

Default Put Response (DFTPUTRESP)

Specifies the type of response required for MQPUT and MQPUT1 calls when applications specify the MQPMO_RESPONSE_AS_Q_DEF option.

The possible values are:

*SAME
The attribute is unchanged.
*ASPARENT
The default response type is based on the setting of the first parent administrative node found in the topic tree relating to this topic.
*SYNC
Specifying this value ensures that the put operations to the queue that specify MQPMO_RESPONSE_AS_Q_DEF are issued as if MQPMO_SYNC_RESPONSE had been specified instead. Fields in the MQMD and MQPMO are returned by the queue manager to the application.
*ASYNC
Specifying this value ensures that the put operations to the queue that specify MQPMO_RESPONSE_AS_Q_DEF are always issued as if MQPMO_ASYNC_RESPONSE had been specified instead. Some fields in the MQMD and MQPMO are not returned by the queue manager to the application. An improvement in performance may be seen for messages put in a transaction or any non-persistent messages.

Wildcard behavior (WILDCARD)

Specifies the behavior of wildcard subscriptions with respect to this topic.

The possible values are:

*SAME
The attribute is unchanged.
*PASSTHRU
Subscriptions made to a wildcarded topic less specific than the topic string at this topic object will receive publications made to this topic and to topic strings more specific than this topic.
*BLOCK
Subscriptions made to a wildcarded topic less specific than the topic string at this topic object will not receive publications made to this topic or to topic strings more specific than this topic.

Persistent message delivery (PMSGDLV)

Specifies the delivery mechanism for persistent messages published to this topic.

The possible values are:

*SAME
The attribute is unchanged.
*ASPARENT
The delivery mechanism used is based on the setting of the first parent administrative node found in the topic tree relating to this topic.
*ALL
Persistent messages must be delivered to all subscribers, irrespective of durability for the MQPUT call to report success. If a delivery failure to any subscriber occurs, no other subscribers receive the message and the MQPUT call fails.
*ALLDUR
Persistent messages must be delivered to all durable subscribers. Failure to deliver a persistent message to any non-durable subscribers does not return an error to the MQPUT call. If a delivery failure to a durable subscriber occurs, no subscribers receive the message and the MQPUT call fails.
*ALLAVAIL
Persistent messages are delivered to all subscribers that can accept the message. Failure to deliver the message to any subscriber does not prevent other subscribers from receiving the message.

Non-persistent message delivery (NPMSGDLV)

Specifies the delivery mechanism for non-persistent messages published to this topic.

The possible values are:

*SAME
The attribute is unchanged.
*ASPARENT
The delivery mechanism used is based on the setting of the first parent administrative node found in the topic tree relating to this topic.
*ALL
Non-persistent messages must be delivered to all subscribers, irrespective of durability for the MQPUT call to report success. If a delivery failure to any subscriber occurs, no other subscribers receive the message and the MQPUT call fails.
*ALLDUR
Non-persistent messages must be delivered to all durable subscribers. Failure to deliver a persistent message to any non-durable subscribers does not return an error to the MQPUT call. If a delivery failure to a durable subscriber occurs, no subscribers receive the message and the MQPUT call fails.
*ALLAVAIL
Non-persistent messages are delivered to all subscribers that can accept the message. Failure to deliver the message to any subscriber does not prevent other subscribers from receiving the message.

Custom attribute (CUSTOM)

This attribute is reserved for the configuration of new features before separate attributes have been introduced. This description will be updated when features using this attribute are introduced. At the moment there are no meaningful values for CUSTOM, so leave it empty.

The possible values are:

*SAME
The attribute is unchanged.
*BLANK
The text is set to a blank string.
custom
Specify zero or more attributes as pairs of attribute name and value, separated by at least one space. The attribute name-value pairs must have the form NAME(VALUE) and be specified in uppercase. Single quotes must be escaped with another single quote.