Skip to content

Commit 743cd49

Browse files
docs
1 parent 0551bf2 commit 743cd49

File tree

1 file changed

+5
-2
lines changed

1 file changed

+5
-2
lines changed

provider/buffered/provider.go

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -29,8 +29,9 @@ const (
2929

3030
var _ internal.Provider = (*SweepingProvider)(nil)
3131

32-
// SweepingProvider implements a buffered provider that queues operations and
33-
// processes them asynchronously in batches.
32+
// buffered.SweepingProvider is a wrapper around a SweepingProvider buffering
33+
// requests, to allow core operations to return instantly. Operations are
34+
// queued and processed asynchronously in batches for improved performance.
3435
type SweepingProvider struct {
3536
closeOnce sync.Once
3637
done chan struct{}
@@ -149,6 +150,8 @@ func (s *SweepingProvider) worker() {
149150
logger.Warnf("BufferedSweepingProvider unable to parse dequeued item: %v", err)
150151
continue
151152
}
153+
// Execute the 4 kinds of queued provider operations on the underlying
154+
// provider.
152155

153156
// Process `StartProviding` (force=true) ops first, so that if
154157
// `StartProviding` (force=false) is called after, there is no need to

0 commit comments

Comments
 (0)