package
9.0.0-alpha+incompatible
Repository: https://github.com/pingcap/tidb.git
Documentation: pkg.go.dev
# Functions
BootstrapWithMultiRegions initializes a Cluster with multiple Regions and 1 Store.
BootstrapWithMultiStores initializes a Cluster with 1 Region and n Stores.
BootstrapWithSingleStore initializes a Cluster with 1 Region and 1 Store.
ImageAvailable checks whether the store image file is available.
NewMockStore creates a mocked tikv store, the path is the file path to store the data.
WithClientHijacker hijacks KV client's behavior, makes it easy to simulate the network problem between TiDB and TiKV.
WithClusterInspector lets user to inspect the mock cluster handler.
WithDDLChecker prepare injected DDL implementation for the domain of this store.
WithKeyspaceMeta lets user set the keyspace meta.
WithMockTiFlash sets the mockStore to have N TiFlash stores (naming as tiflash0, tiflash1, ...).
WithMultipleOptions merges multiple options into one option.
WithPath specifies the mocktikv path.
WithPDAddr set pd address for pd service discovery in mock PD client.
WithPDClientHijacker hijacks PD client's behavior, makes it easy to simulate the network problem between TiDB and PD.
WithStoreType lets user choose the backend storage's type.
WithTiKVOptions sets KV options.
WithTxnLocalLatches enable txnLocalLatches, when capacity > 0.
# Constants
EmbedUnistore is the mock storage based on unistore.
ImageFilePath is used by testing, it's the file path for the bootstraped store image.
MockTiKV is the mock storage based on goleveldb.
# Variables
DDLCheckerInjector is used to break import cycle.
# Structs
EmbedUnistoreDriver is in embedded unistore driver.
MockTiKVDriver is in memory mock TiKV driver.
# Type aliases
MockTiKVStoreOption is used to control some behavior of mock tikv.
StoreType is the type of backend mock storage.