From 7445700d0323cbfac11b0e1367b0052438e38318 Mon Sep 17 00:00:00 2001 From: Vikas Gorur Date: Sat, 24 Oct 2009 08:17:36 +0000 Subject: cluster/afr: Set read-subvolume to the source while self-heal is in progress. Just before the lookup is unwound during background data self-heal, the read subvolume is set to the self-heal source subvol so that read operations on the file work correctly, and don't have to wait for the self-heal to complete. Signed-off-by: Anand V. Avati BUG: 320 (Improve self-heal performance) URL: http://bugs.gluster.com/cgi-bin/bugzilla3/show_bug.cgi?id=320 --- xlators/cluster/afr/src/afr-self-heal-data.c | 1 + 1 file changed, 1 insertion(+) (limited to 'xlators/cluster/afr') diff --git a/xlators/cluster/afr/src/afr-self-heal-data.c b/xlators/cluster/afr/src/afr-self-heal-data.c index 718c716f55a..2118fd66df5 100644 --- a/xlators/cluster/afr/src/afr-self-heal-data.c +++ b/xlators/cluster/afr/src/afr-self-heal-data.c @@ -769,6 +769,7 @@ afr_sh_data_fix (call_frame_t *frame, xlator_t *this) } if (sh->background) { + afr_set_read_child (this, local->loc.inode, sh->source); sh->unwind (frame, this); } -- cgit