Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type ColumnSelector ¶
type ColumnSelector struct {
// contains filtered or unexported fields
}
ColumnSelector manages an array of selectors, the first selector match the given event is used to select out columns.
func New ¶
func New(cfg *config.ReplicaConfig) (*ColumnSelector, error)
New return a column selector
func (*ColumnSelector) Apply ¶
func (c *ColumnSelector) Apply(event *model.RowChangedEvent) error
Apply the column selector to the given event.
func (*ColumnSelector) VerifyColumn ¶
func (c *ColumnSelector) VerifyColumn(schema, table, column string) bool
VerifyColumn return true if the given `schema.table` column is matched.
func (*ColumnSelector) VerifyTables ¶
func (c *ColumnSelector) VerifyTables( infos []*model.TableInfo, eventRouter *dispatcher.EventRouter, ) error
VerifyTables return the error if any given table cannot satisfy the column selector constraints. 1. if the column is filter out, it must not be a part of handle key or the unique key. 2. if the filtered out column is used in the column dispatcher, return error.
Click to show internal directories.
Click to hide internal directories.