libdb/docs/programmer_reference/rep_pri.html
2011-09-13 13:44:24 -04:00

81 lines
3.6 KiB
HTML
Raw Blame History

This file contains invisible Unicode characters

This file contains invisible Unicode characters that are indistinguishable to humans but may be processed differently by a computer. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
<title>Replication environment priorities</title>
<link rel="stylesheet" href="gettingStarted.css" type="text/css" />
<meta name="generator" content="DocBook XSL Stylesheets V1.73.2" />
<link rel="start" href="index.html" title="Berkeley DB Programmer's Reference Guide" />
<link rel="up" href="rep.html" title="Chapter 12.  Berkeley DB Replication" />
<link rel="prev" href="rep_id.html" title="Replication environment IDs" />
<link rel="next" href="rep_app.html" title="Building replicated applications" />
</head>
<body>
<div xmlns="" class="navheader">
<div class="libver">
<p>Library Version 11.2.5.2</p>
</div>
<table width="100%" summary="Navigation header">
<tr>
<th colspan="3" align="center">Replication environment priorities</th>
</tr>
<tr>
<td width="20%" align="left"><a accesskey="p" href="rep_id.html">Prev</a> </td>
<th width="60%" align="center">Chapter 12. 
Berkeley DB Replication
</th>
<td width="20%" align="right"> <a accesskey="n" href="rep_app.html">Next</a></td>
</tr>
</table>
<hr />
</div>
<div class="sect1" lang="en" xml:lang="en">
<div class="titlepage">
<div>
<div>
<h2 class="title" style="clear: both"><a id="rep_pri"></a>Replication environment priorities</h2>
</div>
</div>
</div>
<p>Each database environment included in a replication group must have
a priority, which specifies a relative ordering among the different
environments in a replication group. This ordering is a factor in
determining which environment will be selected as a new master in case
the existing master fails. Both Replication Manager applications and
Base API applications should specify
environment priorities.</p>
<p>Priorities are an unsigned integer, but do not need to be unique
throughout the replication group. A priority of 0 means the system can
never become a master. Otherwise, larger valued priorities
indicate a more desirable master. For example, if a replication group
consists of three database environments, two of which are connected by
an OC3 and the third of which is connected by a T1, the third database
environment should be assigned a priority value which is lower than
either of the other two.</p>
<p>Desirability of the master is first determined by the client having
the most recent log records. Ties in log records are broken with
the client priority. If both sites have the same log
and the same priority, one is selected at random.</p>
</div>
<div class="navfooter">
<hr />
<table width="100%" summary="Navigation footer">
<tr>
<td width="40%" align="left"><a accesskey="p" href="rep_id.html">Prev</a> </td>
<td width="20%" align="center">
<a accesskey="u" href="rep.html">Up</a>
</td>
<td width="40%" align="right"> <a accesskey="n" href="rep_app.html">Next</a></td>
</tr>
<tr>
<td width="40%" align="left" valign="top">Replication environment IDs </td>
<td width="20%" align="center">
<a accesskey="h" href="index.html">Home</a>
</td>
<td width="40%" align="right" valign="top"> Building replicated applications</td>
</tr>
</table>
</div>
</body>
</html>