canal

package
v0.0.0-...-f17123e Latest Latest
Warning

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

Go to latest
Published: Aug 18, 2021 License: Apache-2.0 Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func FormatColName

func FormatColName(col *pbe.Column) string

FormatColName 格式化列名 使用反引号包围

func FormatColValue

func FormatColValue(col *pbe.Column) string

FormatColValue 格式化列数据 除去int bit类型的都要使用单引号包围

func FormatSql

func FormatSql(cols []*pbe.Column, isUpdate bool) (keyColName string, keyColValue string, colNames string, colValues string, updateChanges string)

Types

type Channel

type Channel struct {
	ChannelSql chan []Sql
	Stop       bool
}

func RunCanalClient

func RunCanalClient(address string, port int, username string, password string, destination string, soTimeOut int32, idleTimeOut int32, regex string) *Channel

type Sql

type Sql struct {
	Content string
	Type    string
	Insert  string
}

func GetSql

func GetSql(entrys []pbe.Entry) []Sql

Jump to

Keyboard shortcuts

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