()
return ProcessingNode.objects.filter(last_refreshed__gte=timezone.now() - timedelta(minutes=settings.NODE_OFFLINE_MINUTES)) \
                                     .order_by('queue_count').first()
Attempts to find an available node (seen in the last 5 minutes, and with lowest queue count)
        :return: ProcessingNode | None
Attempts to find an available node (seen in the last 5 minutes, and with lowest queue count)
        :return: ProcessingNode | None
Attempts to find an available node ( seen in the last 5 minutes and with lowest queue count ) : return : ProcessingNode | None
def find_best_available_node():
        """
        Attempts to find an available node (seen in the last 5 minutes, and with lowest queue count)
        :return: ProcessingNode | None
        """
        return ProcessingNode.objects.filter(last_refreshed__gte=timezone.now() - timedelta(minutes=settings.NODE_OFFLINE_MINUTES)) \
                                     .order_by('queue_count').first()
def find_best_available_node ( ) : return ProcessingNode . objects . filter ( last_refreshed__gte = timezone . now ( ) - timedelta ( minutes = settings . NODE_OFFLINE_MINUTES ) ) . order_by ( 'queue_count' ) . first ( )