phonon/nodelist.py
def find_expired_nodes(self, node_ids=None):
        """
        Detects connections that have held a reference for longer than its
        process_ttl without refreshing its session. This function does not
        actually removed them from the hash. (See remove_expired_nodes.)

        :param list node_ids: optional, a list of ids to check to see if they
            have expired.  If node_ids is not passed in, all nodes in the hash
            will be checked.
        """
        if node_ids:
            nodes = zip(node_ids, [int(t) for t in self.conn.client.hmget(self.nodelist_key, node_ids)])
        else:
            nodes = self.get_all_nodes().items()

        expiration_delta = self.conn.PROCESS_TTL * 1000.
        now = int(time.time() * 1000.)
        return [node_id for (node_id, last_updated) in nodes if (now - last_updated) > expiration_delta]
def find_expired_nodes(self, node_ids=None):
        """
        Detects connections that have held a reference for longer than its
        process_ttl without refreshing its session. This function does not
        actually removed them from the hash. (See remove_expired_nodes.)

        :param list node_ids: optional, a list of ids to check to see if they
            have expired.  If node_ids is not passed in, all nodes in the hash
            will be checked.
        """
        if node_ids:
            nodes = zip(node_ids, [int(t) for t in self.conn.client.hmget(self.nodelist_key, node_ids)])
        else:
            nodes = self.get_all_nodes().items()

        expiration_delta = self.conn.PROCESS_TTL * 1000.
        now = int(time.time() * 1000.)
        return [node_id for (node_id, last_updated) in nodes if (now - last_updated) > expiration_delta]
def find_expired_nodes ( self , node_ids = None ) : if node_ids : nodes = zip ( node_ids , [ int ( t ) for t in self . conn . client . hmget ( self . nodelist_key , node_ids ) ] ) else : nodes = self . get_all_nodes ( ) . items ( ) expiration_delta = self . conn . PROCESS_TTL * 1000. now = int ( time . time ( ) * 1000. ) return [ node_id for ( node_id , last_updated ) in nodes if ( now - last_updated ) > expiration_delta ]
Detects connections that have held a reference for longer than its
        process_ttl without refreshing its session. This function does not
        actually removed them from the hash. (See remove_expired_nodes.)

        :param list node_ids: optional, a list of ids to check to see if they
            have expired.  If node_ids is not passed in, all nodes in the hash
            will be checked.
Detects connections that have held a reference for longer than its process_ttl without refreshing its session . This function does not actually removed them from the hash . ( See remove_expired_nodes . )