summaryrefslogtreecommitdiffstats
path: root/xlators/mgmt/glusterd/src/glusterd-sm.c
diff options
context:
space:
mode:
authorAmar Tumballi <amar@gluster.com>2011-11-13 00:18:32 +0530
committerVijay Bellur <vijay@gluster.com>2011-11-16 01:45:24 -0800
commita29ab15988f46fbe98151c37676185de970fb187 (patch)
tree7e768d2fdcfca5e1f1a26b524c2acfb700067d15 /xlators/mgmt/glusterd/src/glusterd-sm.c
parent7a97478dd1a343fcc5d9d4eab963882191a3de69 (diff)
glusterd/cli: rpc cleanup
no more backward compatibility between glusterd <-> glusterd Change-Id: Ibfcca1c7e315a90b2639c4cba8da19b11875051a BUG: 3158 Reviewed-on: http://review.gluster.com/610 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Shishir Gowda <shishirng@gluster.com> Reviewed-by: Krishnan Parthasarathi <kp@gluster.com> Reviewed-by: Vijay Bellur <vijay@gluster.com>
Diffstat (limited to 'xlators/mgmt/glusterd/src/glusterd-sm.c')
-rw-r--r--xlators/mgmt/glusterd/src/glusterd-sm.c20
1 files changed, 10 insertions, 10 deletions
diff --git a/xlators/mgmt/glusterd/src/glusterd-sm.c b/xlators/mgmt/glusterd/src/glusterd-sm.c
index af054c9aebd..2518ee0d496 100644
--- a/xlators/mgmt/glusterd/src/glusterd-sm.c
+++ b/xlators/mgmt/glusterd/src/glusterd-sm.c
@@ -168,7 +168,7 @@ glusterd_broadcast_friend_delete (char *hostname, uuid_t uuid)
goto out;
list_for_each_entry (peerinfo, &priv->peers, uuid_list) {
- if (!peerinfo->connected || !peerinfo->mgmt)
+ if (!peerinfo->connected || !peerinfo->peer)
continue;
ret = dict_set_static_ptr (friends, "peerinfo", peerinfo);
@@ -177,7 +177,7 @@ glusterd_broadcast_friend_delete (char *hostname, uuid_t uuid)
goto out;
}
- proc = &peerinfo->mgmt->proctable[GLUSTERD_MGMT_FRIEND_UPDATE];
+ proc = &peerinfo->peer->proctable[GLUSTERD_FRIEND_UPDATE];
if (proc->fn) {
ret = proc->fn (NULL, this, friends);
}
@@ -286,9 +286,9 @@ glusterd_ac_friend_add (glusterd_friend_sm_event_t *event, void *ctx)
GF_ASSERT (conf);
- if (!peerinfo->mgmt)
+ if (!peerinfo->peer)
goto out;
- proc = &peerinfo->mgmt->proctable[GLUSTERD_MGMT_FRIEND_ADD];
+ proc = &peerinfo->peer->proctable[GLUSTERD_FRIEND_ADD];
if (proc->fn) {
frame = create_frame (this, this->ctx->pool);
if (!frame) {
@@ -335,9 +335,9 @@ glusterd_ac_friend_probe (glusterd_friend_sm_event_t *event, void *ctx)
goto out;
}
- if (!peerinfo->mgmt)
+ if (!peerinfo->peer)
goto out;
- proc = &peerinfo->mgmt->proctable[GLUSTERD_MGMT_PROBE_QUERY];
+ proc = &peerinfo->peer->proctable[GLUSTERD_PROBE_QUERY];
if (proc->fn) {
frame = create_frame (this, this->ctx->pool);
if (!frame) {
@@ -426,9 +426,9 @@ glusterd_ac_send_friend_remove_req (glusterd_friend_sm_event_t *event,
goto out;
}
- if (!peerinfo->mgmt)
+ if (!peerinfo->peer)
goto out;
- proc = &peerinfo->mgmt->proctable[GLUSTERD_MGMT_FRIEND_REMOVE];
+ proc = &peerinfo->peer->proctable[GLUSTERD_FRIEND_REMOVE];
if (proc->fn) {
frame = create_frame (this, this->ctx->pool);
if (!frame) {
@@ -497,7 +497,7 @@ glusterd_ac_send_friend_update (glusterd_friend_sm_event_t *event, void *ctx)
goto out;
list_for_each_entry (peerinfo, &priv->peers, uuid_list) {
- if (!peerinfo->connected || !peerinfo->mgmt)
+ if (!peerinfo->connected || !peerinfo->peer)
continue;
ret = dict_set_static_ptr (friends, "peerinfo", peerinfo);
@@ -506,7 +506,7 @@ glusterd_ac_send_friend_update (glusterd_friend_sm_event_t *event, void *ctx)
goto out;
}
- proc = &peerinfo->mgmt->proctable[GLUSTERD_MGMT_FRIEND_UPDATE];
+ proc = &peerinfo->peer->proctable[GLUSTERD_FRIEND_UPDATE];
if (proc->fn) {
ret = proc->fn (NULL, this, friends);
}