code: func (b *basicBatcher) flush() {
  	b.batchChan <- b.items
  	b.items = make([]interface{}, 0, b.maxItems)
  	b.availableBytes = 0
  }
docs: // flush adds the batch currently being built to the queue of completed batches.
  // flush is not threadsafe, so should be synchronized externally.