'Emit a record.
Append the record. If shouldFlush() tells us to, call flush() to process
the buffer.'

def emit(self, record):

    self.buffer.append(record)
    if self.shouldFlush(record):
        self.flush()
