93 lines
2.4 KiB
Python
93 lines
2.4 KiB
Python
load("@io_bazel_rules_go//go:def.bzl", "go_library", "go_test")
|
|
|
|
go_library(
|
|
name = "sortexec",
|
|
srcs = [
|
|
"multi_way_merge.go",
|
|
"parallel_sort_spill_helper.go",
|
|
"parallel_sort_worker.go",
|
|
"sort.go",
|
|
"sort_partition.go",
|
|
"sort_spill.go",
|
|
"sort_util.go",
|
|
"topn.go",
|
|
"topn_chunk_heap.go",
|
|
"topn_spill.go",
|
|
"topn_worker.go",
|
|
],
|
|
importpath = "github.com/pingcap/tidb/pkg/executor/sortexec",
|
|
visibility = ["//visibility:public"],
|
|
deps = [
|
|
"//pkg/executor/internal/exec",
|
|
"//pkg/expression",
|
|
"//pkg/planner/core",
|
|
"//pkg/planner/util",
|
|
"//pkg/sessionctx/variable",
|
|
"//pkg/types",
|
|
"//pkg/util",
|
|
"//pkg/util/channel",
|
|
"//pkg/util/chunk",
|
|
"//pkg/util/disk",
|
|
"//pkg/util/logutil",
|
|
"//pkg/util/memory",
|
|
"//pkg/util/sqlkiller",
|
|
"@com_github_pingcap_errors//:errors",
|
|
"@com_github_pingcap_failpoint//:failpoint",
|
|
"@org_uber_go_zap//:zap",
|
|
],
|
|
)
|
|
|
|
go_test(
|
|
name = "sort_exec_test",
|
|
timeout = "short",
|
|
srcs = ["sort_test.go"],
|
|
flaky = True,
|
|
shard_count = 13,
|
|
deps = [
|
|
"//pkg/config",
|
|
"//pkg/sessionctx/variable",
|
|
"//pkg/testkit",
|
|
"//pkg/util",
|
|
"@com_github_pingcap_failpoint//:failpoint",
|
|
"@com_github_stretchr_testify//require",
|
|
],
|
|
)
|
|
|
|
go_test(
|
|
name = "sortexec_test",
|
|
timeout = "short",
|
|
srcs = [
|
|
"benchmark_test.go",
|
|
"parallel_sort_spill_test.go",
|
|
"parallel_sort_test.go",
|
|
"sort_spill_test.go",
|
|
"sort_test.go",
|
|
"sortexec_pkg_test.go",
|
|
"topn_spill_test.go",
|
|
],
|
|
embed = [":sortexec"],
|
|
flaky = True,
|
|
shard_count = 6,
|
|
deps = [
|
|
"//pkg/config",
|
|
"//pkg/executor/internal/exec",
|
|
"//pkg/executor/internal/testutil",
|
|
"//pkg/expression",
|
|
"//pkg/expression/contextstatic",
|
|
"//pkg/parser/mysql",
|
|
"//pkg/planner/core",
|
|
"//pkg/planner/util",
|
|
"//pkg/sessionctx/variable",
|
|
"//pkg/testkit",
|
|
"//pkg/types",
|
|
"//pkg/util",
|
|
"//pkg/util/chunk",
|
|
"//pkg/util/dbterror/exeerrors",
|
|
"//pkg/util/memory",
|
|
"//pkg/util/mock",
|
|
"//pkg/util/sqlkiller",
|
|
"@com_github_pingcap_failpoint//:failpoint",
|
|
"@com_github_stretchr_testify//require",
|
|
],
|
|
)
|