From 780b92ada9afcf1d58085a83a0b9e6bc982203d1 Mon Sep 17 00:00:00 2001 From: Lorry Tar Creator Date: Tue, 17 Feb 2015 17:25:57 +0000 Subject: Imported from /home/lorry/working-area/delta_berkeleydb/db-6.1.23.tar.gz. --- docs/programmer_reference/rep_mgr_meth.html | 181 ++++++++++++++++------------ 1 file changed, 101 insertions(+), 80 deletions(-) (limited to 'docs/programmer_reference/rep_mgr_meth.html') diff --git a/docs/programmer_reference/rep_mgr_meth.html b/docs/programmer_reference/rep_mgr_meth.html index 24cd6ae9..63add04e 100644 --- a/docs/programmer_reference/rep_mgr_meth.html +++ b/docs/programmer_reference/rep_mgr_meth.html @@ -9,12 +9,12 @@ - +

- Applications which use the Replication Manager support generally - call the following Berkeley DB methods. The general pattern is to - call various methods to configure Replication Manager, and then - start it by calling DB_ENV->repmgr_start(). Once this initialization is - complete, the application rarely needs to call any of these - methods. (A prime example of an exception to this rule would be - the DB_ENV->rep_sync() method, if the application is + Applications which use the Replication Manager support + generally call the following Berkeley DB methods. The general + pattern is to call various methods to configure Replication + Manager, and then start it by calling DB_ENV->repmgr_start(). Once this + initialization is complete, the application rarely needs to + call any of these methods. (A prime example of an exception to + this rule would be the DB_ENV->rep_sync() method, if the application is Delaying client synchronization.)

@@ -57,38 +55,41 @@

- The DB_SITE handle is used to configure a site that - belongs to the replication group. You can obtain a DB_SITE - handle by calling the DB_ENV->repmgr_site() method. When you do this, you - provide the TCP/IP host name and port that the replication - site uses for incoming connections. + The DB_SITE handle is used to configure a site + that belongs to the replication group. You can + obtain a DB_SITE handle by calling the + DB_ENV->repmgr_site() method. When you do this, you + provide the TCP/IP host name and port that the + replication site uses for incoming connections.

-

+

Once you have the DB_SITE handle, you use the - DB_SITE->set_config() method to configure the handle. One of - the things you can configure about the handle is whether it - is the local site (using the DB_LOCAL_SITE - parameter). You must configure one and only one DB_SITE handle - to be a local site before you start replication. + DB_SITE->set_config() method to configure the + handle. One of the things you can configure about + the handle is whether it is the local site (using + the DB_LOCAL_SITE parameter). + You must configure one and only one DB_SITE + handle to be a local site before you start + replication.

-

- You can also optionally configure DB_SITE handles for - remote sites to help Replication Manager startup more - efficiently. Note that it is usually not necessary for - each site in the replication group initially to know about - all other sites in the group. Sites can discover each - other dynamically, as described in - Connecting to a new site. +

+ You can also optionally configure DB_SITE + handles for remote sites to help Replication + Manager start up more efficiently. Note that it is + usually not necessary for each site in the + replication group initially to know about all + other sites in the group. Sites can discover each + other dynamically, as described in Connecting to a new site.

-

- Once you have configured your DB_SITE handles, you start - replication using DB_ENV->repmgr_start(). +

+ Once you have configured your DB_SITE handles, + you start replication using DB_ENV->repmgr_start().

-

- When you are shutting down your application, you must - use the DB_SITE->close() method to close - all your open DB_SITE handles before you close your - environment handles. +

+ When you are shutting down your application, + you must use the DB_SITE->close() method to close + all your open DB_SITE handles before you close + your environment handles.

@@ -97,13 +98,15 @@
-

- The DB_ENV->repmgr_set_ack_policy() method configures the acknowledgement - policy to be used in the replication group, in other words, the - behavior of the master with respect to acknowledgements for - "permanent" messages, which implements the application's - requirements for Transactional guarantees. The current implementation - requires all sites in the replication group to configure the same +

+ The DB_ENV->repmgr_set_ack_policy() method configures the + acknowledgement policy to be used in the + replication group, in other words, the behavior of + the master with respect to acknowledgements for + "permanent" messages, which implements the + application's requirements for Transactional guarantees. + The current implementation requires all sites + in the replication group to configure the same acknowledgement policy.

@@ -113,9 +116,9 @@
-

- The DB_ENV->rep_set_priority() method configures the local site's priority - for the purpose of elections. +

+ The DB_ENV->rep_set_priority() method configures the local + site's priority for the purpose of elections.

@@ -124,17 +127,19 @@
-

- This method optionally configures various timeout values. - Otherwise default timeout values as specified in DB_ENV->rep_set_timeout() - are used. In particular, Replication Manager client sites can - be configured to monitor the health of the TCP/IP connection to - the master site using heartbeat messages. If the client - receives no messages from the master for a certain amount of - time, it considers the connection to be broken, and calls for - an election to choose a new master. Heartbeat messages - also help clients request missing master changes in the - absence of master activity. +

+ This method optionally configures various + timeout values. Otherwise default timeout values + as specified in DB_ENV->rep_set_timeout() are used. In + particular, Replication Manager client sites can + be configured to monitor the health of the TCP/IP + connection to the master site using heartbeat + messages. If the client receives no messages from + the master for a certain amount of time, it + considers the connection to be broken, and calls + for an election to choose a new master. Heartbeat + messages also help clients request missing master + changes in the absence of master activity.

@@ -144,13 +149,14 @@

- Once configured and started, Replication Manager does virtually - all of its work in the background, usually without the need for - any direct communication with the application. However, - occasionally events occur which the application may be - interested in knowing about. The application can request - notification of these events by calling the DB_ENV->set_event_notify() - method. + Once configured and started, Replication + Manager does virtually all of its work in the + background, usually without the need for any + direct communication with the application. + However, occasionally events occur which the + application may be interested in knowing about. + The application can request notification of these + events by calling the DB_ENV->set_event_notify() method.

@@ -159,25 +165,40 @@
-

- The DB_ENV->repmgr_start() method starts the replication system. It - opens the listening TCP/IP socket and creates all the - background processing threads that will be needed. +

+ The DB_ENV->repmgr_start() method starts the replication + system. It opens the listening TCP/IP socket and + creates all the background processing threads that + will be needed.

- In addition to the methods previously described, Replication Manager - applications may also call the following methods, as needed: - DB_ENV->rep_set_config(), DB_ENV->rep_set_limit(), DB_ENV->rep_set_request(), DB_ENV->rep_sync() and DB_ENV->rep_stat(). + In addition to the methods previously described, + Replication Manager applications may also call the following + methods, as needed: DB_ENV->rep_set_config(), DB_ENV->rep_set_limit(), DB_ENV->rep_set_request(), + DB_ENV->rep_sync() and DB_ENV->rep_stat(). +

+

+ If a Replication Manager replication group contains only two + sites and one particular site should be master whenever + possible, the replication group can be configured to run in + preferred master mode. For more information, see + Preferred master mode. +

+

+ Replication Manager applications may configure one or more + view sites. A view is a full or partial copy of the replicated + data that does not otherwise participate in the replication + group. For more information, see Replication views.

- Finally, Replication Manager applications can also make use of the - Replication Manager's message channels. This allows the various - sites in the replication group to pass messages that are tailored - to the application's requirements. For more information, see - Using Replication Manager message channels. + Finally, Replication Manager applications can also make use + of the Replication Manager's message channels. This allows the + various sites in the replication group to pass messages that + are tailored to the application's requirements. For more + information, see Using Replication Manager message channels.

-- cgit v1.2.1