manageWMQ command
Use the manageWMQ command to manage the settings of the IBM MQ resource adapter that is installed at a particular scope.
To run the command, use the AdminTask object of the wsadmin scripting client.
The wsadmin scripting client is run from Qshell. For more
information, see the topic "Configure Qshell to run WebSphere® Application Server scripts".
This command is valid only when it is used with WebSphere Application Server Version 7 and later application servers. Do not use it with earlier versions.
print AdminTask.help('WMQAdminCommands')
print AdminTask.help('command_name')
AdminConfig.save()
Purpose
Use the manageWMQ command to manage the settings associated with the IBM MQ resource adapter that is installed at a particular scope.
You can use the manageWMQ command to manage the native library path and query the metadata of the specified IBM MQ resource adapter.
Target object
A IBM MQ resource adapter.
Required parameters
None.
Optional parameters
- -nativePath
- This parameter specifies the path to the IBM MQ messaging provider native libraries that are used by the IBM MQ resource adapter to establish a bindings mode connection to the queue manager. This parameter can be specified on a IBM MQ adapter at any scope.
- -query
- This parameter provides information about the level of IBM MQ resource adapter that is used by the IBM MQ messaging provider. This parameter can be specified on a IBM MQ resource adapter at any scope.
-enableInbound
This parameter enables inbound Java™ Platform, Enterprise Edition (Java EE) Connector Architecture (JCA) message delivery to IBM MQ resource adapter activation specifications on the z/OS® platform. This value can only be specified if the target IBM MQ resource adapter is at server scope. An application server restart is required for these changes to take effect.
The value of this parameter must be true or false.
The default value is false.
- -disableWMQ
- This parameter specifies whether or not to disable IBM MQ functionality at the scope
of the specified resource adapter, and at all scopes following it.
The value of this parameter must be true or false.
The default value is false.
In a single server environment this parameter is valid only at the server scope. In a network deployment environment this parameter is valid at all scopes. The affect of setting this parameter to true depends on the scope at which you set it:
- For a cell scoped IBM MQ resource adapter, all IBM MQ functionality on all application servers in the cell is disabled.
- For a node scoped IBM MQ resource adapter, all IBM MQ functionality on all application servers that are part of that node is disabled.
- For a cluster scoped IBM MQ resource adapter, all IBM MQ functionality on all application servers in that cluster are disabled.
- For a server scoped IBM MQ resource adapter, all IBM MQ functionality in that particular application server is disabled.
In all cases, all affected processes must be restarted for the changes to take effect.
The value of the parameter at a higher scope takes precedence over the value at a lower scope. For example, if you set the parameter to false at the server scope but a higher (for example, cell) scoped IBM MQ messaging provider has the parameter set to true, the value at the cell scope takes precedence and IBM MQ functionality is therefore disabled in all application servers in the cell, regardless of the parameter value at the server scope.
- -maxConnections
- This parameter specifies the maximum number of connections to
a IBM MQ queue manager.
The default value is 10.
For further information, see Configuration of the ResourceAdapter object in the IBM MQ information center.
- -connectionConcurrency
- This parameter specifies the maximum number of message-driven
beans that can be supplied by each connection.
The default value is 1.
Setting this property only affects WebSphere Application Server 7 nodes. The property has no effect for WebSphere Application Server Version 8 or later nodes.
For further information, see Configuration of the ResourceAdapter object in the IBM MQ information center.
- -reconnectionRetryCount
- This parameter specifies the maximum number of attempts made by
a IBM MQ messaging provider
activation specification to reconnect to a IBM MQ queue manager if a connection
fails.
The default value is 5.
For further information, see Configuration of the ResourceAdapter object in the IBM MQ information center.
- -reconnectionRetryInterval
- This parameter specifies the time, in milliseconds, that a IBM MQ messaging provider activation
specification waits prior to making another attempt to reconnect to
a IBM MQ queue manager.
The default value is 300000.
For further information, see Configuration of the ResourceAdapter object in the IBM MQ information center.
- -customProperties
- This parameter specifies custom properties to be passed to the IBM MQ resource adapter. Typically,
custom properties are used to set attributes of the IBM MQ resource adapter that are
not directly supported through the WebSphere Application Server administration
interfaces. Each custom property is specified using name and value table step parameters. Since these are table steps, the order of the two parameters is fixed, so you must always specify the name first and the value second:
- In Jython: [name value]
- In Jacl: {name value}
New name/value pairs are added to the existing set of custom properties using the following rules:- If the existing set of properties does not contain a property with the same name as that which is supplied, the supplied property is added to the set of custom properties, unless the custom property has no value specified, when it is disregarded.
- If the existing set of properties contains a property with the same name as that supplied as part of a modify command, and the modify command also specifies a value for the property, the existing value is replaced by the supplied value.
- If the existing set of properties contains a property with the same name as that supplied as part of a modify command, but the modify command does not specify a value for the property, the property with the same name is deleted from the existing set of custom properties.
Examples
The following example shows how to enable inbound JCA message delivery on the z/OS platform.- Using
Jython:
wsadmin>AdminTask.manageWMQ("IBM MQ Resource Adapter (cells/L3A3316Node04Cell/nodes/L3A3316Node05/servers/server1|resources.xml# J2CResourceAdapter_1201601803796)", ["-enableInbound true"])
- Using
Jacl:
wsadmin>$AdminTask manageWMQ "IBM MQ Resource Adapter (cells/L3A3316Node04Cell/nodes/L3A3316Node05/servers/server1|resources.xml# J2CResourceAdapter_1201601803796)" {-enableInbound true}
- Using
Jython:
AdminTask.manageWMQ("IBM MQ Resource Adapter( cells/L3A3316Node01Cell|resources.xml#J2CResourceAdapter_1284547647859)", ["-maxConnections 100 -customProperties [[name1 value1]]"])
- Using
Jacl:
wsadmin>$AdminTask manageWMQ "IBM MQ Resource Adapter( cells/L3A3316Node01Cell|resources.xml#J2CResourceAdapter_1284547647859)" {-maxConnections 100 -customProperties {{name1 value1}}}