code: def flush(self):
          
          queue = self.queue
          size = queue.qsize()
          queue.join()
          self.log.debug('successfully flushed %s items.', size)
docs: Forces a flush from the internal queue to the server