Piotr Kliczewski has uploaded a new change for review.
Change subject: stomp: make sure that subscriptions use uniqe id ......................................................................
stomp: make sure that subscriptions use uniqe id
There was a bug in the engine that there were two subscriptions with the same id. This issue as a result created fd leak because we were not able to clean the subscription id on connection closed or unsubscribe.
Change-Id: I3883bb68134a6e2cc52cf54ce4027122db8150e9 Signed-off-by: pkliczewski piotr.kliczewski@gmail.com --- M lib/yajsonrpc/stompreactor.py 1 file changed, 5 insertions(+), 0 deletions(-)
git pull ssh://gerrit.ovirt.org:29418/vdsm refs/changes/56/46656/1
diff --git a/lib/yajsonrpc/stompreactor.py b/lib/yajsonrpc/stompreactor.py index 71fd2ab..7e74708 100644 --- a/lib/yajsonrpc/stompreactor.py +++ b/lib/yajsonrpc/stompreactor.py @@ -133,6 +133,11 @@ dispatcher.connection) return
+ if sub_id in self._sub_ids.keys(): + self._send_error("Subscription id already exists", + dispatcher.connection) + return + ack = frame.headers.get("ack", stomp.AckMode.AUTO) subscription = stomp._Subscription(dispatcher.connection, destination, sub_id, ack, None)