[Sheepdog] [RFC PATCH 2/4] sheep: add debug output to use for testing

MORITA Kazutaka morita.kazutaka at lab.ntt.co.jp
Fri Oct 28 06:08:26 CEST 2011


Signed-off-by: MORITA Kazutaka <morita.kazutaka at lab.ntt.co.jp>
---
 sheep/group.c |    8 ++++++++
 1 files changed, 8 insertions(+), 0 deletions(-)

diff --git a/sheep/group.c b/sheep/group.c
index d9bf201..0807214 100644
--- a/sheep/group.c
+++ b/sheep/group.c
@@ -758,6 +758,10 @@ static void __sd_join_done(struct cpg_event *cevent)
 		if (nr_zones >= sys->nr_sobjs)
 			sys_stat_set(SD_STATUS_OK);
 	}
+
+	if (node_cmp(&w->joined, &sys->this_node) == 0)
+		/* this output is used for testing */
+		vprintf(SDOG_DEBUG, "join Sheepdog cluster\n");
 }
 
 static void __sd_leave_done(struct cpg_event *cevent)
@@ -1206,6 +1210,10 @@ static void sd_join_handler(struct sheepdog_node_list_entry *joined,
 			update_epoch_log(sys->epoch);
 			update_epoch_store(sys->epoch);
 		}
+
+		if (node_cmp(&w->joined, &sys->this_node) == 0)
+			/* this output is used for testing */
+			vprintf(SDOG_DEBUG, "join Sheepdog cluster\n");
 		break;
 	}
 }
-- 
1.7.2.5




More information about the sheepdog mailing list