Skip to content

Commit

Permalink
Make receiver data delivery guarantees explicit
Browse files Browse the repository at this point in the history
Resolves #4261

We want to make this explicit and ensure all receivers follow this pattern.
It is important for applications of the Collector where it is delivery guarantees are critical.

The OTLP receiver correctly follows the guarantees. Other receivers may need to be audited
to ensure compliance.
  • Loading branch information
tigrannajaryan committed Oct 25, 2021
1 parent c0e8f31 commit b482879
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions component/receiver.go
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,15 @@ import (
)

// Receiver allows the collector to receive metrics, traces and logs.
//
// The receivers SHOULD follow this order of operations:
// - Receive data from some sender (typically from a network).
// - Push received data to the pipeline by calling nextConsumer.Consume*() function.
// - If the receiving protocol supports acknowledgements acknowledge successful
// data receipt to the sender if Consume*() succeeded or return a failure to the
// sender if Consume*() returned an error.
// This ensures there are strong delivery guarantees once the data is acknowledged
// by the Collector.
type Receiver interface {
Component
}
Expand Down

0 comments on commit b482879

Please sign in to comment.