[SCM] CTDB repository - branch master updated - ctdb-2.1-201-gb697625

Amitay Isaacs amitay at samba.org
Fri May 24 06:07:25 MDT 2013


The branch, master has been updated
       via  b697625b184227dad1be31a41b7a3fd9bd312e29 (commit)
       via  d9e24782a90d9ce29c0e6584b75d2b186142174d (commit)
       via  9a21d417c51fb9cad8f2e87e00ca54d379aef860 (commit)
      from  c57430998a3bdedc8a904eb3a9cdfde1421aff50 (commit)

http://gitweb.samba.org/?p=ctdb.git;a=shortlog;h=master


- Log -----------------------------------------------------------------
commit b697625b184227dad1be31a41b7a3fd9bd312e29
Author: Michael Adam <obnox at samba.org>
Date:   Fri May 17 11:05:44 2013 +0200

    ctdbd: fix comment explaining redirection of CTDB_REQ_CALL redirection.
    
    Signed-off-by: Michael Adam <obnox at samba.org>

commit d9e24782a90d9ce29c0e6584b75d2b186142174d
Author: Michael Adam <obnox at samba.org>
Date:   Fri May 17 11:01:31 2013 +0200

    ctdbd: remove a nonempty blank line
    
    Signed-off-by: Michael Adam <obnox at samba.org>

commit 9a21d417c51fb9cad8f2e87e00ca54d379aef860
Author: Michael Adam <obnox at samba.org>
Date:   Fri May 17 11:00:32 2013 +0200

    ctdbd: update comment describing ctdb_call_send_redirect()
    
    Signed-off-by: Michael Adam <obnox at samba.org>

-----------------------------------------------------------------------

Summary of changes:
 server/ctdb_call.c |   21 ++++++---------------
 1 files changed, 6 insertions(+), 15 deletions(-)


Changeset truncated at 500 lines:

diff --git a/server/ctdb_call.c b/server/ctdb_call.c
index dbbebec..a98903d 100644
--- a/server/ctdb_call.c
+++ b/server/ctdb_call.c
@@ -113,20 +113,9 @@ static void ctdb_send_error(struct ctdb_context *ctdb,
  * to its local ctdb (ctdb_request_call). If the node is not itself
  * the record's DMASTER, it first redirects the packet to  the
  * record's LMASTER. The LMASTER then redirects the call packet to
- * the current DMASTER. But there is a race: The record may have
- * been migrated off the DMASTER while the redirected packet is
- * on the wire (or in the local queue). So in case the record has
- * migrated off the new destinaton of the call packet, instead of
- * going back to the LMASTER to get the new DMASTER, we try to
- * reduce round-trips by first chasing the record a couple of times
- * before giving up the direct chase and finally going back to the
- * LMASTER (again). Note that this works because of this: When
+ * the current DMASTER. Note that this works because of this: When
  * a record is migrated off a node, then the new DMASTER is stored
  * in the record's copy on the former DMASTER.
- *
- * The maximum number of attempts for direct chase to make before
- * going back to the LMASTER is configurable by the tunable
- * "MaxRedirectCount".
  */
 static void ctdb_call_send_redirect(struct ctdb_context *ctdb,
 				    struct ctdb_db_context *ctdb_db,
@@ -134,7 +123,6 @@ static void ctdb_call_send_redirect(struct ctdb_context *ctdb,
 				    struct ctdb_req_call *c, 
 				    struct ctdb_ltdb_header *header)
 {
-	
 	uint32_t lmaster = ctdb_lmaster(ctdb, &key);
 
 	c->hdr.destnode = lmaster;
@@ -813,8 +801,11 @@ void ctdb_request_call(struct ctdb_context *ctdb, struct ctdb_req_header *hdr)
 		return;
 	}
 
-	/* if we are not the dmaster and are not hosting any delegations,
-	   then send a redirect to the requesting node */
+	/*
+	 * If we are not the dmaster and are not hosting any delegations,
+	 * then we redirect the request to the node than can answer it
+	 * (the lmaster or the dmaster).
+	 */
 	if ((header.dmaster != ctdb->pnn) 
 	    && (!(header.flags & CTDB_REC_RO_HAVE_DELEGATIONS)) ) {
 		talloc_free(data.dptr);


-- 
CTDB repository


More information about the samba-cvs mailing list