summaryrefslogtreecommitdiffstats
path: root/xlators/cluster/afr/src/afr-self-heal-entry.c
diff options
context:
space:
mode:
authorPranith Kumar K <pranithk@gluster.com>2011-09-02 08:50:48 +0530
committerAnand Avati <avati@gluster.com>2011-09-08 20:33:55 -0700
commit550148f3bb3505335909cde9e937c2362a1e67e3 (patch)
treec84f99aef6ab39f2d8c3fad8a6ae11e90fdd8014 /xlators/cluster/afr/src/afr-self-heal-entry.c
parent4d2afaae2f3c42b710acf8c7ebdb4b50d502b813 (diff)
cluster/afr: Make data selfheal trigger to be configurable.
By default, lookup triggers data self-heal but that is not the preferred way of operating replicated volumes. We would like the data self heals to be triggered in open instead. Number of back-ground self-heals allowed is 16 and lookups block until self-heal is completed. We want to prevent blocking in fops. We can not make lookups independent of self-heal frames because when there are gfid conflicts the decision of which file is correct is determined in self-heal phase. So in afr, lookup self-heal is going to guarantee name space consistency and open/fd fops will take responsibility for data consistency, these are non blocking. The user needs to set the option cluster.data-self-heal "open" for this behavior. Change-Id: If9463cdb9ebac114708558ec13bbca0270acd659 BUG: 3503 Reviewed-on: http://review.gluster.com/334 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Anand Avati <avati@gluster.com>
Diffstat (limited to 'xlators/cluster/afr/src/afr-self-heal-entry.c')
-rw-r--r--xlators/cluster/afr/src/afr-self-heal-entry.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/xlators/cluster/afr/src/afr-self-heal-entry.c b/xlators/cluster/afr/src/afr-self-heal-entry.c
index 8f1c96986..356b15e63 100644
--- a/xlators/cluster/afr/src/afr-self-heal-entry.c
+++ b/xlators/cluster/afr/src/afr-self-heal-entry.c
@@ -2328,7 +2328,7 @@ afr_self_heal_entry (call_frame_t *frame, xlator_t *this)
priv = this->private;
local = frame->local;
- if (local->self_heal.need_entry_self_heal && priv->entry_self_heal) {
+ if (local->self_heal.do_entry_self_heal && priv->entry_self_heal) {
afr_sh_entrylk (frame, this, &local->loc, NULL,
afr_sh_post_nonblocking_entry_cbk);
} else {