Versions in this module Expand all Collapse all v0 v0.1.0 Aug 18, 2021 Changes in this version + func SetLogger(logger log.Logger) + type ColumnData struct + Data []byte + Filed string + IsEmpty bool + Type ColumnType + func (c *ColumnData) MarshalJSON() ([]byte, error) + type ColumnType int + func (c ColumnType) IsBit() bool + func (c ColumnType) IsBlob() bool + func (c ColumnType) IsDate() bool + func (c ColumnType) IsDateTime() bool + func (c ColumnType) IsDecimal() bool + func (c ColumnType) IsFloat() bool + func (c ColumnType) IsGeometry() bool + func (c ColumnType) IsInteger() bool + func (c ColumnType) IsString() bool + func (c ColumnType) IsTime() bool + func (c ColumnType) IsTimestamp() bool + func (c ColumnType) String() string + type Error struct + func (e *Error) Error() string + func (e *Error) Original() error + type FormatType string + func (f FormatType) IsMixed() bool + func (f FormatType) IsRow() bool + func (f FormatType) IsStatement() bool + type MysqlColumn interface + Field func() string + IsUnSignedInt func() bool + type MysqlTable interface + Columns func() []MysqlColumn + Name func() MysqlTableName + type MysqlTableMapper interface + MysqlTable func(name MysqlTableName) (MysqlTable, error) + type MysqlTableName struct + DbName string + TableName string + func NewMysqlTableName(database, table string) MysqlTableName + func (m *MysqlTableName) String() string + type Position struct + Filename string + Offset int64 + func (p Position) IsZero() bool + type RowData struct + Columns []*ColumnData + type SendTransactionFunc func(*Transaction) error + type StatementType int + const StatementAlter + const StatementBegin + const StatementCommit + const StatementCreate + const StatementDelete + const StatementDrop + const StatementInsert + const StatementRename + const StatementRollback + const StatementSet + const StatementTruncate + const StatementUnknown + const StatementUpdate + func GetStatementCategory(sql string) StatementType + func (s StatementType) IsDDL() bool + func (s StatementType) String() string + type StreamEvent struct + Query replication.Query + RowIdentifies []*RowData + RowValues []*RowData + Table MysqlTableName + Timestamp int64 + Type StatementType + func (s *StreamEvent) MarshalJSON() ([]byte, error) + type Streamer struct + func NewStreamer(dsn string, serverID uint32, tableMapper MysqlTableMapper) (*Streamer, error) + func (s *Streamer) Error() error + func (s *Streamer) SetBinlogPosition(startPos Position) + func (s *Streamer) Stream(ctx context.Context, sendTransaction SendTransactionFunc) error + type Transaction struct + Events []*StreamEvent + NextPosition Position + NowPosition Position + Timestamp int64 + func (t *Transaction) MarshalJSON() ([]byte, error)