package
5.3.0-alpha+incompatible
Repository: https://github.com/pingcap/br.git
Documentation: pkg.go.dev
# Functions
EscapeIdentifier quote and escape an sql identifier.
GetJSON fetches a page and parses it as JSON.
GetStorageSize gets storage's capacity and available size.
No description provided by the author
IsContextCanceledError returns whether the error is caused by context cancellation.
IsDirExists checks if dir exists.
IsEmptyDir checks if dir is empty.
IsRetryableError returns whether the error is transient (e.g.
KillMySelf sends sigint to current process, used in integration test only
Only works on Unix.
newConnPool creates a new connPool by the specified conn factory function and capacity.
No description provided by the author
NewPauser returns an initialized pauser.
NewTLS constructs a new HTTP client with TLS configured with the CA, certificate and key paths.
NewTLSFromMockServer constructs a new TLS instance from the certificates of an *httptest.Server.
Retry is shared by SQLWithRetry.perform, implementation of GlueCheckpointsDB and TiDB's glue implementation.
SameDisk is used to check dir1 and dir2 in the same disk.
StringSliceEqual checks if two string slices are equal.
TableHasAutoRowID return whether table has auto generated row id.
ToTLSConfig constructs a `*tls.Config` from the CA, certification and key paths.
UniqueTable returns an unique table name.
Writes a MySQL identifier into the string builder.
# Structs
connPool is a lazy pool of gRPC channels.
No description provided by the author
KvPair is a pair of key and value.
MySQLConnectParam records the parameters needed to connect to a MySQL database.
OnceError is an error value which will can be assigned once.
Pauser is a type which could allow multiple goroutines to wait on demand, similar to a gate or traffic light.
SQLWithRetry constructs a retryable transaction.
StorageSize represents the storage's capacity and available size Learn from tidb-binlog source code.
TLS.