Data Queue APIs--Categories - FTP Directory Listing - IBM

Data Queue APIs--Categories - FTP Directory Listing - IBM Data Queue APIs--Categories - FTP Directory Listing - IBM

as400bks.rochester.ibm.com
from as400bks.rochester.ibm.com More from this publisher
30.06.2013 Views

Create User Queue (QUSCRTUQ) API Create User Queue (QUSCRTUQ) API Required Parameter Group: 1 Qualified user queue name Input Char(20) 2 Extended attribute Input Char(10) 3 Queue type Input Char(1) 4 Key length Input Binary(4) 5 Maximum message size Input Binary(4) 6 Initial number of messages Input Binary(4) 7 Additional number of messages Input Binary(4) 8 Public authority Input Char(10) 9 Text description Input Char(50) Optional Parameter Group 1: 10 Replace Input Char(10) 11 Error code I/O Char(*) Optional Parameter Group 2: 12 Domain Input Char(10) 13 Pointers Input Char(10) Optional Parameter Group 3: 14 Number of queue extensions Input Binary(4) 15 Reclaim storage Input Char(1) Threadsafe: Yes The Create User Queue (QUSCRTUQ) API creates a user queue in either the user domain or the system domain, based on the input parameters. A user-domain user queue can be directly manipulated with MI instructions. If you are running at security level 40 or greater, you cannot directly manipulate a system-domain user queue using MI instructions. If the number of queue extensions is not specified, user queues can grow to a maximum of 16MB in size, though some of that is used for the queue definition. If the number of queue extensions is specified and non-zero, the queue will be extended by the number of additional messages specified until either the number of queue extensions is reached or the storage limit of 32MB is reached. The system can automatically extend user queues, so you should create a small queue and allow the system to extend the queue as needed. Smaller queues provide better performance and use less storage. However, the system does not automatically reduce the size of the queue if it is too large. If you specify the additional number of messages as 0, the system does not extend the user queue you create when the queue is full. http://infocntr.rchland.ibm.com/pubs/html/as400/v4r5/ic2924/info/apis/quscrtuq.htm (1 of 9) [10/4/1999 2:33:25 PM]

Create User Queue (QUSCRTUQ) API To decrease the size of a user queue, a user must delete the queue and create it again. There are no APIs to manipulate user queue entries. If you must access a user queue object in a library that does not permit user-domain user objects, you must use data queue objects. For information about data queues, refer to the CL Programming book. If you need to know into which domain the user queue object was created, use either of the following APIs to retrieve that information: ● Retrieve Object Description (QUSROBJD) API ● List Object (QUSLOBJ) API Note: For performance reasons, the *USRQ object is created before checking to see if it exists in the library specified for the qualified user queue name. If you have an application using this API repeatedly, even if you are using *NO for the replace parameter, permanent system addresses will be used. Note:User queues created with either the number of queue extensions parameter specified with a positive, non-zero number or the reclaim storage parameter specified to reclaim the user queue storage are not eligible to save to a pre-V4R5 system. Authorities and Locks Library Authority *READ and *ADD. User Queue Authority *OBJMGT, *OBJEXIST, and *READ. These authorities are required only if the replace parameter is used and if there is an existing user queue to replace. User Queue Lock *EXCL. This applies to both the user queue being created and an existing user queue being replaced. Required Parameter Group Qualified user queue name INPUT; CHAR(20) The first 10 characters contain the user queue name, and the second 10 characters contain the name of the library where the user queue is located. The only special value supported is *CURLIB. User queues created in the QTEMP and QRPLOBJ libraries are not forced to permanent storage; they are deleted when those libraries are cleared at sign-off and system IPL, respectively. Extended attribute INPUT; CHAR(10) The extended attribute of the user queue. For example, an object type of *FILE has an extended attribute of PF (physical file), LF (logical file), DSPF (display file), SAVF (save file), and so on. The extended attribute must be a valid *NAME. You can enter this parameter in uppercase, http://infocntr.rchland.ibm.com/pubs/html/as400/v4r5/ic2924/info/apis/quscrtuq.htm (2 of 9) [10/4/1999 2:33:25 PM]

Create User <strong>Queue</strong> (QUSCRTUQ) API<br />

Create User <strong>Queue</strong> (QUSCRTUQ) API<br />

Required Parameter Group:<br />

1 Qualified user queue name Input Char(20)<br />

2 Extended attribute Input Char(10)<br />

3 <strong>Queue</strong> type Input Char(1)<br />

4 Key length Input Binary(4)<br />

5 Maximum message size Input Binary(4)<br />

6 Initial number of messages Input Binary(4)<br />

7 Additional number of messages Input Binary(4)<br />

8 Public authority Input Char(10)<br />

9 Text description Input Char(50)<br />

Optional Parameter Group 1:<br />

10 Replace Input Char(10)<br />

11 Error code I/O Char(*)<br />

Optional Parameter Group 2:<br />

12 Domain Input Char(10)<br />

13 Pointers Input Char(10)<br />

Optional Parameter Group 3:<br />

14 Number of queue extensions Input Binary(4)<br />

15 Reclaim storage Input Char(1)<br />

Threadsafe: Yes<br />

The Create User <strong>Queue</strong> (QUSCRTUQ) API creates a user queue in either the user domain or the system<br />

domain, based on the input parameters. A user-domain user queue can be directly manipulated with MI<br />

instructions. If you are running at security level 40 or greater, you cannot directly manipulate a<br />

system-domain user queue using MI instructions.<br />

If the number of queue extensions is not specified, user queues can grow to a maximum of 16MB in<br />

size, though some of that is used for the queue definition. If the number of queue extensions is specified<br />

and non-zero, the queue will be extended by the number of additional messages specified until either the<br />

number of queue extensions is reached or the storage limit of 32MB is reached.<br />

The system can automatically extend user queues, so you should create a small queue and allow the<br />

system to extend the queue as needed. Smaller queues provide better performance and use less storage.<br />

However, the system does not automatically reduce the size of the queue if it is too large. If you specify<br />

the additional number of messages as 0, the system does not extend the user queue you create when the<br />

queue is full.<br />

http://infocntr.rchland.ibm.com/pubs/html/as400/v4r5/ic2924/info/apis/quscrtuq.htm (1 of 9) [10/4/1999 2:33:25 PM]

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

Saved successfully!

Ooh no, something went wrong!