From a1fe3d040a8c9b032cbcb5e831383628cddfa39a Mon Sep 17 00:00:00 2001 From: Anand Avati Date: Wed, 7 Aug 2013 16:04:23 -0700 Subject: cluster/afr: skip directory inspection when entry self-heal is off When user has explicitly configured to disable entry self-heal in the client, it is wrong to do the healing in opendir. So skip it. This is especially useful to reduce opendir() times after graph switches. Change-Id: Ic6eb9ff2334a5b8417f2f35410a366a536bad5df Signed-off-by: Anand Avati Reviewed-on: http://review.gluster.org/5528 Tested-by: Gluster Build System Reviewed-by: Vijay Bellur --- xlators/cluster/afr/src/afr-dir-read.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'xlators') diff --git a/xlators/cluster/afr/src/afr-dir-read.c b/xlators/cluster/afr/src/afr-dir-read.c index 799c5591..689dd84e 100644 --- a/xlators/cluster/afr/src/afr-dir-read.c +++ b/xlators/cluster/afr/src/afr-dir-read.c @@ -253,7 +253,7 @@ unlock: goto out; if (!afr_is_opendir_done (this, local->fd->inode) && - up_children_count > 1) { + up_children_count > 1 && priv->entry_self_heal) { /* * This is the first opendir on this inode. We need -- cgit