Chapter 7 Get Server
Get Server
This section will describe how to invoke and use the Get Server Stress Testing tool. The Get Server will continuously consume messages from a queue and show statistics of its current state.
For the Stress Testing Servers (Get, Put, SIM Client & SIM Server), you can have unlimited number of them running (up to what your box can support). Also, while any of the Servers are running, the user can still use MQ Batch Toolkit.
Purpose
Use the GetServer command to remove the messages of a particular queue of a queue manager.
Syntax
{mqbt or mqbt.sh} GetServer -a Path_and_FileName_for_CommProfileDB -p Profile_Name -q Queue_Name {-d Days -h Minutes -m Hours -n Max_Message_Count} [-s Start_Position]
Function Name:
GetServer
Required Parameters:
-a The full path and filename for a CommProfileDB.properties file.
-p The name of a profile contained in the CommProfileDB.properties file.
-q The name of the queue (Note: Queue names are case sensitive.)
Requires at least 1 of the following parameters:
-d Consumes messages for 'x' days.
-h Consumes messages for 'x' hours.
-m Consumes messages for 'x' minutes.
-n Maximum number of messages to be read from the queue before terminating.
Example 1
Consume the messages from a queue of a queue manager for 4 hours.
Windows
mqbt GetServer -a c:\CommProfileDB.properties -p MQA1 -q TEST01.Q -h 4
Unix
./mqbt.sh GetServer -a /Capitalware/MQBT/CommProfileDB.properties -p MQA1 -q TEST01.Q -h 4
Example 2
Consume the messages from a queue of a queue manager for 8 days, 4 hours and 35 minutes.
Windows
mqbt GetServer -a c:\CommProfileDB.properties -p MQA1 -q TEST01.Q -d 8 -h 4 -m 35
Unix
./mqbt.sh GetServer -a /Capitalware/MQBT/CommProfileDB.properties -p MQA1 -q TEST01.Q -d 8 -h 4 -m 35
Example 3
Consume the messages from a queue of a queue manager until 5000 mesasges have been consumed.
Windows
mqbt GetServer -a c:\CommProfileDB.properties -p MQA1 -q TEST01.Q -n 5000
Unix
./mqbt.sh GetServer -a /Capitalware/MQBT/CommProfileDB.properties -p MQA1 -q TEST01.Q -n 5000
|