package
25.1.0+incompatible
Repository: https://github.com/cockroachdb/cockroach.git
Documentation: pkg.go.dev
# Functions
MakeKVEvent returns KV event constructed from existing RangeFeedEvent.
MakeMetrics constructs a Metrics struct with the provided histogram window.
MakeResolvedEvent returns resolved event constructed from existing RangeFeedEvent.
NewBackfillKVEvent returns new KV event constructed during the backfill.
NewBackfillResolvedEvent returns new resolved event.
NewMemBuffer returns a new in-memory buffer which will store events.
NewThrottlingBuffer wraps specified event buffer with a throttle that regulates the rate of events returned by the buffer reader.
TestingMakeAlloc creates allocation for the specified number of bytes in a single message using allocation pool 'p'.
TestingNewMemBuffer allows test to construct buffer which will invoked specified notification function when blocked, waiting for memory.
# Constants
TypeFlush indicates a request to flush buffered data.
TypeKV indicates that the KV, PrevKeyValue, and BackfillTimestamp methods on the Event meaningful.
TypeResolved indicates that the Resolved method on the Event will be meaningful.
# Variables
ErrNormalRestartReason is a sentinel error to indicate the ErrBufferClosed's reason is a pending restart.
# Structs
Alloc describes the resources allocated on behalf of an event.
ErrBufferClosed is returned by Readers when no more values will be returned from the buffer.
Event represents an event emitted by a kvfeed.
Metrics is a metric.Struct for kvfeed metrics.
PerBufferMetricsWithCompat is a compatibility layer between the new per-buffer metrics and the old metrics.
# Interfaces
Buffer is an interface for communicating kvfeed entries between processors.
MemAllocator is an interface for acquiring memory.
Reader is the read portion of the Buffer interface.
Writer is the write portion of the Buffer interface.
# Type aliases
Type indicates the type of the event.