Author: sleon
Date: 2006-01-09 14:38:47 +0000 (Mon, 09 Jan 2006)
New Revision: 7827

Modified:
   trunk/apps/freeviz/db.py
Log:
added a max to the number of a from client dataaccepting threads per time, all 
other connections will be queueueueuened, max queueue length is 100

Modified: trunk/apps/freeviz/db.py
===================================================================
--- trunk/apps/freeviz/db.py    2006-01-09 13:04:17 UTC (rev 7826)
+++ trunk/apps/freeviz/db.py    2006-01-09 14:38:47 UTC (rev 7827)
@@ -76,17 +76,12 @@


 def delete_conns(nodeinfo, trans):
-       nodeid = getIdFromInfo(nodeinfo,trans)
-       node = Node.get(nodeid, connection=trans)
-       edges = node.edges      
+        nodeid = getIdFromInfo(nodeinfo,trans)
+        l = NodePair.select(connection=trans)
+        for i in l:
+                if i.node1.id == nodeid or i.node2.id == nodeid:
+                        i.delete(i.id)

-       for edge in edges:
-               node1=edge.node1
-               node2=edge.node2
-               #node1.removeNodePair(edge)
-               #node2.removeNodePair(edge)
-               edge.delete(edge.id)
-
 def exists(nodeinfo,trans):
        result = Node.select(Node.q.identity == 
nodeinfo['identity'],connection=trans)



Reply via email to