19.03.2015 Views

www.it-ebooks.info

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

Chapter 2<br />

Tuxedo also provides a server called TMQFORWARD, which dequeues a message and<br />

forwards <strong>it</strong> to other services. Messages can be retrieved in any of several ordering<br />

schemes, including Last In, First Out (LIFO), First In, First Out (FIFO), prior<strong>it</strong>y order,<br />

and time-based order. More than one client or server can access the same queue. In<br />

Chapter 3, Development of Tuxedo – Various APIs, I have discussed the Tuxedo queue<br />

in more detail; I am avoiding repet<strong>it</strong>ion, so please refer to the Queues (Tuxedo /Q)<br />

section of that chapter.<br />

There are three primary tasks for a Tuxedo administrator to carry out. They are<br />

configuring, maintaining, and mon<strong>it</strong>oring the Tuxedo queue.<br />

Configuration of resources for /Q<br />

There are three servers (TMS, TMQUEUE, and TMQFORWARD) provided by the Tuxedo<br />

system that need to be configured in the SERVER section of the UBBCONFIG file.<br />

Also, there must be a server group defined for each queue space as per the<br />

application usage or design. The TMSNAME and OPENINFO parameters need to be set<br />

accordingly; please see the following example in the UBBCONFIG file:<br />

*GROUPS<br />

TMQUEUE-G1<br />

GRPNO=1 TMSNAME=TMS_QM<br />

OPENINFO="TUXEDO/QM:/dev/deviceONE:QueueSpace1"<br />

*SERVERS<br />

TMQUEUE SRVGRP="TMQUEUE-G1" SRVID=1550 RESTART=Y GRACE=0 \<br />

CLOPT="-s CUSTOMER:TMQUEUE"<br />

In this example, the -s flag of the CLOPT parameter is used to name the queue space<br />

served by a given instance of the server.<br />

We mentioned that the environment variable for the queue (/Q)<br />

is QMCONFIG, which needs to be set in the environment.<br />

Creation of queue space and queues<br />

To use a queue, we need to create the queue devices, queue space, and queues, in<br />

that order; qmadmin is the tool provided by the Tuxedo system to do this for us.<br />

%UnixPromt%> qmadmin<br />

> crdl /home/applicationQ/CustomerQdev 0 500<br />

[ 61 ]<br />

<strong>www</strong>.<strong>it</strong>-<strong>ebooks</strong>.<strong>info</strong>

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!