Documentation ¶
Index ¶
- func GetFileContent(fpath string) ([]byte, error)
- type DMMasterCtl
- func (ctl *DMMasterCtl) OperateSQL(ctx context.Context, op pb.SQLOp, taskName, worker, pos, sqlPattern string, ...) (*pb.HandleSQLsResponse, error)
- func (ctl *DMMasterCtl) QueryError(ctx context.Context, taskName string) (map[string]*pb.QueryErrorResponse, error)
- func (ctl *DMMasterCtl) QueryStatus(ctx context.Context, taskName string) (map[string]*pb.QueryStatusResponse, error)
- func (ctl *DMMasterCtl) QueryUnresolvedGroups(ctx context.Context, taskName string) (map[string]map[string][]*pb.ShardingGroup, error)
- func (ctl *DMMasterCtl) ReplaceSQL(ctx context.Context, taskName, worker, pos, sqlPattern string, sharding bool, ...) (*pb.HandleSQLsResponse, error)
- func (ctl *DMMasterCtl) ResumeTask(ctx context.Context, taskName string, workers []string) (*pb.OperateTaskResponse, error)
- func (ctl *DMMasterCtl) SkipSQL(ctx context.Context, taskName, worker, pos, sqlPattern string, sharding bool) (*pb.HandleSQLsResponse, error)
- func (ctl *DMMasterCtl) StartTask(ctx context.Context, task string, workers []string) error
- func (ctl *DMMasterCtl) StartTaskWithContent(ctx context.Context, content string, workers []string) error
- func (ctl *DMMasterCtl) StopTask(ctx context.Context, task string, workers []string) error
- func (ctl *DMMasterCtl) UpdateMasterConfig(ctx context.Context, cfg string) error
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func GetFileContent ¶
GetFileContent reads and returns file's content
Types ¶
type DMMasterCtl ¶
type DMMasterCtl struct {
// contains filtered or unexported fields
}
DMMasterCtl controls dm master
func CreateDMMasterCtl ¶
func CreateDMMasterCtl(addr string) (*DMMasterCtl, error)
CreateDMMasterCtl creates dm-master client
func (*DMMasterCtl) OperateSQL ¶
func (*DMMasterCtl) QueryError ¶
func (ctl *DMMasterCtl) QueryError(ctx context.Context, taskName string) (map[string]*pb.QueryErrorResponse, error)
QueryError shows status of tasks
func (*DMMasterCtl) QueryStatus ¶
func (ctl *DMMasterCtl) QueryStatus(ctx context.Context, taskName string) (map[string]*pb.QueryStatusResponse, error)
QueryStatus shows status of tasks
func (*DMMasterCtl) QueryUnresolvedGroups ¶
func (ctl *DMMasterCtl) QueryUnresolvedGroups(ctx context.Context, taskName string) (map[string]map[string][]*pb.ShardingGroup, error)
func (*DMMasterCtl) ReplaceSQL ¶
func (ctl *DMMasterCtl) ReplaceSQL(ctx context.Context, taskName, worker, pos, sqlPattern string, sharding bool, args []string) (*pb.HandleSQLsResponse, error)
func (*DMMasterCtl) ResumeTask ¶
func (ctl *DMMasterCtl) ResumeTask(ctx context.Context, taskName string, workers []string) (*pb.OperateTaskResponse, error)
ResumeTask resumes a paused task
func (*DMMasterCtl) SkipSQL ¶
func (ctl *DMMasterCtl) SkipSQL(ctx context.Context, taskName, worker, pos, sqlPattern string, sharding bool) (*pb.HandleSQLsResponse, error)
SkipSQL skips specified binlog position or sql pattern
func (*DMMasterCtl) StartTaskWithContent ¶
func (*DMMasterCtl) UpdateMasterConfig ¶
func (ctl *DMMasterCtl) UpdateMasterConfig(ctx context.Context, cfg string) error
Update master config online
Click to show internal directories.
Click to hide internal directories.