code: func NewBackend(delegate audit.Backend, config BatchConfig) audit.Backend {
  	var throttle flowcontrol.RateLimiter
  	if config.ThrottleEnable {
  		throttle = flowcontrol.NewTokenBucketRateLimiter(config.ThrottleQPS, config.ThrottleBurst)
  	}
  	return &bufferedBackend{
  		delegateBackend: delegate,
  		buffer:          make(chan *auditinternal.Event, config.BufferSize),
  		maxBatchSize:    config.MaxBatchSize,
  		maxBatchWait:    config.MaxBatchWait,
  		asyncDelegate:   config.AsyncDelegate,
  		shutdownCh:      make(chan struct{}),
  		wg:              sync.WaitGroup{},
  		throttle:        throttle,
  	}
  }
docs: // NewBackend returns a buffered audit backend that wraps delegate backend.
  // Buffered backend automatically runs and shuts down the delegate backend.