config

package
v1.0.2 Latest Latest
Warning

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

Go to latest
Published: Oct 30, 2023 License: Apache-2.0 Imports: 1 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type CompareConfig

type CompareConfig struct {
	SourceType     string `toml:"source-type" json:"source-type"`
	DestType       string `toml:"dest-type" json:"dest-type"`
	SQLSource      string `toml:"sql-source" json:"sql-source"`
	SQLFileDefault string `toml:"sqlfile-default" json:"sqlfile-default"`
	SQLFileSource  string `toml:"sqlfile-source" json:"sqlfile-source"`
	SQLFileDest    string `toml:"sqlfile-dest" json:"sqlfile-dest"`
	Delimiter      string `toml:"sqlfile-delimiter" json:"sqlfile-delimiter"`
	Output         string `toml:"output" json:"output"`
	OutputPrefix   string `toml:"outputprefix" json:"outputprefix"`
}

type Config

type Config struct {
	Log           Log            `toml:"log" json:"log"`
	MySQLConfig   DBConfig       `toml:"mysql-config" json:"mysql-config"`
	TiDBConfig    DBConfig       `toml:"tidb-config" json:"tidb-config"`
	CompareConfig CompareConfig  `toml:"compare-config" json:"compare-config"`
	OracleConfig  OracleDBConfig `toml:"oracle-config" json:"oracle-config"`
}

func InitConfig

func InitConfig(configPath string) (cfg Config)

InitConfig Func

type DBConfig

type DBConfig struct {
	Host       string `toml:"host" json:"host"`
	Port       int    `toml:"port" json:"port"`
	User       string `toml:"user" json:"user"`
	Password   string `toml:"password" json:"password"`
	Database   string `toml:"database" json:"database"`
	StatusPort int    `toml:"status-port" json:"status-port"`
	PDAddr     string `toml:"pd-addr" json:"pd-addr"`
}

type Log

type Log struct {
	Level   string `toml:"log-level" json:"log-level"`
	LogPath string `toml:"log-path" json:"log-path"`
	LogDir  string `toml:"log-dir" json:"log-dir"`
}

type O2TInitConfig

type O2TInitConfig struct {
	Sqluldr2BinPath       string `toml:"sqluldr2-bin-path" json:"sqluldr2-bin-path"`
	Sqluldr2ExtraArgs     string `toml:"sqluldr2-extra-args" json:"sqluldr2-extra-args"`
	DumpDataDir           string `toml:"dump-data-dir" json:"dump-data-dir"`
	LightningBinPath      string `toml:"lightning-bin-path" json:"lightning-bin-path"`
	LightningTomlTemplate string `toml:"lightning-toml-template" json:"lightning-toml-template"`
	LightningTomlDir      string `toml:"lightning-toml-dir" json:"lightning-toml-dir"`
	LightningExtraArgs    string `toml:"lightning-extra-args" json:"lightning-extra-args"`
}

type OTOConfig

type OTOConfig struct {
	Log             Log                   `toml:"log" json:"log"`
	Performance     PerformanceConfig     `toml:"performance" json:"performance"`
	TiDBConfig      DBConfig              `toml:"tidb-config" json:"tidb-config"`
	OracleConfig    OracleDBConfig        `toml:"oracle-config" json:"oracle-config"`
	SyncDiffControl SyncDiffControlConfig `toml:"sync-diff-control" json:"sync-diff-control"`
	T2OInit         T2OInitConfig         `toml:"t2o-init" json:"t2o-init"`
	O2TInit         O2TInitConfig         `toml:"o2t-init" json:"o2t-init"`
}

func InitOTOConfig

func InitOTOConfig(configPath string) (cfg OTOConfig)

InitConfig Func

type OracleDBConfig

type OracleDBConfig struct {
	User        string `toml:"user" json:"user"`
	Password    string `toml:"password" json:"password"`
	Host        string `toml:"host" json:"host"`
	Port        int    `toml:"port" json:"port"`
	ServiceName string `toml:"service-name" json:"service-name"`
	SchemaName  string `toml:"schema-name" json:"schema-name"`
}

type PerformanceConfig

type PerformanceConfig struct {
	Concurrency   int  `toml:"concurrency" json:"concurrency"`
	CheckRowCount bool `toml:"check-row-count" json:"check-row-count"`
}

type SyncDiffControlConfig

type SyncDiffControlConfig struct {
	ConfDir      string `toml:"conf-dir" json:"conf-dir"`
	BinPath      string `toml:"bin-path" json:"bin-path"`
	SyncTemplate string `toml:"sync-template" json:"sync-template"`
}

type T2OInitConfig

type T2OInitConfig struct {
	DumplingBinPath    string `toml:"dumpling-bin-path" json:"dumpling-bin-path"`
	DumpDataDir        string `toml:"dump-data-dir" json:"dump-data=dir"`
	DumpExtraArgs      string `toml:"dump-extra-args" json:"dump-extra-args"`
	OracleCtlFileDir   string `toml:"oracle-ctl-file-dir" json:"oracle-ctl-file-dir"`
	CtlTemplate        string `toml:"ctl-template" json:"ctl-template"`
	SqlldrBinPath      string `toml:"sqlldr-bin-path" json:"sqlldr-bin-path"`
	SqlldrExtraArgs    string `toml:"sqlldr-extra-args" json:"sqlldr-extra-args"`
	TruncateBeforeLoad bool   `toml:"truncate-before-load" json:"truncate-before-load"`
}

Jump to

Keyboard shortcuts

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