ibm-information-center/dist/eclipse/plugins/i5OS.ic.apis_5.4.0.1/xaxunreg.htm

153 lines
4.2 KiB
HTML
Raw Permalink Normal View History

2024-04-02 14:02:31 +00:00
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<meta name="Copyright" content="Copyright (c) 2006 by IBM Corporation">
<title>ax_unreg()--Exit Program to Dynamically Unregister an XA Resource
Manager</title>
<!-- 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. -->
<!-- Begin Header Records ========================================== -->
<!-- UNIX11 SCRIPT A converted by B2H R4.1 (346) (CMS) by V2DCIJB at -->
<!-- RCHVMW2 on 1 Jun 1999 at 16:14:12 -->
<!--End Header Records -->
<link rel="stylesheet" type="text/css" href="../rzahg/ic.css">
</head>
<body>
<!-- Java sync-link -->
<script type="text/javascript" language="Javascript" src="../rzahg/synch.js">
</script>
<a name="Top_Of_Page"></a>
<h2>ax_unreg()--Exit Program to Dynamically Unregister an XA Resource Manager (Job Scoped Locks)</h2>
<div class="box" style="width: 60%;">
<br>
&nbsp;&nbsp;Syntax<br>
<pre>
#include &lt;xa.h&gt;
int ax_unreg(int <em>rmid</em>, long <em>flags</em>);
</pre>
<br>
&nbsp;&nbsp;Threadsafe: Conditional; see <a href="#USAGE">Usage Notes</a>.<br>
<!-- iddvc RMBR -->
<br>
</div>
<p>The XA resource manager calls <strong>ax_unreg()</strong> to inform a
transaction manager that it has completed work on a local transaction. The
local transaction was started after receiving a <em>NULLXID</em> from
<strong>ax_reg()</strong>.</p>
<p>The XA resource manager indicates that it uses the dynamic registration
facility by setting the <em>TMREGISTER</em> value in the <em>flags</em>
element of its <em>xa_switch_t</em> structure.</p>
<p>The name of the service program that contains <strong>ax_reg()</strong> and
<strong>ax_unreg()</strong> must be provided to the XA resource manager in the
<em>*xa_info</em> parameter of the <strong>db2xa_open()</strong> call.</p>
<h3>Parameters</h3>
<dl>
<dt><strong>rmid</strong></dt>
<dd>(Input) The resource manager identifier that was generated by a transaction
manager when the resource manager was opened.</dd>
<dt><strong>flags</strong></dt>
<dd>(Input) The <em>flags</em> argument must be set to this value.
<em>TMNOFLAGS:</em> 0x00000000L No flags are defined for this function.</dd>
</dl>
<br>
<h3>Authorities</h3>
<p>None</p>
<br>
<h3>Return Value</h3>
<table cellpadding="5">
<tr>
<td align="left" valign="top" nowrap><em>-3</em> </td>
<td align="left" valign="top">[TMER_PROTO]
<p><strong>ax_unreg()</strong> was not successful. Function was called in an
improper context.</p>
</td>
</tr>
<tr>
<td align="left" valign="top"><em>-2</em> </td>
<td align="left" valign="top">[TMER_INVAL]
<p><strong>ax_unreg()</strong> was not successful. Incorrect arguments were
specified.</p>
</td>
</tr>
<tr>
<td align="left" valign="top"><em>-1</em> </td>
<td align="left" valign="top">[TMER_TMERR]
<p><strong>ax_unreg()</strong> was not successful. The transaction manager
detected an error when unregistering the resource.</p>
</td>
</tr>
<tr>
<td align="left" valign="top"><em>0</em> </td>
<td align="left" valign="top">[TM_OK]
<p><strong>ax_unreg()</strong> was successful.</p>
</td>
</tr>
</table>
<br>
<br>
<h3><a name="USAGE">Usage Notes</a></h3>
<ol>
<li>This function must be threadsafe if the transaction manager calls the XA
APIs in a multithreaded job.</li>
</ol>
<br>
<h3>Related Information</h3>
<ul>
<li>X/Open CAE Specification, December 1991, Distributed Transaction
Processing: The XA Specification (ISBN:1-872630-24-3, C193 or XO/CAE/91/300),
The Open Group.</li>
<li>X/Open CAE Specification, April 1995, Distributed Transaction Processing:
The TX (Transaction Demarcation) Specification (ISBN:1-85912-094-6, C504), The
Open Group.</li>
</ul>
<br>
<hr>
Exit program introduced: V4R3
<hr>
<center>
<table cellpadding="2" cellspacing="2">
<tr align="center">
<td valign="middle" align="center"><a href="#Top_Of_Page">Top</a> | <a href=
"unix.htm">UNIX-Type APIs</a> | <a href="aplist.htm">APIs by category</a> </td>
</tr>
</table></center>
</body>
</html>