Messagequeue
This task performs IBM MQM get and put opertions to a specified queue or topic.
This is useful if the scenario is another user type than MessageQueueUser
, but the scenario still requires an action towards an MQ server.
Use Transformer task to extract specific parts of the message.
Grizzly must have been installed with the extra mq
package and native IBM MQ libraries must be installed for being able to use this variable:
pip3 install grizzly-loadtester[mq]
Step implementations
Arguments
-
direction
RequestDirection - if the request is upstream or downstream -
endpoint
str - specifies details to be able to perform the request, e.g. account and container information -
name
str - name used inlocust
statistics -
destination
str (optional) - not used by this client -
source
str (optional) - file path of local file that should be put onendpoint
Format
endpoint
mq[s]://<username>:<password>@]<hostname>[:<port>]/<endpoint>?QueueManager=<queue manager>&Channel=<channel>[&wait=<wait>][&heartbeat=<heartbeat>][&KeyFile=<key repo path>[&SslCipher=<ssl cipher>][&CertLabel=<certificate label>]][&HeaderType=<header type>][&MaxMessageSize=<number of bytes>]
All variables in the endpoint have support for Templating.
-
mq[s]
str - must be specified,mqs
implies connecting with TLS, ifKeyFile
is not set in querystring, it will look for a key repository in./<username>
-
username
str (optional) - username to authenticate with, defaultNone
-
password
str (optional) - password to authenticate with, defaultNone
-
hostname
str - hostname of MQ server -
port
int (optional) - port on MQ server, default1414
-
endpoint
str - prefixed with eithertopic:
orqueue:
and then the name of the endpoint to perform operations on -
wait
int (optional) - number of seconds to wait for an message, default is to wait infinite (0 seconds) -
heartbeat
int (optional) - number of seconds between heartbeats, default is 300 seconds -
QueueManager
str - name of queue manager -
Channel
str - name of channel to connect to -
KeyFile
str (optional) - path to key repository for certificates needed to connect over TLS -
SslCipher
str (optional) - SSL cipher to use for connection, defaultECDHE_RSA_AES_256_GCM_SHA384
-
CertLabel
str (optional) - label of certificate in key repository, defaultusername
-
HeaderType
str (optional) - header type, can beRFH2
for sending gzip compressed messages using RFH2 header, defaultNone
-
MaxMessageSize
int (optional) - maximum number of bytes a message can be for the client to accept it, default isNone
which implies that the client will throwMQRC_TRUNCATED_MSG_FAILED
, adjust buffer and try again.