afr: honour selfheal enable/disable volume set options
authorRavishankar N <ravishankar@redhat.com>
Sat, 30 May 2015 04:53:33 +0000 (10:23 +0530)
committerPranith Kumar Karampuri <pkarampu@redhat.com>
Wed, 3 Jun 2015 10:50:47 +0000 (03:50 -0700)
commitda111ae21429d33179cd11409bc171fae9d55194
tree75b00dccac53a17255c6e856fb39fa1c8dc7a5da
parent9798a24febba9bbf28e97656b81b8a01a1325f68
afr: honour selfheal enable/disable volume set options

afr-v1 had the following volume set options that are used to enable/ disable
self-heals from happening in AFR xlator when loaded in the client graph:
cluster.metadata-self-heal
cluster.data-self-heal
cluster.entry-self-heal

In afr-v2, these 3 heals can happen from the client if there is an inode
refresh. This patch allows such heals to proceed only if the corresponding
volume set options are set to true.

Change-Id: I8d97d6020611152e73a269f3fdb607652c66cc86
BUG: 1226507
Signed-off-by: Ravishankar N <ravishankar@redhat.com>
Reviewed-on: http://review.gluster.org/11012
Tested-by: NetBSD Build System <jenkins@build.gluster.org>
Tested-by: Gluster Build System <jenkins@build.gluster.com>
Reviewed-by: Pranith Kumar Karampuri <pkarampu@redhat.com>
tests/basic/afr/client-side-heal.t [new file with mode: 0644]
xlators/cluster/afr/src/afr-common.c
xlators/cluster/afr/src/afr-self-heal-common.c