Documentation ¶
Index ¶
- func AttachLocalTemporaryTableInfoSchema(sctx sessionctx.Context, is infoschema.InfoSchema) infoschema.InfoSchema
- func DetachLocalTemporaryTableInfoSchema(is infoschema.InfoSchema) infoschema.InfoSchema
- func SessionSnapshotInterceptor(sctx sessionctx.Context, is infoschema.InfoSchema) kv.SnapshotInterceptor
- type TemporaryTableDDL
- type TemporaryTableSnapshotInterceptor
- func (i *TemporaryTableSnapshotInterceptor) OnBatchGet(ctx context.Context, snap kv.Snapshot, keys []kv.Key) (map[string][]byte, error)
- func (i *TemporaryTableSnapshotInterceptor) OnGet(ctx context.Context, snap kv.Snapshot, k kv.Key) ([]byte, error)
- func (i *TemporaryTableSnapshotInterceptor) OnIter(snap kv.Snapshot, k kv.Key, upperBound kv.Key) (kv.Iterator, error)
- func (i *TemporaryTableSnapshotInterceptor) OnIterReverse(snap kv.Snapshot, k kv.Key, lowerBound kv.Key) (kv.Iterator, error)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func AttachLocalTemporaryTableInfoSchema ¶
func AttachLocalTemporaryTableInfoSchema(sctx sessionctx.Context, is infoschema.InfoSchema) infoschema.InfoSchema
AttachLocalTemporaryTableInfoSchema attach local temporary table information schema to is
func DetachLocalTemporaryTableInfoSchema ¶
func DetachLocalTemporaryTableInfoSchema(is infoschema.InfoSchema) infoschema.InfoSchema
DetachLocalTemporaryTableInfoSchema detach local temporary table information schema from is
func SessionSnapshotInterceptor ¶
func SessionSnapshotInterceptor(sctx sessionctx.Context, is infoschema.InfoSchema) kv.SnapshotInterceptor
SessionSnapshotInterceptor creates a new snapshot interceptor for temporary table data fetch
Types ¶
type TemporaryTableDDL ¶
type TemporaryTableDDL interface { CreateLocalTemporaryTable(db *model.DBInfo, info *model.TableInfo) error DropLocalTemporaryTable(schema model.CIStr, tblName model.CIStr) error TruncateLocalTemporaryTable(schema model.CIStr, tblName model.CIStr) error }
TemporaryTableDDL is an interface providing ddl operations for temporary table
func GetTemporaryTableDDL ¶
func GetTemporaryTableDDL(sctx sessionctx.Context) TemporaryTableDDL
GetTemporaryTableDDL gets the temptable.TemporaryTableDDL from session context
type TemporaryTableSnapshotInterceptor ¶
type TemporaryTableSnapshotInterceptor struct {
// contains filtered or unexported fields
}
TemporaryTableSnapshotInterceptor implements kv.SnapshotInterceptor
func NewTemporaryTableSnapshotInterceptor ¶
func NewTemporaryTableSnapshotInterceptor(is infoschema.InfoSchema, sessionData kv.Retriever) *TemporaryTableSnapshotInterceptor
NewTemporaryTableSnapshotInterceptor creates a new TemporaryTableSnapshotInterceptor
func (*TemporaryTableSnapshotInterceptor) OnBatchGet ¶
func (i *TemporaryTableSnapshotInterceptor) OnBatchGet(ctx context.Context, snap kv.Snapshot, keys []kv.Key) (map[string][]byte, error)
OnBatchGet intercepts BatchGet operation for Snapshot
func (*TemporaryTableSnapshotInterceptor) OnGet ¶
func (i *TemporaryTableSnapshotInterceptor) OnGet(ctx context.Context, snap kv.Snapshot, k kv.Key) ([]byte, error)
OnGet intercepts Get operation for Snapshot