def update_vm_result(self, context, msg):
args = jsonutils.loads(msg)<EOL>agent = context.get('<STR_LIT>')<EOL>port_id = args.get('<STR_LIT>')<EOL>result = args.get('<STR_LIT:result>')<EOL>LOG.debug('<STR_LIT>'<EOL>'<STR_LIT>', {'<STR_LIT>': agent,<EOL>'<STR_LIT>': port_id,<EOL>'<STR_LIT:result>': result})<EOL>event_type = '<STR_LIT>'<EOL>payload = {'<STR_LIT>': port_id, '<STR_LIT:result>': result}<EOL>timestamp = time.ctime()<EOL>data = (event_type, payload)<EOL>pri = self.obj.PRI_LOW_START + <NUM_LIT:10><EOL>self.obj.pqueue.put((pri, timestamp, data))<EOL>LOG.debug('<STR_LIT>')<EOL>return <NUM_LIT:0><EOL>
Update VM's result field in the DB.

        The result reflects the success of failure of operation when an
        agent processes the vm info.