| 1 | <?xml version="1.0" encoding="UTF-8" standalone="no"?> |
| 2 | <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> |
| 3 | <html xmlns="http://www.w3.org/1999/xhtml"> |
| 4 | <head> |
| 5 | <meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /> |
| 6 | <title>DB_ENV->get_timeout()</title> |
| 7 | <link rel="stylesheet" href="apiReference.css" type="text/css" /> |
| 8 | <meta name="generator" content="DocBook XSL Stylesheets V1.73.2" /> |
| 9 | <link rel="start" href="index.html" title="Berkeley DB C API Reference" /> |
| 10 | <link rel="up" href="env.html" title="Chapter 5. The DB_ENV Handle" /> |
| 11 | <link rel="prev" href="envget_thread_count.html" title="DB_ENV->get_thread_count()" /> |
| 12 | <link rel="next" href="envget_tmp_dir.html" title="DB_ENV->get_tmp_dir()" /> |
| 13 | </head> |
| 14 | <body> |
| 15 | <div xmlns="" class="navheader"> |
| 16 | <div class="libver"> |
| 17 | <p>Library Version 11.2.5.3</p> |
| 18 | </div> |
| 19 | <table width="100%" summary="Navigation header"> |
| 20 | <tr> |
| 21 | <th colspan="3" align="center">DB_ENV->get_timeout()</th> |
| 22 | </tr> |
| 23 | <tr> |
| 24 | <td width="20%" align="left"><a accesskey="p" href="envget_thread_count.html">Prev</a> </td> |
| 25 | <th width="60%" align="center">Chapter 5. |
| 26 | The DB_ENV Handle |
| 27 | </th> |
| 28 | <td width="20%" align="right"> <a accesskey="n" href="envget_tmp_dir.html">Next</a></td> |
| 29 | </tr> |
| 30 | </table> |
| 31 | <hr /> |
| 32 | </div> |
| 33 | <div class="sect1" lang="en" xml:lang="en"> |
| 34 | <div class="titlepage"> |
| 35 | <div> |
| 36 | <div> |
| 37 | <h2 class="title" style="clear: both"><a id="envget_timeout"></a>DB_ENV->get_timeout()</h2> |
| 38 | </div> |
| 39 | </div> |
| 40 | </div> |
| 41 | <pre class="programlisting">#include <db.h> |
| 42 | |
| 43 | int |
| 44 | DB_ENV->get_timeout(DB_ENV *dbenv, db_timeout_t *timeoutp, |
| 45 | u_int32_t flag); </pre> |
| 46 | <p> |
| 47 | The <code class="methodname">DB_ENV->get_timeout()</code> method returns a value, in |
| 48 | microseconds, representing either lock or transaction timeouts. These values are set using the |
| 49 | <a class="xref" href="envset_timeout.html" title="DB_ENV->set_timeout()">DB_ENV->set_timeout()</a> |
| 50 | method. |
| 51 | </p> |
| 52 | <p> |
| 53 | The <code class="methodname">DB_ENV->get_timeout()</code> method may be called at any time during the |
| 54 | life of the application. |
| 55 | </p> |
| 56 | <p> |
| 57 | The <code class="methodname">DB_ENV->get_timeout()</code> <span> |
| 58 | <span> |
| 59 | method returns a non-zero error value on failure and 0 on success. |
| 60 | </span> |
| 61 | |
| 62 | </span> |
| 63 | </p> |
| 64 | <div class="sect2" lang="en" xml:lang="en"> |
| 65 | <div class="titlepage"> |
| 66 | <div> |
| 67 | <div> |
| 68 | <h3 class="title"><a id="idp51594664"></a>Parameters</h3> |
| 69 | </div> |
| 70 | </div> |
| 71 | </div> |
| 72 | <div class="sect3" lang="en" xml:lang="en"> |
| 73 | <div class="titlepage"> |
| 74 | <div> |
| 75 | <div> |
| 76 | <h4 class="title"><a id="idp51594016"></a>timeoutp</h4> |
| 77 | </div> |
| 78 | </div> |
| 79 | </div> |
| 80 | <p> |
| 81 | The <span class="bold"><strong>timeoutp</strong></span> parameter references |
| 82 | memory into which the timeout value of the specified <span class="bold"><strong>flag</strong></span> parameter is copied. |
| 83 | </p> |
| 84 | </div> |
| 85 | <div class="sect3" lang="en" xml:lang="en"> |
| 86 | <div class="titlepage"> |
| 87 | <div> |
| 88 | <div> |
| 89 | <h4 class="title"><a id="idp51588968"></a>flag</h4> |
| 90 | </div> |
| 91 | </div> |
| 92 | </div> |
| 93 | <p> |
| 94 | The <span class="bold"><strong>flags</strong></span> parameter must be set to |
| 95 | one of the following values: |
| 96 | </p> |
| 97 | <div class="itemizedlist"> |
| 98 | <ul type="disc"> |
| 99 | <li> |
| 100 | <p><a id="get_timeout_DB_SET_LOCK_TIMEOUT"></a> |
| 101 | <code class="literal">DB_SET_LOCK_TIMEOUT</code> |
| 102 | </p> |
| 103 | <p> |
| 104 | Return the timeout value for locks in this database environment. |
| 105 | </p> |
| 106 | </li> |
| 107 | <li> |
| 108 | <p><a id="get_timeout_DB_SET_REG_TIMEOUT"></a> |
| 109 | <code class="literal">DB_SET_REG_TIMEOUT</code> |
| 110 | </p> |
| 111 | <p> |
| 112 | Return the timeout value for how long to wait for |
| 113 | processes to exit the environment before |
| 114 | recovery is started. This flag only has meaning |
| 115 | when the <a class="xref" href="envopen.html" title="DB_ENV->open()">DB_ENV->open()</a> |
| 116 | method was called with the |
| 117 | <a class="link" href="envopen.html#envopen_DB_REGISTER">DB_REGISTER</a> |
| 118 | flag and recovery must be performed. |
| 119 | </p> |
| 120 | </li> |
| 121 | <li> |
| 122 | <p><a id="get_timeout_DB_SET_TXN_TIMEOUT"></a> |
| 123 | <code class="literal">DB_SET_TXN_TIMEOUT</code> |
| 124 | </p> |
| 125 | <p> |
| 126 | Return the timeout value for transactions in this database |
| 127 | environment. |
| 128 | </p> |
| 129 | </li> |
| 130 | </ul> |
| 131 | </div> |
| 132 | </div> |
| 133 | </div> |
| 134 | <div class="sect2" lang="en" xml:lang="en"> |
| 135 | <div class="titlepage"> |
| 136 | <div> |
| 137 | <div> |
| 138 | <h3 class="title"><a id="idp51602376"></a>Class</h3> |
| 139 | </div> |
| 140 | </div> |
| 141 | </div> |
| 142 | <p> |
| 143 | <a class="link" href="env.html" title="Chapter 5. The DB_ENV Handle">DB_ENV</a> |
| 144 | </p> |
| 145 | </div> |
| 146 | <div class="sect2" lang="en" xml:lang="en"> |
| 147 | <div class="titlepage"> |
| 148 | <div> |
| 149 | <div> |
| 150 | <h3 class="title"><a id="idp51598416"></a>See Also</h3> |
| 151 | </div> |
| 152 | </div> |
| 153 | </div> |
| 154 | <p> |
| 155 | <a class="xref" href="env.html#envlist" title="Database Environments and Related Methods">Database Environments and Related Methods</a>, |
| 156 | <a class="xref" href="envset_timeout.html" title="DB_ENV->set_timeout()">DB_ENV->set_timeout()</a> |
| 157 | </p> |
| 158 | </div> |
| 159 | </div> |
| 160 | <div class="navfooter"> |
| 161 | <hr /> |
| 162 | <table width="100%" summary="Navigation footer"> |
| 163 | <tr> |
| 164 | <td width="40%" align="left"><a accesskey="p" href="envget_thread_count.html">Prev</a> </td> |
| 165 | <td width="20%" align="center"> |
| 166 | <a accesskey="u" href="env.html">Up</a> |
| 167 | </td> |
| 168 | <td width="40%" align="right"> <a accesskey="n" href="envget_tmp_dir.html">Next</a></td> |
| 169 | </tr> |
| 170 | <tr> |
| 171 | <td width="40%" align="left" valign="top">DB_ENV->get_thread_count() </td> |
| 172 | <td width="20%" align="center"> |
| 173 | <a accesskey="h" href="index.html">Home</a> |
| 174 | </td> |
| 175 | <td width="40%" align="right" valign="top"> DB_ENV->get_tmp_dir()</td> |
| 176 | </tr> |
| 177 | </table> |
| 178 | </div> |
| 179 | </body> |
| 180 | </html> |