code: func (eq *LimitQueue) Write(event events.Event) error {
  	eq.mu.Lock()
  	defer eq.mu.Unlock()
  
  	if eq.closed {
  		return events.ErrSinkClosed
  	}
  
  	if eq.limit > 0 && uint64(eq.events.Len()) >= eq.limit {
  		// If the limit has been reached, don't write the event to the queue,
  		// and close the Full channel. This notifies listeners that the queue
  		// is now full, but the sink is still permitted to consume events. It's
  		// the responsibility of the listener to decide whether they want to
  		// live with dropped events or whether they want to Close() the
  		// LimitQueue
  		if !eq.fullClosed {
  			eq.fullClosed = true
  			close(eq.full)
  		}
  		return ErrQueueFull
  	}
  
  	eq.events.PushBack(event)
  	eq.cond.Signal() // signal waiters
  
  	return nil
  }
docs: // Write accepts the events into the queue, only failing if the queue has
  // been closed or has reached its size limit.