56 lines
1.6 KiB
Python
56 lines
1.6 KiB
Python
load("@io_bazel_rules_go//go:def.bzl", "go_library", "go_test")
|
|
|
|
go_library(
|
|
name = "loaddata",
|
|
srcs = [
|
|
"dispatcher.go",
|
|
"job.go",
|
|
"proto.go",
|
|
"scheduler.go",
|
|
"subtask_executor.go",
|
|
"wrapper.go",
|
|
],
|
|
importpath = "github.com/pingcap/tidb/disttask/loaddata",
|
|
visibility = ["//visibility:public"],
|
|
deps = [
|
|
"//br/pkg/lightning/backend",
|
|
"//br/pkg/lightning/backend/kv",
|
|
"//br/pkg/lightning/checkpoints",
|
|
"//br/pkg/lightning/common",
|
|
"//br/pkg/lightning/config",
|
|
"//br/pkg/lightning/mydump",
|
|
"//br/pkg/lightning/verification",
|
|
"//disttask/framework/dispatcher",
|
|
"//disttask/framework/handle",
|
|
"//disttask/framework/proto",
|
|
"//disttask/framework/scheduler",
|
|
"//disttask/framework/storage",
|
|
"//domain/infosync",
|
|
"//executor/asyncloaddata",
|
|
"//executor/importer",
|
|
"//parser/mysql",
|
|
"//table/tables",
|
|
"//util/logutil",
|
|
"@com_github_google_uuid//:uuid",
|
|
"@com_github_pingcap_errors//:errors",
|
|
"@com_github_pingcap_failpoint//:failpoint",
|
|
"@org_uber_go_atomic//:atomic",
|
|
"@org_uber_go_zap//:zap",
|
|
],
|
|
)
|
|
|
|
go_test(
|
|
name = "loaddata_test",
|
|
timeout = "short",
|
|
srcs = ["dispatcher_test.go"],
|
|
embed = [":loaddata"],
|
|
flaky = True,
|
|
deps = [
|
|
"//disttask/framework/proto",
|
|
"//domain/infosync",
|
|
"@com_github_pingcap_failpoint//:failpoint",
|
|
"@com_github_stretchr_testify//require",
|
|
"@com_github_stretchr_testify//suite",
|
|
],
|
|
)
|