Documentation ¶
Index ¶
- type Config
- type Option
- func WithIDFinder(idFinder columnFinder) Option
- func WithInstrumentation(i *otel.Instrumentation) Option
- func WithLogger(l loglib.Logger) Option
- func WithSkipDataEvent(skip dataEventFilter) Option
- func WithSkipSchemaEvent(skip schemaEventFilter) Option
- func WithVersionFinder(versionFinder columnFinder) Option
- type Translator
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Config ¶
type Config struct {
Store schemalogpg.Config
}
type Option ¶
type Option func(t *Translator)
func WithIDFinder ¶
func WithIDFinder(idFinder columnFinder) Option
func WithInstrumentation ¶ added in v0.2.0
func WithInstrumentation(i *otel.Instrumentation) Option
func WithLogger ¶
func WithSkipDataEvent ¶ added in v0.2.0
func WithSkipDataEvent(skip dataEventFilter) Option
func WithSkipSchemaEvent ¶ added in v0.2.0
func WithSkipSchemaEvent(skip schemaEventFilter) Option
func WithVersionFinder ¶
func WithVersionFinder(versionFinder columnFinder) Option
type Translator ¶
type Translator struct {
// contains filtered or unexported fields
}
Translator is a decorator around a wal processor that populates the wal metadata with the schemalog entry for the relevant schema. This allows following processors to have more information for processing the event effectively.
func New ¶
New will return a translator processor wrapper that will inject pgstream metadata into the wal data events before passing them over to the processor on input. By default, all schemas are processed and the pgstream identity will be the primary key/not null unique column if present.
func (*Translator) Close ¶
func (t *Translator) Close() error
func (*Translator) Name ¶
func (t *Translator) Name() string
func (*Translator) ProcessWALEvent ¶
ProcessWALEvent populates the metadata of the wal event on input, before passing it over to the configured wal processor.