(self)
| 60 | return nodes.order_by('queue_count').first() |
| 61 | |
| 62 | def is_online(self): |
| 63 | if settings.NODE_OPTIMISTIC_MODE: |
| 64 | return True |
| 65 | |
| 66 | return self.last_refreshed is not None and \ |
| 67 | self.last_refreshed >= timezone.now() - timedelta(minutes=settings.NODE_OFFLINE_MINUTES) |
| 68 | |
| 69 | def update_node_info(self): |
| 70 | """ |
no outgoing calls