ibm-information-center/dist/eclipse/plugins/i5OS.ic.rbam6_5.4.0.1/alloq.htm

73 lines
4.8 KiB
HTML

<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE html
PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html lang="en-us" xml:lang="en-us">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<meta name="security" content="public" />
<meta name="Robots" content="index,follow" />
<meta http-equiv="PICS-Label" content='(PICS-1.1 "http://www.icra.org/ratingsv02.html" l gen true r (cz 1 lz 1 nz 1 oz 1 vz 1) "http://www.rsac.org/ratingsv01.html" l gen true r (n 0 s 0 v 0 l 0) "http://www.classify.org/safesurf/" l gen true r (SS~~000 1))' />
<meta name="DC.Type" content="task" />
<meta name="DC.Title" content="Allocate data queues" />
<meta name="abstract" content="If all users of a data queue allocate it before using it, this helps to ensure that a data queue is not accessed by more than one job at a time." />
<meta name="description" content="If all users of a data queue allocate it before using it, this helps to ensure that a data queue is not accessed by more than one job at a time." />
<meta name="DC.subject" content="data queue, allocating, sending data" />
<meta name="keywords" content="data queue, allocating, sending data" />
<meta name="DC.Relation" scheme="URI" content="qcomm.htm" />
<meta name="DC.Relation" scheme="URI" content="../cl/alcobj.htm" />
<meta name="DC.Relation" scheme="URI" content="../cl/dlcobj.htm" />
<meta name="DC.Relation" scheme="URI" content="../cl/monmsg.htm" />
<meta name="DC.Relation" scheme="URI" content="monmg.htm" />
<meta name="copyright" content="(C) Copyright IBM Corporation 1998, 2006" />
<meta name="DC.Rights.Owner" content="(C) Copyright IBM Corporation 1998, 2006" />
<meta name="DC.Format" content="XHTML" />
<meta name="DC.Identifier" content="alloq" />
<meta name="DC.Language" content="en-us" />
<!-- All rights reserved. Licensed Materials Property of IBM -->
<!-- US Government Users Restricted Rights -->
<!-- Use, duplication or disclosure restricted by -->
<!-- GSA ADP Schedule Contract with IBM Corp. -->
<link rel="stylesheet" type="text/css" href="./ibmdita.css" />
<link rel="stylesheet" type="text/css" href="./ic.css" />
<title>Allocate data queues</title>
</head>
<body id="alloq"><a name="alloq"><!-- --></a>
<!-- Java sync-link --><script language="Javascript" src="../rzahg/synch.js" type="text/javascript"></script>
<h1 class="topictitle1">Allocate data queues</h1>
<div><p>If all users of a data queue allocate it before using it, this
helps to ensure that a data queue is not accessed by more than one job at
a time.</p>
<div class="section"> <p>If your application requires that a data queue is not accessed
by more than one job at a time, it should be coded to include an <span class="cmdname">Allocate
Object (ALCOBJ)</span> command before using a data queue. The data queue
should then be deallocated using the <span class="cmdname">Deallocate Object (DLCOBJ)</span> command
when the application is finished using it.</p>
<p>The ALCOBJ command does <em>not</em>,
by itself, restrict another job from sending or receiving data from a data
queue or clearing a data queue. However, if all applications are coded to
include the ALCOBJ command before any use of a data queue, the allocation
of a data queue already allocated to another job will fail, preventing the
data queue from use by more than one job at a time.</p>
<p>When an allocation
fails because the data queue is already allocated to another job, the system
issues an error message, CPF1002. The <span class="cmdname">Monitor Message (MONMSG)</span> command
can be used in the application procedure to monitor for this message and respond
to the error message. Possible responses include sending a message to the
user and attempting to allocate the data queue again. </p>
</div>
</div>
<div>
<div class="familylinks">
<div class="parentlink"><strong>Parent topic:</strong> <a href="qcomm.htm" title="Data queues are a type of system object that you can create, to which one HLL procedure or program can send data, and from which another HLL procedure or program can receive data.">Use data queues</a></div>
</div>
<div class="reltasks"><strong>Related tasks</strong><br />
<div><a href="monmg.htm" title="You can monitor for exception messages. Exception messages include escape, notify, and status messages that are sent to your CL procedure's or program's call message queue by the commands in your procedure or program or by commands in another procedure or program. Diagnostic messages cannot be monitored.">Monitor for messages in a CL program or procedure</a></div>
</div>
<div class="relinfo"><strong>Related information</strong><br />
<div><a href="../cl/alcobj.htm">Allocate Object (ALCOBJ) command</a></div>
<div><a href="../cl/dlcobj.htm">Deallocate Object (DLCOBJ) command</a></div>
<div><a href="../cl/monmsg.htm">Monitor Message (MONMSG) command</a></div>
</div>
</div>
</body>
</html>