diff --git a/executor/distsql_test.go b/executor/distsql_test.go index 04e9b56063..9e59deeb3c 100644 --- a/executor/distsql_test.go +++ b/executor/distsql_test.go @@ -95,7 +95,6 @@ func (s *testSuite) TestCopClientSend(c *C) { // Split the table. cli := tikv.GetMockTiKVClient(s.store) cli.Cluster.SplitTable(cli.MvccStore, tblID, 100) - tikv.ClearRegionCache(s.store) // Send coprocessor request when the table split. rss, err := tk.Se.Execute("select sum(id) from copclient") diff --git a/store/tikv/kv.go b/store/tikv/kv.go index 1ad78b7e8d..512f11cbd2 100644 --- a/store/tikv/kv.go +++ b/store/tikv/kv.go @@ -130,12 +130,6 @@ func GetMockTiKVClient(store kv.Storage) *mocktikv.RPCClient { return s.client.(*mocktikv.RPCClient) } -// ClearRegionCache clears the region cache in the store. -func ClearRegionCache(store kv.Storage) { - s := store.(*tikvStore) - s.regionCache = NewRegionCache(s.regionCache.pdClient) -} - func (s *tikvStore) Begin() (kv.Transaction, error) { txn, err := newTiKVTxn(s) if err != nil {