(self, item, block = True, timeout = None)
| 11 | self.curSize = 0 # in Bytes. We maintain this to prevent nodes from flooing us with objects which take up too much memory. If this gets too big we'll sleep before asking for further objects. |
| 12 | |
| 13 | def put(self, item, block = True, timeout = None): |
| 14 | while self.curSize >= self.maxSize: |
| 15 | time.sleep(1) |
| 16 | with self.sizeLock: |
| 17 | self.curSize += len(item[1]) |
| 18 | Queue.Queue.put(self, item, block, timeout) |
| 19 | |
| 20 | def get(self, block = True, timeout = None): |
| 21 | try: |
no outgoing calls
no test coverage detected