(self)
执行协议
执行协议
执行协议
def _run(self):
        """执行协议
        """
        address = 'tcp://%s:%s'%self.to_db_address
        self.sock.connect(address)
        while True:
            try:
                message = self.inbox.get()
                self.sock.send_pyobj(message)
            except Exception as e:
                log.err(_stuff=e,_why=traceback.format_exc())
                log.msg(str(message))
def _run ( self ) : address = 'tcp://%s:%s' % self . to_db_address self . sock . connect ( address ) while True : try : message = self . inbox . get ( ) self . sock . send_pyobj ( message ) except Exception as e : log . err ( _stuff = e , _why = traceback . format_exc ( ) ) log . msg ( str ( message ) )