Documentation ¶
Overview ¶
Package cdc contains a http.Handler which can receive webhook events from a CockroachDB CDC changefeed. Row updates and resolved timestamps are written to staging tables. The resolved timestamps are processed as a logical loop.
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var Set = wire.NewSet( ProvideHandler, ProvideConveyorConfig, ProvideDLQConfig, ProvideScriptConfig, ProvideSequencerConfig, conveyor.Set, )
Set is used by Wire.
Functions ¶
func ProvideConveyorConfig ¶
ProvideConveyorConfig is called by Wire.
func ProvideDLQConfig ¶
ProvideDLQConfig is called by Wire.
func ProvideScriptConfig ¶
ProvideScriptConfig is called by Wire.
func ProvideSequencerConfig ¶
ProvideSequencerConfig is called by Wire.
Types ¶
type Config ¶
type Config struct { ConveyorConfig conveyor.Config DLQConfig dlq.Config SequencerConfig sequencer.Config ScriptConfig script.Config // Discard all incoming HTTP payloads. This is useful for tuning // changefeed throughput without considering cdc-sink performance. Discard bool // If non-zero, wait half before and after consuming the payload. DiscardDelay time.Duration // The maximum amount of data to buffer when reading a single line // of ndjson input. This can be increased if the source cluster // has large blob values. NDJsonBuffer int // The maximum amount of time that we want to allow an HTTP handler // to run for. ResponseTimeout time.Duration }
Config adds CDC-specific configuration to the core logical loop.
type Handler ¶
type Handler struct { Authenticator types.Authenticator // Access checks. Config *Config // Runtime options. Conveyors *conveyor.Conveyors // Mutation delivery to the target. TargetPool *types.TargetPool // Access to the target cluster. }
Handler is an http.Handler for processing webhook requests from a CockroachDB changefeed.
func ProvideHandler ¶
func ProvideHandler( auth types.Authenticator, cfg *Config, conv *conveyor.Conveyors, pool *types.TargetPool, ) (*Handler, error)
ProvideHandler is called by Wire.
Source Files ¶
Click to show internal directories.
Click to hide internal directories.