Documentation ¶
Index ¶
- Constants
- func Int64Slice2Str(values interface{}, sep string) (string, error)
- type BaseUndoLogManager
- func (m *BaseUndoLogManager) BatchDeleteUndoLog(xid []string, branchID []int64, conn *sql.Conn) error
- func (m *BaseUndoLogManager) DBType() types.DBType
- func (m *BaseUndoLogManager) DeleteUndoLog(ctx context.Context, xid string, branchID int64, conn *sql.Conn) error
- func (m *BaseUndoLogManager) FlushUndoLog(tranCtx *types.TransactionContext, conn driver.Conn) error
- func (m *BaseUndoLogManager) HasUndoLogTable(ctx context.Context, conn *sql.Conn) (res bool, err error)
- func (m *BaseUndoLogManager) Init()
- func (m *BaseUndoLogManager) InsertUndoLog(record undo.UndologRecord, conn driver.Conn) error
- func (m *BaseUndoLogManager) InsertUndoLogWithSqlConn(ctx context.Context, record undo.UndologRecord, conn *sql.Conn) error
- func (m *BaseUndoLogManager) RunUndo(ctx context.Context, xid string, branchID int64, conn *sql.DB, dbName string) error
- func (m *BaseUndoLogManager) Undo(ctx context.Context, dbType types.DBType, xid string, branchID int64, ...) (err error)
- func (m *BaseUndoLogManager) UnmarshalContext(undoContext []byte) (map[string]string, error)
Constants ¶
View Source
const ( // UndoLogStatusNormal This state can be properly rolled back by services UndoLogStatusNormal = iota // UndoLogStatusGlobalFinished This state prevents the branch transaction from inserting undo_log after the global transaction is rolled back. UndoLogStatusGlobalFinished )
undo log status
Variables ¶
This section is empty.
Functions ¶
func Int64Slice2Str ¶
Int64Slice2Str
Types ¶
type BaseUndoLogManager ¶
type BaseUndoLogManager struct{}
BaseUndoLogManager
func NewBaseUndoLogManager ¶
func NewBaseUndoLogManager() *BaseUndoLogManager
func (*BaseUndoLogManager) BatchDeleteUndoLog ¶
func (m *BaseUndoLogManager) BatchDeleteUndoLog(xid []string, branchID []int64, conn *sql.Conn) error
BatchDeleteUndoLog exec delete undo log operate
func (*BaseUndoLogManager) DeleteUndoLog ¶
func (m *BaseUndoLogManager) DeleteUndoLog(ctx context.Context, xid string, branchID int64, conn *sql.Conn) error
DeleteUndoLog exec delete single undo log operate
func (*BaseUndoLogManager) FlushUndoLog ¶
func (m *BaseUndoLogManager) FlushUndoLog(tranCtx *types.TransactionContext, conn driver.Conn) error
FlushUndoLog flush undo log
func (*BaseUndoLogManager) HasUndoLogTable ¶
func (m *BaseUndoLogManager) HasUndoLogTable(ctx context.Context, conn *sql.Conn) (res bool, err error)
HasUndoLogTable check undo log table if exist
func (*BaseUndoLogManager) InsertUndoLog ¶
func (m *BaseUndoLogManager) InsertUndoLog(record undo.UndologRecord, conn driver.Conn) error
InsertUndoLog
func (*BaseUndoLogManager) InsertUndoLogWithSqlConn ¶
func (m *BaseUndoLogManager) InsertUndoLogWithSqlConn(ctx context.Context, record undo.UndologRecord, conn *sql.Conn) error
func (*BaseUndoLogManager) RunUndo ¶
func (m *BaseUndoLogManager) RunUndo(ctx context.Context, xid string, branchID int64, conn *sql.DB, dbName string) error
RunUndo undo sql
func (*BaseUndoLogManager) Undo ¶
func (m *BaseUndoLogManager) Undo(ctx context.Context, dbType types.DBType, xid string, branchID int64, db *sql.DB, dbName string) (err error)
Undo undo sql
func (*BaseUndoLogManager) UnmarshalContext ¶
func (m *BaseUndoLogManager) UnmarshalContext(undoContext []byte) (map[string]string, error)
Click to show internal directories.
Click to hide internal directories.