Change in vdsm[master]: jsonrpcvdscli: use subscription when creating a client

ykaplan at redhat.com ykaplan at redhat.com
Mon Apr 27 08:56:15 UTC 2015


Yeela Kaplan has uploaded a new change for review.

Change subject: jsonrpcvdscli: use subscription when creating a client
......................................................................

jsonrpcvdscli: use subscription when creating a client

Change-Id: I33e1084a4016509aaf0e9e749ff05e33a331f580
Signed-off-by: Yeela Kaplan <ykaplan at redhat.com>
---
M lib/vdsm/jsonrpcvdscli.py
1 file changed, 7 insertions(+), 2 deletions(-)


  git pull ssh://gerrit.ovirt.org:29418/vdsm refs/changes/07/40307/1

diff --git a/lib/vdsm/jsonrpcvdscli.py b/lib/vdsm/jsonrpcvdscli.py
index 6e66b89..ffbfdbf 100644
--- a/lib/vdsm/jsonrpcvdscli.py
+++ b/lib/vdsm/jsonrpcvdscli.py
@@ -21,10 +21,11 @@
 from functools import partial
 from uuid import uuid4
 
+from .config import config
 from rpc.Bridge import InvalidCall
+from yajsonrpc import stompReactor
 from yajsonrpc import \
     JsonRpcError, \
-    JsonRpcClient, \
     JsonRpcRequest, \
     CALL_TIMEOUT
 
@@ -77,7 +78,11 @@
     if stompClient is None:
         raise Exception("Failed to create a stomp client")
 
-    client = JsonRpcClient(stompClient)
+    requestQueues = config.get('addresses', 'request_queues')
+    requestQueue = requestQueues.split(",")[0]
+    client = stompReactor.StompRpcClient(stompClient,
+                                         requestQueue,
+                                         str(uuid4()))
     client.connect()
 
     return _Server(client)
\ No newline at end of file


-- 
To view, visit https://gerrit.ovirt.org/40307
To unsubscribe, visit https://gerrit.ovirt.org/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: I33e1084a4016509aaf0e9e749ff05e33a331f580
Gerrit-PatchSet: 1
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Yeela Kaplan <ykaplan at redhat.com>


More information about the vdsm-patches mailing list