def add_events(self, **kwargs):
event_q = kwargs.get('<STR_LIT>')<EOL>pri = kwargs.get('<STR_LIT>')<EOL>if not event_q or not pri:<EOL><INDENT>return<EOL><DEDENT>try:<EOL><INDENT>event_type = '<STR_LIT>'<EOL>payload = {}<EOL>timestamp = time.ctime()<EOL>data = (event_type, payload)<EOL>event_q.put((pri, timestamp, data))<EOL>LOG.debug('<STR_LIT>')<EOL><DEDENT>except Exception as exc:<EOL><INDENT>LOG.exception('<STR_LIT>',<EOL>{'<STR_LIT>': str(exc), '<STR_LIT>': event_type})<EOL>raise exc<EOL><DEDENT>
Add failure event into the queue.