summaryrefslogtreecommitdiffstats
path: root/xlators/cluster/afr
diff options
context:
space:
mode:
authorAnand Avati <avati@redhat.com>2013-08-07 16:04:23 -0700
committerVijay Bellur <vbellur@redhat.com>2013-08-11 11:13:02 -0700
commita1fe3d040a8c9b032cbcb5e831383628cddfa39a (patch)
treea6354058a5dc4b54143344ee4b7ee17ac734b731 /xlators/cluster/afr
parente0890b723519519b3a979940b982a0ea37d2daa3 (diff)
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 <avati@redhat.com> Reviewed-on: http://review.gluster.org/5528 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Vijay Bellur <vbellur@redhat.com>
Diffstat (limited to 'xlators/cluster/afr')
-rw-r--r--xlators/cluster/afr/src/afr-dir-read.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/xlators/cluster/afr/src/afr-dir-read.c b/xlators/cluster/afr/src/afr-dir-read.c
index 799c55919b8..689dd84e646 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