Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type WalFollower ¶
type WalFollower struct {
// contains filtered or unexported fields
}
WalFollower watches the WAL and writes changes into the cache
func NewWalFollower ¶
func NewWalFollower(conn *pgconn.PgConn, mapping []config.InternalTableMapping, cache *cache.Cache) *WalFollower
NewWalFollower creates a new WalFollower for postgres. The conn must be made with the `replication` flag set.
func (*WalFollower) Follow ¶
Follow starts watching the replication log at startpos. It uses the config's InternalTableMapping to translate WAL events into relationships, which are then written to the cache. Follow (and replication connections in general) are not safe to share across threads. Events should be read from the cache to process them in parallel.
Click to show internal directories.
Click to hide internal directories.