Documentation ¶
Index ¶
- func AssertUserDBsEmpty(dom *domain.Domain) error
- func GetTS(ctx context.Context, pdClient pd.Client) (uint64, error)
- func GetTSWithRetry(ctx context.Context, pdClient pd.Client) (uint64, error)
- func GetTableSchema(dom *domain.Domain, dbName pmodel.CIStr, tableName pmodel.CIStr) (*model.TableInfo, error)
- func RestorePostWork(ctx context.Context, switcher *ImportModeSwitcher, ...)
- func RestorePreWork(ctx context.Context, mgr *conn.Mgr, switcher *ImportModeSwitcher, ...) (pdutil.UndoFunc, *pdutil.ClusterConfig, error)
- func TransferBoolToValue(enable bool) string
- type Granularity
- type ImportModeSwitcher
- type UniqueTableName
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func AssertUserDBsEmpty ¶
AssertUserDBsEmpty check whether user dbs exist in the cluster
func GetTSWithRetry ¶
GetTSWithRetry gets a new timestamp with retry from PD.
func GetTableSchema ¶
func GetTableSchema( dom *domain.Domain, dbName pmodel.CIStr, tableName pmodel.CIStr, ) (*model.TableInfo, error)
GetTableSchema returns the schema of a table from TiDB.
func RestorePostWork ¶
func RestorePostWork( ctx context.Context, switcher *ImportModeSwitcher, restoreSchedulers pdutil.UndoFunc, isOnline bool, )
RestorePostWork executes some post work after restore. TODO: aggregate all lifetime manage methods into batcher's context manager field.
func RestorePreWork ¶
func RestorePreWork( ctx context.Context, mgr *conn.Mgr, switcher *ImportModeSwitcher, isOnline bool, switchToImport bool, ) (pdutil.UndoFunc, *pdutil.ClusterConfig, error)
RestorePreWork executes some prepare work before restore. TODO make this function returns a restore post work.
func TransferBoolToValue ¶
Types ¶
type Granularity ¶
type Granularity string
deprecated parameter
const ( FineGrained Granularity = "fine-grained" CoarseGrained Granularity = "coarse-grained" )
type ImportModeSwitcher ¶
type ImportModeSwitcher struct {
// contains filtered or unexported fields
}
func NewImportModeSwitcher ¶
type UniqueTableName ¶
Click to show internal directories.
Click to hide internal directories.