From 8fd09cd88ccefe8ea84887e96faa98419496085e Mon Sep 17 00:00:00 2001 From: Hu# Date: Thu, 2 Feb 2023 18:11:45 +0800 Subject: [PATCH] config support both path and names (#683) Signed-off-by: HuSharp --- .github/workflows/test.yml | 6 +++--- examples/gcworker/go.mod | 2 +- examples/rawkv/go.mod | 2 +- examples/txnkv/1pc_txn/go.mod | 2 +- examples/txnkv/async_commit/go.mod | 2 +- examples/txnkv/delete_range/go.mod | 2 +- examples/txnkv/go.mod | 2 +- examples/txnkv/pessimistic_txn/go.mod | 2 +- examples/txnkv/unsafedestoryrange/go.mod | 2 +- go.mod | 8 ++++---- go.sum | 13 ++++++------- integration_tests/go.mod | 12 +++++++----- integration_tests/go.sum | 21 +++++++++++---------- integration_tests/split_test.go | 3 +-- internal/mockstore/mocktikv/pd.go | 2 +- 15 files changed, 41 insertions(+), 40 deletions(-) diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index 811fc6778b..a83875db6d 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -15,7 +15,7 @@ jobs: - name: Set up Go uses: actions/setup-go@v2 with: - go-version: 1.18 + go-version: 1.19 - name: Test run: go test ./... @@ -28,7 +28,7 @@ jobs: - name: Set up Go uses: actions/setup-go@v2 with: - go-version: 1.18 + go-version: 1.19 - name: Test with race run: go test -race ./... @@ -42,7 +42,7 @@ jobs: - name: Set up Go uses: actions/setup-go@v2 with: - go-version: 1.18 + go-version: 1.19 - name: Lint uses: golangci/golangci-lint-action@v2.5.2 diff --git a/examples/gcworker/go.mod b/examples/gcworker/go.mod index 1f7ccaaafd..1a2348df1c 100644 --- a/examples/gcworker/go.mod +++ b/examples/gcworker/go.mod @@ -1,6 +1,6 @@ module gcworker -go 1.18 +go 1.19 require github.com/tikv/client-go/v2 v2.0.0 diff --git a/examples/rawkv/go.mod b/examples/rawkv/go.mod index ba37c68828..ce3b5fb8e8 100644 --- a/examples/rawkv/go.mod +++ b/examples/rawkv/go.mod @@ -1,6 +1,6 @@ module rawkv -go 1.18 +go 1.19 require github.com/tikv/client-go/v2 v2.0.0 diff --git a/examples/txnkv/1pc_txn/go.mod b/examples/txnkv/1pc_txn/go.mod index 3f1f94933a..8fa5bc66eb 100644 --- a/examples/txnkv/1pc_txn/go.mod +++ b/examples/txnkv/1pc_txn/go.mod @@ -1,6 +1,6 @@ module 1pc_txn -go 1.18 +go 1.19 require github.com/tikv/client-go/v2 v2.0.0 diff --git a/examples/txnkv/async_commit/go.mod b/examples/txnkv/async_commit/go.mod index 92922d3a0d..f69fd114cc 100644 --- a/examples/txnkv/async_commit/go.mod +++ b/examples/txnkv/async_commit/go.mod @@ -1,6 +1,6 @@ module async_commit -go 1.18 +go 1.19 require github.com/tikv/client-go/v2 v2.0.0 diff --git a/examples/txnkv/delete_range/go.mod b/examples/txnkv/delete_range/go.mod index 562f01167b..d1ac1e950f 100644 --- a/examples/txnkv/delete_range/go.mod +++ b/examples/txnkv/delete_range/go.mod @@ -1,6 +1,6 @@ module delete_range -go 1.18 +go 1.19 require github.com/tikv/client-go/v2 v2.0.0 diff --git a/examples/txnkv/go.mod b/examples/txnkv/go.mod index 4363f6cd35..17e459fe93 100644 --- a/examples/txnkv/go.mod +++ b/examples/txnkv/go.mod @@ -1,6 +1,6 @@ module txnkv -go 1.18 +go 1.19 require github.com/tikv/client-go/v2 v2.0.0 diff --git a/examples/txnkv/pessimistic_txn/go.mod b/examples/txnkv/pessimistic_txn/go.mod index 625003fa7e..be89291ba6 100644 --- a/examples/txnkv/pessimistic_txn/go.mod +++ b/examples/txnkv/pessimistic_txn/go.mod @@ -1,6 +1,6 @@ module pessimistic_txn -go 1.18 +go 1.19 require github.com/tikv/client-go/v2 v2.0.0 diff --git a/examples/txnkv/unsafedestoryrange/go.mod b/examples/txnkv/unsafedestoryrange/go.mod index 2a09bbe413..144a2ff661 100644 --- a/examples/txnkv/unsafedestoryrange/go.mod +++ b/examples/txnkv/unsafedestoryrange/go.mod @@ -1,6 +1,6 @@ module unsafedestoryrange -go 1.18 +go 1.19 require github.com/tikv/client-go/v2 v2.0.0 diff --git a/go.mod b/go.mod index a10c770453..027a8ae0e7 100644 --- a/go.mod +++ b/go.mod @@ -1,6 +1,6 @@ module github.com/tikv/client-go/v2 -go 1.18 +go 1.19 require ( github.com/cznic/mathutil v0.0.0-20181122101859-297441e03548 @@ -14,7 +14,7 @@ require ( github.com/pingcap/errors v0.11.5-0.20211224045212-9687c2b0f87c github.com/pingcap/failpoint v0.0.0-20210918120811-547c13e3eb00 github.com/pingcap/goleveldb v0.0.0-20191226122134-f82aafb29989 - github.com/pingcap/kvproto v0.0.0-20230119031034-25f1909b7934 + github.com/pingcap/kvproto v0.0.0-20230201112839-2b853bed8125 github.com/pingcap/log v1.1.1-0.20221110025148-ca232912c9f3 github.com/pkg/errors v0.9.1 github.com/prometheus/client_golang v1.11.0 @@ -22,8 +22,8 @@ require ( github.com/stathat/consistent v1.0.0 github.com/stretchr/testify v1.8.1 github.com/tiancaiamao/gp v0.0.0-20221230034425-4025bc8a4d4a - github.com/tikv/pd v1.1.0-beta.0.20230119114149-402c2bfee2f3 - github.com/tikv/pd/client v0.0.0-20230118040950-082fc6a9bc2e + github.com/tikv/pd v1.1.0-beta.0.20230202094356-18df271ce57f + github.com/tikv/pd/client v0.0.0-20230202094356-18df271ce57f github.com/twmb/murmur3 v1.1.3 go.etcd.io/etcd/api/v3 v3.5.2 go.etcd.io/etcd/client/v3 v3.5.2 diff --git a/go.sum b/go.sum index 0a71c25d36..5f1ebb7010 100644 --- a/go.sum +++ b/go.sum @@ -601,9 +601,8 @@ github.com/pingcap/failpoint v0.0.0-20210918120811-547c13e3eb00 h1:C3N3itkduZXDZ github.com/pingcap/failpoint v0.0.0-20210918120811-547c13e3eb00/go.mod h1:4qGtCB0QK0wBzKtFEGDhxXnSnbQApw1gc9siScUl8ew= github.com/pingcap/goleveldb v0.0.0-20191226122134-f82aafb29989 h1:surzm05a8C9dN8dIUmo4Be2+pMRb6f55i+UIYrluu2E= github.com/pingcap/goleveldb v0.0.0-20191226122134-f82aafb29989/go.mod h1:O17XtbryoCJhkKGbT62+L2OlrniwqiGLSqrmdHCMzZw= -github.com/pingcap/kvproto v0.0.0-20230117104311-1bc802baaad6/go.mod h1:+on3Lfk/fb1lXkud3XvskJumhSIEEgN2TTbMObUlrxE= -github.com/pingcap/kvproto v0.0.0-20230119031034-25f1909b7934 h1:LB+BrfyO5fsz5pwN3V4HvTrpZTAmsjB4VkCEBLbjYUw= -github.com/pingcap/kvproto v0.0.0-20230119031034-25f1909b7934/go.mod h1:+on3Lfk/fb1lXkud3XvskJumhSIEEgN2TTbMObUlrxE= +github.com/pingcap/kvproto v0.0.0-20230201112839-2b853bed8125 h1:ZiCJcEzmmF5xNgt8GIXekd3WQXI/22kzYQnrHi3Fc/4= +github.com/pingcap/kvproto v0.0.0-20230201112839-2b853bed8125/go.mod h1:+on3Lfk/fb1lXkud3XvskJumhSIEEgN2TTbMObUlrxE= github.com/pingcap/log v1.1.1-0.20221110025148-ca232912c9f3 h1:HR/ylkkLmGdSSDaD8IDP+SZrdhV1Kibl9KrHxJ9eciw= github.com/pingcap/log v1.1.1-0.20221110025148-ca232912c9f3/go.mod h1:DWQW5jICDR7UJh4HtxXSM20Churx4CQL0fwL/SoOSA4= github.com/pkg/errors v0.8.0/go.mod h1:bwawxfHBFNV+L2hUp1rHADufV3IMtnDRdf1r5NINEl0= @@ -658,10 +657,10 @@ github.com/stretchr/testify v1.8.1 h1:w7B6lhMri9wdJUVmEZPGGhZzrYTPvgJArz7wNPgYKs github.com/stretchr/testify v1.8.1/go.mod h1:w2LPCIKwWwSfY2zedu0+kehJoqGctiVI29o6fzry7u4= github.com/tiancaiamao/gp v0.0.0-20221230034425-4025bc8a4d4a h1:J/YdBZ46WKpXsxsW93SG+q0F8KI+yFrcIDT4c/RNoc4= github.com/tiancaiamao/gp v0.0.0-20221230034425-4025bc8a4d4a/go.mod h1:h4xBhSNtOeEosLJ4P7JyKXX7Cabg7AVkWCK5gV2vOrM= -github.com/tikv/pd v1.1.0-beta.0.20230119114149-402c2bfee2f3 h1:cj3bhdIBJcLL2304EDEmd3eX+r73+hbGSYRFn/APiDU= -github.com/tikv/pd v1.1.0-beta.0.20230119114149-402c2bfee2f3/go.mod h1:IFQZ85uu1438yp7Tb0xCgvw/BdSPReB9zcJsxXbyTP4= -github.com/tikv/pd/client v0.0.0-20230118040950-082fc6a9bc2e h1:MD/PZa8Hcv7dg3cFY0tO+g+OPMhTW3O3tXetE80SjbY= -github.com/tikv/pd/client v0.0.0-20230118040950-082fc6a9bc2e/go.mod h1:yRGXx64wsS1dGsjtyeBm6Iy6DItkYkbcQ9+Hj9OED4U= +github.com/tikv/pd v1.1.0-beta.0.20230202094356-18df271ce57f h1:iY/RztOIZ2nTbINUiLGsSv3SUGoEiub1GN0SKVKHJYg= +github.com/tikv/pd v1.1.0-beta.0.20230202094356-18df271ce57f/go.mod h1:jb9oq6rN4U0U3FZdvqWlpi9rZzFJxiOlvZ3aj5BTpg8= +github.com/tikv/pd/client v0.0.0-20230202094356-18df271ce57f h1:xHPPej9Z8IrYdyLED4byOGtGm/7yhxyRUf4m93CpDyg= +github.com/tikv/pd/client v0.0.0-20230202094356-18df271ce57f/go.mod h1:0fdKmj9cafPLsHAeVAcgB50Uj018WGfMC1tgvzWXXQQ= github.com/twmb/murmur3 v1.1.3 h1:D83U0XYKcHRYwYIpBKf3Pks91Z0Byda/9SJ8B6EMRcA= github.com/twmb/murmur3 v1.1.3/go.mod h1:Qq/R7NUyOfr65zD+6Q5IHKsJLwP7exErjN6lyyq3OSQ= github.com/yuin/goldmark v1.1.25/go.mod h1:3hX8gzYuyVAZsxl0MRgGTJEmQBFcNTphYh9decYSb74= diff --git a/integration_tests/go.mod b/integration_tests/go.mod index b093968da1..94d4aef814 100644 --- a/integration_tests/go.mod +++ b/integration_tests/go.mod @@ -1,18 +1,18 @@ module integration_tests -go 1.18 +go 1.19 require ( github.com/ninedraft/israce v0.0.3 github.com/pingcap/errors v0.11.5-0.20221009092201-b66cddb77c32 github.com/pingcap/failpoint v0.0.0-20220423142525-ae43b7f4e5c3 - github.com/pingcap/kvproto v0.0.0-20230119031034-25f1909b7934 + github.com/pingcap/kvproto v0.0.0-20230201112839-2b853bed8125 github.com/pingcap/tidb v0.0.0-20230120062950-38a7c6220ea6 github.com/pkg/errors v0.9.1 github.com/stretchr/testify v1.8.1 github.com/tidwall/gjson v1.14.1 github.com/tikv/client-go/v2 v2.0.5-0.20230120021435-f89383775234 - github.com/tikv/pd/client v0.0.0-20230119115149-5c518d079b93 + github.com/tikv/pd/client v0.0.0-20230202094356-18df271ce57f go.uber.org/goleak v1.2.0 ) @@ -72,7 +72,7 @@ require ( github.com/tiancaiamao/gp v0.0.0-20221230034425-4025bc8a4d4a // indirect github.com/tidwall/match v1.1.1 // indirect github.com/tidwall/pretty v1.2.0 // indirect - github.com/tikv/pd v1.1.0-beta.0.20230119114149-402c2bfee2f3 // indirect + github.com/tikv/pd v1.1.0-beta.0.20230202094356-18df271ce57f // indirect github.com/twmb/murmur3 v1.1.3 // indirect github.com/uber/jaeger-client-go v2.30.0+incompatible // indirect github.com/uber/jaeger-lib v2.4.1+incompatible // indirect @@ -89,7 +89,7 @@ require ( golang.org/x/sys v0.4.0 // indirect golang.org/x/text v0.6.0 // indirect golang.org/x/time v0.3.0 // indirect - golang.org/x/tools v0.2.0 // indirect + golang.org/x/tools v0.5.0 // indirect google.golang.org/genproto v0.0.0-20221202195650-67e5cbc046fd // indirect google.golang.org/grpc v1.51.0 // indirect google.golang.org/protobuf v1.28.1 // indirect @@ -98,3 +98,5 @@ require ( ) replace github.com/tikv/client-go/v2 => ../ + +replace github.com/pingcap/tidb => github.com/HuSharp/tidb v0.0.0-20230201105642-2ff0bda68903 diff --git a/integration_tests/go.sum b/integration_tests/go.sum index 58c1c30ff7..c820cda6ec 100644 --- a/integration_tests/go.sum +++ b/integration_tests/go.sum @@ -392,6 +392,8 @@ github.com/CloudyKit/fastprinter v0.0.0-20170127035650-74b38d55f37a/go.mod h1:EF github.com/CloudyKit/jet v2.1.3-0.20180809161101-62edd43e4f88+incompatible/go.mod h1:HPYO+50pSWkPoj9Q/eq0aRGByCL6ScRlUmiEX5Zgm+w= github.com/DataDog/zstd v1.4.5 h1:EndNeuB0l9syBZhut0wns3gV1hL8zX8LIu6ZiVHWLIQ= github.com/HdrHistogram/hdrhistogram-go v1.1.2 h1:5IcZpTvzydCQeHzK4Ef/D5rrSqwxob0t8PQPMybUNFM= +github.com/HuSharp/tidb v0.0.0-20230201105642-2ff0bda68903 h1:8Mg/diY1+lOVBF8qDsbFwvYrq8mg4PTVhktejI6H5nE= +github.com/HuSharp/tidb v0.0.0-20230201105642-2ff0bda68903/go.mod h1:Wh2kr4+vtRttC2DMM5670CCCoOKiHprSLsopH7Jpbng= github.com/Joker/hpp v1.0.0/go.mod h1:8x5n+M1Hp5hC0g8okX3sR3vFQwynaX/UgSOM9MeBKzY= github.com/Joker/jade v1.0.1-0.20190614124447-d475f43051e7/go.mod h1:6E6s8o2AE4KhCrqr6GRJjdC/gNfTdxkIXvuGZZda2VM= github.com/Masterminds/semver v1.5.0 h1:H65muMkzWKEuNDnfl9d70GUjFniHKHRbFPGBuZ3QEww= @@ -791,15 +793,13 @@ github.com/pingcap/failpoint v0.0.0-20220423142525-ae43b7f4e5c3/go.mod h1:4qGtCB github.com/pingcap/fn v0.0.0-20200306044125-d5540d389059 h1:Pe2LbxRmbTfAoKJ65bZLmhahmvHm7n9DUxGRQT00208= github.com/pingcap/goleveldb v0.0.0-20191226122134-f82aafb29989 h1:surzm05a8C9dN8dIUmo4Be2+pMRb6f55i+UIYrluu2E= github.com/pingcap/goleveldb v0.0.0-20191226122134-f82aafb29989/go.mod h1:O17XtbryoCJhkKGbT62+L2OlrniwqiGLSqrmdHCMzZw= -github.com/pingcap/kvproto v0.0.0-20230119031034-25f1909b7934 h1:LB+BrfyO5fsz5pwN3V4HvTrpZTAmsjB4VkCEBLbjYUw= -github.com/pingcap/kvproto v0.0.0-20230119031034-25f1909b7934/go.mod h1:+on3Lfk/fb1lXkud3XvskJumhSIEEgN2TTbMObUlrxE= +github.com/pingcap/kvproto v0.0.0-20230201112839-2b853bed8125 h1:ZiCJcEzmmF5xNgt8GIXekd3WQXI/22kzYQnrHi3Fc/4= +github.com/pingcap/kvproto v0.0.0-20230201112839-2b853bed8125/go.mod h1:+on3Lfk/fb1lXkud3XvskJumhSIEEgN2TTbMObUlrxE= github.com/pingcap/log v1.1.0/go.mod h1:DWQW5jICDR7UJh4HtxXSM20Churx4CQL0fwL/SoOSA4= github.com/pingcap/log v1.1.1-0.20221110025148-ca232912c9f3/go.mod h1:DWQW5jICDR7UJh4HtxXSM20Churx4CQL0fwL/SoOSA4= github.com/pingcap/log v1.1.1-0.20221116035753-734d527bc87c h1:crhkw6DD+07Bg1wYhW5Piw+kYNKZqFQqfC2puUf6gMI= github.com/pingcap/log v1.1.1-0.20221116035753-734d527bc87c/go.mod h1:DWQW5jICDR7UJh4HtxXSM20Churx4CQL0fwL/SoOSA4= github.com/pingcap/sysutil v0.0.0-20220114020952-ea68d2dbf5b4 h1:HYbcxtnkN3s5tqrZ/z3eJS4j3Db8wMphEm1q10lY/TM= -github.com/pingcap/tidb v0.0.0-20230120062950-38a7c6220ea6 h1:UrysnVknfSA15v/h7nShX1xsZ+RmFkHLNVXTtJbkNoQ= -github.com/pingcap/tidb v0.0.0-20230120062950-38a7c6220ea6/go.mod h1:gmWCo8AR9PRtJAPa+fZ0ub8r9i9ZXtrA/HXayhhDCYM= github.com/pingcap/tidb/parser v0.0.0-20230109054422-b477b1c94620 h1:cEP+A7ylw8sGGOCHe8F8gto+vlkGQaYt09DHgHd2xmg= github.com/pingcap/tidb/parser v0.0.0-20230109054422-b477b1c94620/go.mod h1:wjvp+T3/T9XYt0nKqGX3Kc1AKuyUcfno6LTc6b2A6ew= github.com/pingcap/tipb v0.0.0-20230119054146-c6b7a5a1623b h1:j5sw2YZY7QfgIFZEoUcn1P5cYflms1PCVVS96i+IQiI= @@ -874,6 +874,7 @@ github.com/spf13/pflag v1.0.3/go.mod h1:DYY7MBk1bdzusC3SYhjObp+wFpr4gzcvqqNjLnIn github.com/spf13/pflag v1.0.5 h1:iy+VFUOCP1a+8yFto/drg2CJ5u0yRoB7fZw3DKv/JXA= github.com/spf13/pflag v1.0.5/go.mod h1:McXfInJRrz4CZXVZOBLb0bTZqETkiAhM9Iw0y3An2Bg= github.com/spf13/viper v1.3.2/go.mod h1:ZiWeW+zYFKm7srdB9IoDzzZXaJaI5eL9QjNiN/DMA2s= +github.com/spkg/bom v1.0.0 h1:S939THe0ukL5WcTGiGqkgtaW5JW+O6ITaIlpJXTYY64= github.com/stathat/consistent v1.0.0 h1:ZFJ1QTRn8npNBKW065raSZ8xfOqhpb8vLOkfp4CcL/U= github.com/stathat/consistent v1.0.0/go.mod h1:uajTPbgSygZBJ+V+0mY7meZ8i0XAcZs7AQ6V121XSxw= github.com/stretchr/objx v0.1.0/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+wExME= @@ -900,10 +901,10 @@ github.com/tidwall/match v1.1.1 h1:+Ho715JplO36QYgwN9PGYNhgZvoUSc9X2c80KVTi+GA= github.com/tidwall/match v1.1.1/go.mod h1:eRSPERbgtNPcGhD8UCthc6PmLEQXEWd3PRB5JTxsfmM= github.com/tidwall/pretty v1.2.0 h1:RWIZEg2iJ8/g6fDDYzMpobmaoGh5OLl4AXtGUGPcqCs= github.com/tidwall/pretty v1.2.0/go.mod h1:ITEVvHYasfjBbM0u2Pg8T2nJnzm8xPwvNhhsoaGGjNU= -github.com/tikv/pd v1.1.0-beta.0.20230119114149-402c2bfee2f3 h1:cj3bhdIBJcLL2304EDEmd3eX+r73+hbGSYRFn/APiDU= -github.com/tikv/pd v1.1.0-beta.0.20230119114149-402c2bfee2f3/go.mod h1:IFQZ85uu1438yp7Tb0xCgvw/BdSPReB9zcJsxXbyTP4= -github.com/tikv/pd/client v0.0.0-20230119115149-5c518d079b93 h1:KK5bx0KLcpYUCnuQ06THPYT6QdAMfvwAtRQ0saVGD7k= -github.com/tikv/pd/client v0.0.0-20230119115149-5c518d079b93/go.mod h1:NrbwVp9afaCmJjJEwFNtEQWfCChAW1ndnwjteHHS+d0= +github.com/tikv/pd v1.1.0-beta.0.20230202094356-18df271ce57f h1:iY/RztOIZ2nTbINUiLGsSv3SUGoEiub1GN0SKVKHJYg= +github.com/tikv/pd v1.1.0-beta.0.20230202094356-18df271ce57f/go.mod h1:jb9oq6rN4U0U3FZdvqWlpi9rZzFJxiOlvZ3aj5BTpg8= +github.com/tikv/pd/client v0.0.0-20230202094356-18df271ce57f h1:xHPPej9Z8IrYdyLED4byOGtGm/7yhxyRUf4m93CpDyg= +github.com/tikv/pd/client v0.0.0-20230202094356-18df271ce57f/go.mod h1:0fdKmj9cafPLsHAeVAcgB50Uj018WGfMC1tgvzWXXQQ= github.com/tklauser/go-sysconf v0.3.10 h1:IJ1AZGZRWbY8T5Vfk04D9WOA5WSejdflXxP03OUqALw= github.com/tklauser/go-sysconf v0.3.10/go.mod h1:C8XykCvCb+Gn0oNCWPIlcb0RuglQTYaQ2hGm7jmxEFk= github.com/tklauser/numcpus v0.4.0 h1:E53Dm1HjH1/R2/aoCtXtPgzmElmn51aOkhCFSuZq//o= @@ -1318,8 +1319,8 @@ golang.org/x/tools v0.1.3/go.mod h1:o0xws9oXOQQZyjljx8fwUC0k7L1pTE6eaCbjGeHmOkk= golang.org/x/tools v0.1.4/go.mod h1:o0xws9oXOQQZyjljx8fwUC0k7L1pTE6eaCbjGeHmOkk= golang.org/x/tools v0.1.5/go.mod h1:o0xws9oXOQQZyjljx8fwUC0k7L1pTE6eaCbjGeHmOkk= golang.org/x/tools v0.1.12/go.mod h1:hNGJHUnrk76NpqgfD5Aqm5Crs+Hm0VOH/i9J2+nxYbc= -golang.org/x/tools v0.2.0 h1:G6AHpWxTMGY1KyEYoAQ5WTtIekUUvDNjan3ugu60JvE= -golang.org/x/tools v0.2.0/go.mod h1:y4OqIKeOV/fWJetJ8bXPU1sEVniLMIyDAZWeHdV+NTA= +golang.org/x/tools v0.5.0 h1:+bSpV5HIeWkuvgaMfI3UmKRThoTA5ODJTUd8T17NO+4= +golang.org/x/tools v0.5.0/go.mod h1:N+Kgy78s5I24c24dU8OfWNEotWjutIs8SnJvn5IDq+k= golang.org/x/xerrors v0.0.0-20190717185122-a985d3407aa7/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= golang.org/x/xerrors v0.0.0-20191011141410-1b5146add898/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= golang.org/x/xerrors v0.0.0-20191204190536-9bdfabe68543/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= diff --git a/integration_tests/split_test.go b/integration_tests/split_test.go index f0bc624cae..012d9d840c 100644 --- a/integration_tests/split_test.go +++ b/integration_tests/split_test.go @@ -142,7 +142,7 @@ type mockPDClient struct { stop bool } -func (c *mockPDClient) LoadGlobalConfig(ctx context.Context, configPath string) ([]pd.GlobalConfigItem, int64, error) { +func (c *mockPDClient) LoadGlobalConfig(ctx context.Context, names []string, configPath string) ([]pd.GlobalConfigItem, int64, error) { return nil, 0, nil } @@ -337,4 +337,3 @@ func (c *mockPDClient) GetExternalTimestamp(ctx context.Context) (uint64, error) func (c *mockPDClient) SetExternalTimestamp(ctx context.Context, tso uint64) error { panic("unimplemented") } - diff --git a/internal/mockstore/mocktikv/pd.go b/internal/mockstore/mocktikv/pd.go index d392d08c7c..b021081673 100644 --- a/internal/mockstore/mocktikv/pd.go +++ b/internal/mockstore/mocktikv/pd.go @@ -79,7 +79,7 @@ func NewPDClient(cluster *Cluster) pd.Client { } } -func (c *pdClient) LoadGlobalConfig(ctx context.Context, configPath string) ([]pd.GlobalConfigItem, int64, error) { +func (c *pdClient) LoadGlobalConfig(ctx context.Context, names []string, configPath string) ([]pd.GlobalConfigItem, int64, error) { return nil, 0, nil }