summaryrefslogtreecommitdiffstats
path: root/xlators
diff options
context:
space:
mode:
authorshishir gowda <sgowda@redhat.com>2012-06-22 13:28:31 +0530
committerVijay Bellur <vbellur@redhat.com>2012-08-01 20:57:30 -0700
commit31e81065edc26378eabdd4785f5dd689719cd126 (patch)
treed2030cb65e91b98bf3aec6a8ecb97ce7e8a71319 /xlators
parent84d0f889eab947b58a0f6e8d0eda5ae84c15a6c7 (diff)
cluster/dht: Remove dht dependency on glusterfsd-mgmt
glusterfs_ctx->notify can be used by any xlator to talk to glusterfsd-mgmt. Note- This is for any rpc communication initiated by the xlator, and not from glusterd. Change-Id: Ic0e4af106fe1e98d797ca621facda8839b87598a BUG: 835757 Signed-off-by: shishir gowda <sgowda@redhat.com> Reviewed-on: http://review.gluster.com/3610 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Jeff Darcy <jdarcy@redhat.com> Reviewed-by: Vijay Bellur <vbellur@redhat.com>
Diffstat (limited to 'xlators')
-rw-r--r--xlators/cluster/dht/src/dht-rebalance.c8
1 files changed, 7 insertions, 1 deletions
diff --git a/xlators/cluster/dht/src/dht-rebalance.c b/xlators/cluster/dht/src/dht-rebalance.c
index d348a7fb5ab..ba2df528a2e 100644
--- a/xlators/cluster/dht/src/dht-rebalance.c
+++ b/xlators/cluster/dht/src/dht-rebalance.c
@@ -1404,11 +1404,16 @@ gf_defrag_start_crawl (void *data)
dict_t *fix_layout = NULL;
dict_t *migrate_data = NULL;
dict_t *status = NULL;
+ glusterfs_ctx_t *ctx = NULL;
this = data;
if (!this)
goto out;
+ ctx = glusterfs_ctx_get ();
+ if (!ctx)
+ goto out;
+
conf = this->private;
if (!conf)
goto out;
@@ -1480,7 +1485,8 @@ out:
{
status = dict_new ();
gf_defrag_status_get (defrag, status);
- glusterfs_rebalance_event_notify (status);
+ if (ctx->notify)
+ ctx->notify (GF_EN_DEFRAG_STATUS, status);
if (status)
dict_unref (status);
defrag->is_exiting = 1;