oracle

package
v1.18.8 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Oct 15, 2026 License: MIT Imports: 17 Imported by: 0

Documentation

Index

Constants

View Source
const (
	CDCMethodIncremental = "incremental"
	CDCMethodLogMiner    = "logminer"
)

CDCMethodLogMiner selects log-based CDC through Oracle LogMiner. The default, CDCMethodIncremental, polls each table for rows above the last id_field value seen and so sees inserts only.

Variables

This section is empty.

Functions

This section is empty.

Types

type OracleSource

type OracleSource struct {
	// contains filtered or unexported fields
}

OracleSource implements the hermod.Source interface for Oracle.

func NewOracleSource

func NewOracleSource(connString string, tables []string, idField string, pollInterval time.Duration, useCDC bool) *OracleSource

func (*OracleSource) Ack

func (o *OracleSource) Ack(ctx context.Context, msg hermod.Message) error

Ack moves the persisted cursor to the acknowledged row.

func (*OracleSource) Close

func (o *OracleSource) Close() error

func (*OracleSource) DiscoverColumns

func (o *OracleSource) DiscoverColumns(ctx context.Context, table string) ([]hermod.ColumnInfo, error)

func (*OracleSource) DiscoverDatabases

func (o *OracleSource) DiscoverDatabases(ctx context.Context) ([]string, error)

func (*OracleSource) DiscoverTables

func (o *OracleSource) DiscoverTables(ctx context.Context) ([]string, error)

func (*OracleSource) GetState

func (o *OracleSource) GetState() map[string]string

func (*OracleSource) IsReady added in v1.18.0

func (o *OracleSource) IsReady(ctx context.Context) error

IsReady reports what stops LogMiner from capturing complete changes: supplemental logging, grants, or tables it cannot see.

func (*OracleSource) Ping

func (o *OracleSource) Ping(ctx context.Context) error

func (*OracleSource) Read

func (o *OracleSource) Read(ctx context.Context) (hermod.Message, error)

func (*OracleSource) Sample

func (o *OracleSource) Sample(ctx context.Context, table string) (hermod.Message, error)

func (*OracleSource) SetLogMiner added in v1.18.0

func (o *OracleSource) SetLogMiner(pdb string, initialLoad bool)

SetLogMiner switches CDC from incremental polling to LogMiner, which reads inserts, updates and deletes from the redo logs. pdb names the pluggable database to capture when the connection is to CDB$ROOT; leave it empty when connected to the PDB itself or to a non-CDB. initialLoad emits the tables' current rows, read as of the start SCN, before the first change.

func (*OracleSource) SetLogger

func (o *OracleSource) SetLogger(logger hermod.Logger)

func (*OracleSource) SetState

func (o *OracleSource) SetState(state map[string]string)

func (*OracleSource) Snapshot

func (o *OracleSource) Snapshot(ctx context.Context, tables ...string) error

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL