def closeConnections(cls, path, userIdList, excludeId=None):
# Note: closed connections may be automatically re-opened; use lockConnection to force reloads
sessionConnections = cls._connections.get(path,{})
for userId in userIdList:
if excludeId and userId == excludeId:
continue
if Options['debug']:
print >> sys.stderr, "DEBUG: sdserver.closeConnections", 'Closing connections for user:', userId
for connection in sessionConnections.get(userId,[])[:]: # connection list may be altered by close
connection.close()
评论列表
文章目录