Documentation
¶
Index ¶
- Constants
- Variables
- func BuildTable(ctx context.Context, bcs *block.Cursor, name string, ...) (*TableRoot, *Table, error)
- func GetDbContext(ctx *sql.Context) context.Context
- func MarshalTableRowKey(nonce uint64) []byte
- func NewDatabaseRootBlock() block.Block
- func NewMysqlGorm(ctx context.Context, le *logrus.Entry, tx *Tx, conf *gorm.Config, dsn string) (*gorm.DB, *sql.DB, error)
- func NewRootBlock() block.Block
- func NewSqlConnector(ctx context.Context, tx *Tx, dsn string) (driver.Connector, error)
- func NewSqlDb(ctx context.Context, tx *Tx, dsn string) (*sql.DB, error)
- func NewSqlDriver(ctx context.Context, tx *Tx, driverOpts *gdriver.Options) *gdriver.Driver
- func NewTableRootBlock() block.Block
- func NewTableRowBlock() block.Block
- func ParseColumnType(typeStr string) (*sqlparser.ColumnType, error)
- func UnmarshalTableRowKey(dat []byte) (uint64, error)
- type CommitFn
- type Database
- func (d *Database) CreateTable(ctx *sql.Context, name string, schema sql.PrimaryKeySchema, ...) error
- func (d *Database) DropTable(ctx *sql.Context, name string) error
- func (d *Database) GetTableInsensitive(ctx *sql.Context, tblName string) (sql.Table, bool, error)
- func (d *Database) GetTableNames(ctx *sql.Context) ([]string, error)
- func (d *Database) IsReadOnly() bool
- func (d *Database) Name() string
- func (d *Database) RenameTable(ctx *sql.Context, oldName, newName string) error
- func (d *Database) TableCount() int
- type DatabaseRoot
- func (r *DatabaseRoot) ApplySubBlock(id uint32, next block.SubBlock) error
- func (m *DatabaseRoot) CloneMessageVT() protobuf_go_lite.CloneMessage
- func (m *DatabaseRoot) CloneVT() *DatabaseRoot
- func (this *DatabaseRoot) EqualMessageVT(thatMsg any) bool
- func (this *DatabaseRoot) EqualVT(that *DatabaseRoot) bool
- func (r *DatabaseRoot) GetRootTableSet(bcs *block.Cursor) *namedsbset.NamedSubBlockSet
- func (r *DatabaseRoot) GetSubBlockCtor(id uint32) block.SubBlockCtor
- func (r *DatabaseRoot) GetSubBlocks() map[uint32]block.SubBlock
- func (x *DatabaseRoot) GetTables() []*DatabaseRootTable
- func (r *DatabaseRoot) InsertTable(name string, ref *block.BlockRef, bcs *block.Cursor) (*block.Cursor, bool)
- func (r *DatabaseRoot) IsNil() bool
- func (r *DatabaseRoot) MarshalBlock() ([]byte, error)
- func (x *DatabaseRoot) MarshalJSON() ([]byte, error)
- func (x *DatabaseRoot) MarshalProtoJSON(s *json.MarshalState)
- func (x *DatabaseRoot) MarshalProtoText() string
- func (m *DatabaseRoot) MarshalToSizedBufferVT(dAtA []byte) (int, error)
- func (m *DatabaseRoot) MarshalToVT(dAtA []byte) (int, error)
- func (m *DatabaseRoot) MarshalVT() (dAtA []byte, err error)
- func (*DatabaseRoot) ProtoMessage()
- func (x *DatabaseRoot) Reset()
- func (m *DatabaseRoot) SizeVT() (n int)
- func (x *DatabaseRoot) String() string
- func (r *DatabaseRoot) UnmarshalBlock(data []byte) error
- func (x *DatabaseRoot) UnmarshalJSON(b []byte) error
- func (x *DatabaseRoot) UnmarshalProtoJSON(s *json.UnmarshalState)
- func (m *DatabaseRoot) UnmarshalVT(dAtA []byte) error
- func (r *DatabaseRoot) Validate() error
- type DatabaseRootTable
- func (r *DatabaseRootTable) ApplyBlockRef(id uint32, ptr *block.BlockRef) error
- func (m *DatabaseRootTable) CloneMessageVT() protobuf_go_lite.CloneMessage
- func (m *DatabaseRootTable) CloneVT() *DatabaseRootTable
- func (this *DatabaseRootTable) EqualMessageVT(thatMsg any) bool
- func (this *DatabaseRootTable) EqualVT(that *DatabaseRootTable) bool
- func (r *DatabaseRootTable) GetBlockRefCtor(id uint32) block.Ctor
- func (r *DatabaseRootTable) GetBlockRefs() (map[uint32]*block.BlockRef, error)
- func (x *DatabaseRootTable) GetName() string
- func (x *DatabaseRootTable) GetRef() *block.BlockRef
- func (r *DatabaseRootTable) IsNil() bool
- func (x *DatabaseRootTable) MarshalJSON() ([]byte, error)
- func (x *DatabaseRootTable) MarshalProtoJSON(s *json.MarshalState)
- func (x *DatabaseRootTable) MarshalProtoText() string
- func (m *DatabaseRootTable) MarshalToSizedBufferVT(dAtA []byte) (int, error)
- func (m *DatabaseRootTable) MarshalToVT(dAtA []byte) (int, error)
- func (m *DatabaseRootTable) MarshalVT() (dAtA []byte, err error)
- func (*DatabaseRootTable) ProtoMessage()
- func (x *DatabaseRootTable) Reset()
- func (m *DatabaseRootTable) SizeVT() (n int)
- func (x *DatabaseRootTable) String() string
- func (x *DatabaseRootTable) UnmarshalJSON(b []byte) error
- func (x *DatabaseRootTable) UnmarshalProtoJSON(s *json.UnmarshalState)
- func (m *DatabaseRootTable) UnmarshalVT(dAtA []byte) error
- func (r *DatabaseRootTable) Validate() error
- type DriverProvider
- func (p *DriverProvider) NewContext(ctx context.Context, conn *gdriver.Conn, opts ...sql.ContextOption) (*sql.Context, error)
- func (p *DriverProvider) NewSession(ctx context.Context, id uint32, conn *gdriver.Connector) (sql.Session, error)
- func (p *DriverProvider) Resolve(name string, options *gdriver.Options) (string, sql.DatabaseProvider, error)
- type Mysql
- type Root
- func (n *Root) ApplySubBlock(id uint32, next block.SubBlock) error
- func (m *Root) CloneMessageVT() protobuf_go_lite.CloneMessage
- func (m *Root) CloneVT() *Root
- func (this *Root) EqualMessageVT(thatMsg any) bool
- func (this *Root) EqualVT(that *Root) bool
- func (x *Root) GetDatabases() []*RootDb
- func (n *Root) GetRootDbSet(bcs *block.Cursor) *namedsbset.NamedSubBlockSet
- func (n *Root) GetSubBlockCtor(id uint32) block.SubBlockCtor
- func (n *Root) GetSubBlocks() map[uint32]block.SubBlock
- func (n *Root) InsertDatabase(name string, ref *block.BlockRef, bcs *block.Cursor) (*RootDb, *block.Cursor)
- func (n *Root) MarshalBlock() ([]byte, error)
- func (x *Root) MarshalJSON() ([]byte, error)
- func (x *Root) MarshalProtoJSON(s *json.MarshalState)
- func (x *Root) MarshalProtoText() string
- func (m *Root) MarshalToSizedBufferVT(dAtA []byte) (int, error)
- func (m *Root) MarshalToVT(dAtA []byte) (int, error)
- func (m *Root) MarshalVT() (dAtA []byte, err error)
- func (*Root) ProtoMessage()
- func (x *Root) Reset()
- func (m *Root) SizeVT() (n int)
- func (x *Root) String() string
- func (n *Root) UnmarshalBlock(data []byte) error
- func (x *Root) UnmarshalJSON(b []byte) error
- func (x *Root) UnmarshalProtoJSON(s *json.UnmarshalState)
- func (m *Root) UnmarshalVT(dAtA []byte) error
- func (n *Root) Validate() error
- type RootDb
- func (r *RootDb) ApplyBlockRef(id uint32, ptr *block.BlockRef) error
- func (m *RootDb) CloneMessageVT() protobuf_go_lite.CloneMessage
- func (m *RootDb) CloneVT() *RootDb
- func (this *RootDb) EqualMessageVT(thatMsg any) bool
- func (this *RootDb) EqualVT(that *RootDb) bool
- func (r *RootDb) GetBlockRefCtor(id uint32) block.Ctor
- func (r *RootDb) GetBlockRefs() (map[uint32]*block.BlockRef, error)
- func (x *RootDb) GetName() string
- func (x *RootDb) GetRef() *block.BlockRef
- func (r *RootDb) IsNil() bool
- func (x *RootDb) MarshalJSON() ([]byte, error)
- func (x *RootDb) MarshalProtoJSON(s *json.MarshalState)
- func (x *RootDb) MarshalProtoText() string
- func (m *RootDb) MarshalToSizedBufferVT(dAtA []byte) (int, error)
- func (m *RootDb) MarshalToVT(dAtA []byte) (int, error)
- func (m *RootDb) MarshalVT() (dAtA []byte, err error)
- func (*RootDb) ProtoMessage()
- func (x *RootDb) Reset()
- func (m *RootDb) SizeVT() (n int)
- func (x *RootDb) String() string
- func (x *RootDb) UnmarshalJSON(b []byte) error
- func (x *RootDb) UnmarshalProtoJSON(s *json.UnmarshalState)
- func (m *RootDb) UnmarshalVT(dAtA []byte) error
- func (r *RootDb) Validate() error
- type SqlConn
- type SqlTx
- type Table
- func (t *Table) AutoIncrementSetter(sqlCtx *sql.Context) sql.AutoIncrementSetter
- func (t *Table) Collation() sql.CollationID
- func (t *Table) GetNextAutoIncrementValue(sqlCtx *sql.Context, insertVal any) (uint64, error)
- func (t *Table) Inserter(sqlCtx *sql.Context) sql.RowInserter
- func (t *Table) Name() string
- func (t *Table) NewTableEditor(sqlCtx *sql.Context) *TableEditor
- func (t *Table) PartitionAtIndex(ix int) (*TablePartition, error)
- func (t *Table) PartitionCount(*sql.Context) (int64, error)
- func (t *Table) PartitionRows(ctx *sql.Context, part sql.Partition) (sql.RowIter, error)
- func (t *Table) Partitions(ctx *sql.Context) (sql.PartitionIter, error)
- func (t *Table) PeekNextAutoIncrementValue(*sql.Context) (uint64, error)
- func (t *Table) PrimaryKeySchema(*sql.Context) sql.PrimaryKeySchema
- func (t *Table) Schema(*sql.Context) sql.Schema
- func (t *Table) SelectPartition(nonce uint64) (*TablePartition, int, error)
- func (t *Table) SetIndexLookup(lookup *sql.IndexLookup)
- func (t *Table) String() string
- type TableColumn
- func (t *TableColumn) ApplySubBlock(id uint32, next block.SubBlock) error
- func (m *TableColumn) CloneMessageVT() protobuf_go_lite.CloneMessage
- func (m *TableColumn) CloneVT() *TableColumn
- func (this *TableColumn) EqualMessageVT(thatMsg any) bool
- func (this *TableColumn) EqualVT(that *TableColumn) bool
- func (t *TableColumn) FetchSqlColumn(ctx context.Context, bcs *block.Cursor) (any, error)
- func (x *TableColumn) GetBoolValue() bool
- func (x *TableColumn) GetBytesBlob() *blob.Blob
- func (x *TableColumn) GetFloatValue() float64
- func (x *TableColumn) GetIntValue() int64
- func (x *TableColumn) GetJsonBlob() *blob.Blob
- func (x *TableColumn) GetStringBlob() *blob.Blob
- func (t *TableColumn) GetSubBlockCtor(id uint32) block.SubBlockCtor
- func (t *TableColumn) GetSubBlocks() map[uint32]block.SubBlock
- func (x *TableColumn) GetTimespanMicros() int64
- func (x *TableColumn) GetTimestampValue() *TableTimestamp
- func (x *TableColumn) GetUintValue() uint64
- func (m *TableColumn) GetValue() isTableColumn_Value
- func (t *TableColumn) IsEmpty() bool
- func (t *TableColumn) IsNil() bool
- func (t *TableColumn) MarshalBlock() ([]byte, error)
- func (x *TableColumn) MarshalJSON() ([]byte, error)
- func (x *TableColumn) MarshalProtoJSON(s *json.MarshalState)
- func (x *TableColumn) MarshalProtoText() string
- func (m *TableColumn) MarshalToSizedBufferVT(dAtA []byte) (int, error)
- func (m *TableColumn) MarshalToVT(dAtA []byte) (int, error)
- func (m *TableColumn) MarshalVT() (dAtA []byte, err error)
- func (*TableColumn) ProtoMessage()
- func (x *TableColumn) Reset()
- func (m *TableColumn) SizeVT() (n int)
- func (x *TableColumn) String() string
- func (t *TableColumn) UnmarshalBlock(data []byte) error
- func (x *TableColumn) UnmarshalJSON(b []byte) error
- func (x *TableColumn) UnmarshalProtoJSON(s *json.UnmarshalState)
- func (m *TableColumn) UnmarshalVT(dAtA []byte) error
- func (t *TableColumn) Validate() error
- type TableColumn_BoolValue
- func (m *TableColumn_BoolValue) CloneOneofVT() isTableColumn_Value
- func (m *TableColumn_BoolValue) CloneVT() *TableColumn_BoolValue
- func (this *TableColumn_BoolValue) EqualVT(thatIface isTableColumn_Value) bool
- func (m *TableColumn_BoolValue) MarshalToSizedBufferVT(dAtA []byte) (int, error)
- func (m *TableColumn_BoolValue) MarshalToVT(dAtA []byte) (int, error)
- func (m *TableColumn_BoolValue) SizeVT() (n int)
- type TableColumn_BytesBlob
- func (m *TableColumn_BytesBlob) CloneOneofVT() isTableColumn_Value
- func (m *TableColumn_BytesBlob) CloneVT() *TableColumn_BytesBlob
- func (this *TableColumn_BytesBlob) EqualVT(thatIface isTableColumn_Value) bool
- func (m *TableColumn_BytesBlob) MarshalToSizedBufferVT(dAtA []byte) (int, error)
- func (m *TableColumn_BytesBlob) MarshalToVT(dAtA []byte) (int, error)
- func (m *TableColumn_BytesBlob) SizeVT() (n int)
- type TableColumn_FloatValue
- func (m *TableColumn_FloatValue) CloneOneofVT() isTableColumn_Value
- func (m *TableColumn_FloatValue) CloneVT() *TableColumn_FloatValue
- func (this *TableColumn_FloatValue) EqualVT(thatIface isTableColumn_Value) bool
- func (m *TableColumn_FloatValue) MarshalToSizedBufferVT(dAtA []byte) (int, error)
- func (m *TableColumn_FloatValue) MarshalToVT(dAtA []byte) (int, error)
- func (m *TableColumn_FloatValue) SizeVT() (n int)
- type TableColumn_IntValue
- func (m *TableColumn_IntValue) CloneOneofVT() isTableColumn_Value
- func (m *TableColumn_IntValue) CloneVT() *TableColumn_IntValue
- func (this *TableColumn_IntValue) EqualVT(thatIface isTableColumn_Value) bool
- func (m *TableColumn_IntValue) MarshalToSizedBufferVT(dAtA []byte) (int, error)
- func (m *TableColumn_IntValue) MarshalToVT(dAtA []byte) (int, error)
- func (m *TableColumn_IntValue) SizeVT() (n int)
- type TableColumn_JsonBlob
- func (m *TableColumn_JsonBlob) CloneOneofVT() isTableColumn_Value
- func (m *TableColumn_JsonBlob) CloneVT() *TableColumn_JsonBlob
- func (this *TableColumn_JsonBlob) EqualVT(thatIface isTableColumn_Value) bool
- func (m *TableColumn_JsonBlob) MarshalToSizedBufferVT(dAtA []byte) (int, error)
- func (m *TableColumn_JsonBlob) MarshalToVT(dAtA []byte) (int, error)
- func (m *TableColumn_JsonBlob) SizeVT() (n int)
- type TableColumn_StringBlob
- func (m *TableColumn_StringBlob) CloneOneofVT() isTableColumn_Value
- func (m *TableColumn_StringBlob) CloneVT() *TableColumn_StringBlob
- func (this *TableColumn_StringBlob) EqualVT(thatIface isTableColumn_Value) bool
- func (m *TableColumn_StringBlob) MarshalToSizedBufferVT(dAtA []byte) (int, error)
- func (m *TableColumn_StringBlob) MarshalToVT(dAtA []byte) (int, error)
- func (m *TableColumn_StringBlob) SizeVT() (n int)
- type TableColumn_TimespanMicros
- func (m *TableColumn_TimespanMicros) CloneOneofVT() isTableColumn_Value
- func (m *TableColumn_TimespanMicros) CloneVT() *TableColumn_TimespanMicros
- func (this *TableColumn_TimespanMicros) EqualVT(thatIface isTableColumn_Value) bool
- func (m *TableColumn_TimespanMicros) MarshalToSizedBufferVT(dAtA []byte) (int, error)
- func (m *TableColumn_TimespanMicros) MarshalToVT(dAtA []byte) (int, error)
- func (m *TableColumn_TimespanMicros) SizeVT() (n int)
- type TableColumn_TimestampValue
- func (m *TableColumn_TimestampValue) CloneOneofVT() isTableColumn_Value
- func (m *TableColumn_TimestampValue) CloneVT() *TableColumn_TimestampValue
- func (this *TableColumn_TimestampValue) EqualVT(thatIface isTableColumn_Value) bool
- func (m *TableColumn_TimestampValue) MarshalToSizedBufferVT(dAtA []byte) (int, error)
- func (m *TableColumn_TimestampValue) MarshalToVT(dAtA []byte) (int, error)
- func (m *TableColumn_TimestampValue) SizeVT() (n int)
- type TableColumn_UintValue
- func (m *TableColumn_UintValue) CloneOneofVT() isTableColumn_Value
- func (m *TableColumn_UintValue) CloneVT() *TableColumn_UintValue
- func (this *TableColumn_UintValue) EqualVT(thatIface isTableColumn_Value) bool
- func (m *TableColumn_UintValue) MarshalToSizedBufferVT(dAtA []byte) (int, error)
- func (m *TableColumn_UintValue) MarshalToVT(dAtA []byte) (int, error)
- func (m *TableColumn_UintValue) SizeVT() (n int)
- type TableEditor
- func (i *TableEditor) AcquireAutoIncrementLock(ctx *sql.Context) (func(), error)
- func (i *TableEditor) Close(sqlCtx *sql.Context) error
- func (i *TableEditor) DiscardChanges(ctx *sql.Context, errorEncountered error) error
- func (i *TableEditor) Insert(sqlCtx *sql.Context, row sql.Row) error
- func (i *TableEditor) SetAutoIncrementValue(sqlCtx *sql.Context, val uint64) error
- func (i *TableEditor) SetBuildBlobOpts(opts *blob.BuildBlobOpts)
- func (i *TableEditor) StatementBegin(ctx *sql.Context)
- func (i *TableEditor) StatementComplete(ctx *sql.Context) error
- type TablePartition
- type TablePartitionIter
- type TablePartitionRoot
- func (r *TablePartitionRoot) ApplySubBlock(id uint32, next block.SubBlock) error
- func (m *TablePartitionRoot) CloneMessageVT() protobuf_go_lite.CloneMessage
- func (m *TablePartitionRoot) CloneVT() *TablePartitionRoot
- func (this *TablePartitionRoot) EqualMessageVT(thatMsg any) bool
- func (this *TablePartitionRoot) EqualVT(that *TablePartitionRoot) bool
- func (x *TablePartitionRoot) GetRowKeyValue() *block1.KeyValueStore
- func (r *TablePartitionRoot) GetSubBlockCtor(id uint32) block.SubBlockCtor
- func (r *TablePartitionRoot) GetSubBlocks() map[uint32]block.SubBlock
- func (r *TablePartitionRoot) IsNil() bool
- func (x *TablePartitionRoot) MarshalJSON() ([]byte, error)
- func (x *TablePartitionRoot) MarshalProtoJSON(s *json.MarshalState)
- func (x *TablePartitionRoot) MarshalProtoText() string
- func (m *TablePartitionRoot) MarshalToSizedBufferVT(dAtA []byte) (int, error)
- func (m *TablePartitionRoot) MarshalToVT(dAtA []byte) (int, error)
- func (m *TablePartitionRoot) MarshalVT() (dAtA []byte, err error)
- func (*TablePartitionRoot) ProtoMessage()
- func (x *TablePartitionRoot) Reset()
- func (m *TablePartitionRoot) SizeVT() (n int)
- func (x *TablePartitionRoot) String() string
- func (x *TablePartitionRoot) UnmarshalJSON(b []byte) error
- func (x *TablePartitionRoot) UnmarshalProtoJSON(s *json.UnmarshalState)
- func (m *TablePartitionRoot) UnmarshalVT(dAtA []byte) error
- func (r *TablePartitionRoot) Validate() error
- type TablePartitionRowIter
- type TableRoot
- func (r *TableRoot) ApplySubBlock(id uint32, next block.SubBlock) error
- func (m *TableRoot) CloneMessageVT() protobuf_go_lite.CloneMessage
- func (m *TableRoot) CloneVT() *TableRoot
- func (this *TableRoot) EqualMessageVT(thatMsg any) bool
- func (this *TableRoot) EqualVT(that *TableRoot) bool
- func (r *TableRoot) FetchAutoIncrVal(ctx context.Context, bcs *block.Cursor, expectedType sql.Type) (any, sql.ConvertInRange, error)
- func (x *TableRoot) GetAutoIncrVal() *TableColumn
- func (x *TableRoot) GetCollationId() uint32
- func (x *TableRoot) GetComment() string
- func (x *TableRoot) GetPrimaryKeyOrdinals() []int32
- func (x *TableRoot) GetRowNonce() uint64
- func (r *TableRoot) GetSubBlockCtor(id uint32) block.SubBlockCtor
- func (r *TableRoot) GetSubBlocks() map[uint32]block.SubBlock
- func (x *TableRoot) GetTablePartitions() []*TablePartitionRoot
- func (x *TableRoot) GetTableSchema() *TableSchema
- func (r *TableRoot) MarshalBlock() ([]byte, error)
- func (x *TableRoot) MarshalJSON() ([]byte, error)
- func (x *TableRoot) MarshalProtoJSON(s *json.MarshalState)
- func (x *TableRoot) MarshalProtoText() string
- func (m *TableRoot) MarshalToSizedBufferVT(dAtA []byte) (int, error)
- func (m *TableRoot) MarshalToVT(dAtA []byte) (int, error)
- func (m *TableRoot) MarshalVT() (dAtA []byte, err error)
- func (*TableRoot) ProtoMessage()
- func (x *TableRoot) Reset()
- func (m *TableRoot) SizeVT() (n int)
- func (r *TableRoot) StoreAutoIncrVal(ctx context.Context, bcs *block.Cursor, buildBlobOpts *blob.BuildBlobOpts, ...) error
- func (x *TableRoot) String() string
- func (r *TableRoot) UnmarshalBlock(data []byte) error
- func (x *TableRoot) UnmarshalJSON(b []byte) error
- func (x *TableRoot) UnmarshalProtoJSON(s *json.UnmarshalState)
- func (m *TableRoot) UnmarshalVT(dAtA []byte) error
- func (r *TableRoot) Validate() error
- type TableRow
- func (r *TableRow) ApplySubBlock(id uint32, next block.SubBlock) error
- func (m *TableRow) CloneMessageVT() protobuf_go_lite.CloneMessage
- func (m *TableRow) CloneVT() *TableRow
- func (this *TableRow) EqualMessageVT(thatMsg any) bool
- func (this *TableRow) EqualVT(that *TableRow) bool
- func (r *TableRow) FetchSqlRow(ctx context.Context, bcs *block.Cursor) (sql.Row, error)
- func (x *TableRow) GetColumns() []*TableColumn
- func (r *TableRow) GetSubBlockCtor(id uint32) block.SubBlockCtor
- func (r *TableRow) GetSubBlocks() map[uint32]block.SubBlock
- func (r *TableRow) MarshalBlock() ([]byte, error)
- func (x *TableRow) MarshalJSON() ([]byte, error)
- func (x *TableRow) MarshalProtoJSON(s *json.MarshalState)
- func (x *TableRow) MarshalProtoText() string
- func (m *TableRow) MarshalToSizedBufferVT(dAtA []byte) (int, error)
- func (m *TableRow) MarshalToVT(dAtA []byte) (int, error)
- func (m *TableRow) MarshalVT() (dAtA []byte, err error)
- func (*TableRow) ProtoMessage()
- func (x *TableRow) Reset()
- func (m *TableRow) SizeVT() (n int)
- func (x *TableRow) String() string
- func (r *TableRow) UnmarshalBlock(data []byte) error
- func (x *TableRow) UnmarshalJSON(b []byte) error
- func (x *TableRow) UnmarshalProtoJSON(s *json.UnmarshalState)
- func (m *TableRow) UnmarshalVT(dAtA []byte) error
- type TableSchema
- func (m *TableSchema) CloneMessageVT() protobuf_go_lite.CloneMessage
- func (m *TableSchema) CloneVT() *TableSchema
- func (this *TableSchema) EqualMessageVT(thatMsg any) bool
- func (this *TableSchema) EqualVT(that *TableSchema) bool
- func (x *TableSchema) GetColumns() []*TableSchemaColumn
- func (x *TableSchema) MarshalJSON() ([]byte, error)
- func (x *TableSchema) MarshalProtoJSON(s *json.MarshalState)
- func (x *TableSchema) MarshalProtoText() string
- func (m *TableSchema) MarshalToSizedBufferVT(dAtA []byte) (int, error)
- func (m *TableSchema) MarshalToVT(dAtA []byte) (int, error)
- func (m *TableSchema) MarshalVT() (dAtA []byte, err error)
- func (*TableSchema) ProtoMessage()
- func (x *TableSchema) Reset()
- func (m *TableSchema) SizeVT() (n int)
- func (x *TableSchema) String() string
- func (s *TableSchema) ToSqlSchema(ctx *sql.Context) (sql.Schema, error)
- func (x *TableSchema) UnmarshalJSON(b []byte) error
- func (x *TableSchema) UnmarshalProtoJSON(s *json.UnmarshalState)
- func (m *TableSchema) UnmarshalVT(dAtA []byte) error
- func (s *TableSchema) Validate() error
- type TableSchemaColumn
- func (m *TableSchemaColumn) CloneMessageVT() protobuf_go_lite.CloneMessage
- func (m *TableSchemaColumn) CloneVT() *TableSchemaColumn
- func (this *TableSchemaColumn) EqualMessageVT(thatMsg any) bool
- func (this *TableSchemaColumn) EqualVT(that *TableSchemaColumn) bool
- func (x *TableSchemaColumn) GetAutoIncrement() bool
- func (x *TableSchemaColumn) GetColumnType() string
- func (x *TableSchemaColumn) GetComment() string
- func (x *TableSchemaColumn) GetDefaultValueExpr() string
- func (x *TableSchemaColumn) GetExtra() string
- func (x *TableSchemaColumn) GetName() string
- func (x *TableSchemaColumn) GetNullable() bool
- func (x *TableSchemaColumn) GetPrimaryKey() bool
- func (x *TableSchemaColumn) GetSource() string
- func (x *TableSchemaColumn) MarshalJSON() ([]byte, error)
- func (x *TableSchemaColumn) MarshalProtoJSON(s *json.MarshalState)
- func (x *TableSchemaColumn) MarshalProtoText() string
- func (m *TableSchemaColumn) MarshalToSizedBufferVT(dAtA []byte) (int, error)
- func (m *TableSchemaColumn) MarshalToVT(dAtA []byte) (int, error)
- func (m *TableSchemaColumn) MarshalVT() (dAtA []byte, err error)
- func (t *TableSchemaColumn) ParseColumnType() (sql.Type, error)
- func (t *TableSchemaColumn) ParseDefaultValueExpr(ctx *sql.Context) (*sql.ColumnDefaultValue, error)
- func (*TableSchemaColumn) ProtoMessage()
- func (x *TableSchemaColumn) Reset()
- func (m *TableSchemaColumn) SizeVT() (n int)
- func (x *TableSchemaColumn) String() string
- func (t *TableSchemaColumn) ToSqlColumn(ctx *sql.Context) (*sql.Column, error)
- func (x *TableSchemaColumn) UnmarshalJSON(b []byte) error
- func (x *TableSchemaColumn) UnmarshalProtoJSON(s *json.UnmarshalState)
- func (m *TableSchemaColumn) UnmarshalVT(dAtA []byte) error
- func (t *TableSchemaColumn) Validate() error
- type TableTimestamp
- func (m *TableTimestamp) CloneMessageVT() protobuf_go_lite.CloneMessage
- func (m *TableTimestamp) CloneVT() *TableTimestamp
- func (this *TableTimestamp) EqualMessageVT(thatMsg any) bool
- func (this *TableTimestamp) EqualVT(that *TableTimestamp) bool
- func (x *TableTimestamp) GetNanos() int32
- func (x *TableTimestamp) GetUnixSeconds() int64
- func (x *TableTimestamp) MarshalJSON() ([]byte, error)
- func (x *TableTimestamp) MarshalProtoJSON(s *json.MarshalState)
- func (x *TableTimestamp) MarshalProtoText() string
- func (m *TableTimestamp) MarshalToSizedBufferVT(dAtA []byte) (int, error)
- func (m *TableTimestamp) MarshalToVT(dAtA []byte) (int, error)
- func (m *TableTimestamp) MarshalVT() (dAtA []byte, err error)
- func (*TableTimestamp) ProtoMessage()
- func (x *TableTimestamp) Reset()
- func (m *TableTimestamp) SizeVT() (n int)
- func (x *TableTimestamp) String() string
- func (x *TableTimestamp) UnmarshalJSON(b []byte) error
- func (x *TableTimestamp) UnmarshalProtoJSON(s *json.UnmarshalState)
- func (m *TableTimestamp) UnmarshalVT(dAtA []byte) error
- type Tx
- func (t *Tx) BuildDatabaseProvider(ctx context.Context) (sql.DatabaseProvider, error)
- func (t *Tx) Commit(ctx context.Context) (cerr error)
- func (t *Tx) DatabaseCount() int
- func (t *Tx) Discard()
- func (t *Tx) GetBlockTransaction() *block.Transaction
- func (t *Tx) OpenDatabase(ctx context.Context, name string, create bool) (*Database, error)
Constants ¶
const TableColumnMaxSize = 2e4 // 20kb
TableColumnMaxSize is the maximum size of the data field, if larger than this size, data will be stored in a block referenced by "data_ref".
Variables ¶
var ( // ErrEmptyDatabaseName is returned if an empty string is found where a db name is expected. ErrEmptyDatabaseName = errors.New("empty database name is invalid") // ErrDatabaseExists is returned if the database already exists. ErrDatabaseExists = errors.New("database already exists") // ErrDatabaseNotFound is returned if the database does not exist. ErrDatabaseNotFound = sql.ErrDatabaseNotFound // ErrEmptyTableName is returned if an empty string is found where a table name is expected. ErrEmptyTableName = errors.New("empty table name is invalid") // ErrEmptyTable is returned if an empty table is found where at least one column is expected. ErrEmptyTable = errors.New("empty table with no columns is invalid") // ErrEmptyTableColumn is returned if an empty table column is found where one is expected. ErrEmptyTableColumn = errors.New("empty table column schema is invalid") // ErrEmptyTableColumnName is returned if an empty table column name is found where one is expected. ErrEmptyTableColumnName = errors.New("empty table column name is invalid") // ErrUnexpectedType is returned if a type assertion failed. ErrUnexpectedType = errors.New("sql db unexpected object type") )
var TableRowKeyEndian = binary.BigEndian
TableRowKeyEndian is the endian-ness to use for table keys. Note: this is selected to make keys sort in the correct order.
Functions ¶
func BuildTable ¶
func BuildTable( ctx context.Context, bcs *block.Cursor, name string, schema sql.PrimaryKeySchema, numPartitions int, collationID sql.CollationID, comment string, ) (*TableRoot, *Table, error)
BuildTable constructs a new table, storing it in the block cursor (if set).
if bcs is nil, the returned *Table will also be nil.
func GetDbContext ¶
GetDbContext gets the sql context or returns background.
func MarshalTableRowKey ¶
MarshalTableRowKey marshals the key for a table row.
func NewDatabaseRootBlock ¶
NewDatabaseRootBlock constructs a new db root block.
func NewMysqlGorm ¶
func NewMysqlGorm(ctx context.Context, le *logrus.Entry, tx *Tx, conf *gorm.Config, dsn string) (*gorm.DB, *sql.DB, error)
NewMysqlGorm constructs a go-orm instance from a Mysql transaction. dsn allows specifying the database name and/or other parameters
func NewSqlConnector ¶
NewSqlConnector constructs a new sql conn from a transaction. NOTE: dsn is used to specify arguments and is NOT the db name. ctx is used for the driver Resolve() function
func NewSqlDb ¶
NewSqlDb opens the sql database driver. NOTE: dsn is used to specify arguments and is NOT the db name. ctx is used for the provider Resolve function
func NewSqlDriver ¶
NewSqlDriver constructs a sql driver from a transaction.
ctx is used for the driver Resolve() function
func NewTableRootBlock ¶
NewTableRootBlock constructs a new db root block.
func NewTableRowBlock ¶
NewTableRowBlock constructs a new db root block.
func ParseColumnType ¶
func ParseColumnType(typeStr string) (*sqlparser.ColumnType, error)
ParseColumnType parses a column type string to a sqlparser.ColumnType.
func UnmarshalTableRowKey ¶
UnmarshalTableRowKey unmarshals the nonce for a table row.
Types ¶
type CommitFn ¶
CommitFn is a function to call with the updated root before confirming it. Should be used to write the updated state back to storage. Note: engine rmtx is locked while cb is called, do not block or call engine funcs! If an error is returned the change will be rolled back. Do not change the nrootBcs during this call.
type Database ¶
type Database struct {
// contains filtered or unexported fields
}
Database is the block-graph backed SQL db cursor. NOTE: calls are not concurrency-safe.
func NewDatabase ¶
func NewDatabase(ctx context.Context, name string, readOnly bool, bcs *block.Cursor) (*Database, error)
NewDatabase constructs a new database handle.
func (*Database) CreateTable ¶
func (d *Database) CreateTable(ctx *sql.Context, name string, schema sql.PrimaryKeySchema, collation sql.CollationID, comment string) error
Creates the table with the given name and schema. If a table with that name already exists, must return sql.ErrTableAlreadyExists.
func (*Database) GetTableInsensitive ¶
GetTableInsensitive retrieves a table by its case insensitive name. Implementations should look for exact (case-sensitive matches) first. If no exact matches are found then any table matching the name case insensitively should be returned. If there is more than one table that matches a case insensitive comparison the resolution strategy is not defined.
func (*Database) GetTableNames ¶
GetTableNames returns the table names of every table in the database
func (*Database) IsReadOnly ¶
IsReadOnly returns whether this database is read-only.
func (*Database) RenameTable ¶
Renames a table from oldName to newName as given. If a table with newName already exists, must return sql.ErrTableAlreadyExists.
func (*Database) TableCount ¶
TableCount returns the count of tables in the database.
type DatabaseRoot ¶
type DatabaseRoot struct {
// Tables contains the table list sorted by name.
Tables []*DatabaseRootTable `protobuf:"bytes,1,rep,name=tables,proto3" json:"tables,omitempty"`
// contains filtered or unexported fields
}
DatabaseRoot is the root object of the database.
func LoadDatabaseRoot ¶
LoadDatabaseRoot follows the database root cursor. may return nil
func (*DatabaseRoot) ApplySubBlock ¶
func (r *DatabaseRoot) ApplySubBlock(id uint32, next block.SubBlock) error
ApplySubBlock applies a sub-block change with a field id.
func (*DatabaseRoot) CloneMessageVT ¶
func (m *DatabaseRoot) CloneMessageVT() protobuf_go_lite.CloneMessage
func (*DatabaseRoot) CloneVT ¶
func (m *DatabaseRoot) CloneVT() *DatabaseRoot
func (*DatabaseRoot) EqualMessageVT ¶
func (this *DatabaseRoot) EqualMessageVT(thatMsg any) bool
func (*DatabaseRoot) EqualVT ¶
func (this *DatabaseRoot) EqualVT(that *DatabaseRoot) bool
func (*DatabaseRoot) GetRootTableSet ¶
func (r *DatabaseRoot) GetRootTableSet(bcs *block.Cursor) *namedsbset.NamedSubBlockSet
GetRootTableSet returns the root table set sub-block.
bcs is optional
func (*DatabaseRoot) GetSubBlockCtor ¶
func (r *DatabaseRoot) GetSubBlockCtor(id uint32) block.SubBlockCtor
GetSubBlockCtor returns a function which creates or returns the existing sub-block at reference id. Can return nil to indicate invalid reference id.
func (*DatabaseRoot) GetSubBlocks ¶
func (r *DatabaseRoot) GetSubBlocks() map[uint32]block.SubBlock
GetSubBlocks returns all constructed sub-blocks by ID. May return nil, and values may also be nil.
func (*DatabaseRoot) GetTables ¶
func (x *DatabaseRoot) GetTables() []*DatabaseRootTable
func (*DatabaseRoot) InsertTable ¶
func (r *DatabaseRoot) InsertTable(name string, ref *block.BlockRef, bcs *block.Cursor) (*block.Cursor, bool)
InsertTable inserts a new table. Caller should check if it doesn't exist before calling.
Returns new cursor, added. bcs can be nil, or should be located at root.
func (*DatabaseRoot) IsNil ¶
func (r *DatabaseRoot) IsNil() bool
IsNil returns if the object is nil.
func (*DatabaseRoot) MarshalBlock ¶
func (r *DatabaseRoot) MarshalBlock() ([]byte, error)
MarshalBlock marshals the block to binary. This is the initial step of marshaling, before transformations.
func (*DatabaseRoot) MarshalJSON ¶
func (x *DatabaseRoot) MarshalJSON() ([]byte, error)
MarshalJSON marshals the DatabaseRoot to JSON.
func (*DatabaseRoot) MarshalProtoJSON ¶
func (x *DatabaseRoot) MarshalProtoJSON(s *json.MarshalState)
MarshalProtoJSON marshals the DatabaseRoot message to JSON.
func (*DatabaseRoot) MarshalProtoText ¶
func (x *DatabaseRoot) MarshalProtoText() string
func (*DatabaseRoot) MarshalToSizedBufferVT ¶
func (m *DatabaseRoot) MarshalToSizedBufferVT(dAtA []byte) (int, error)
func (*DatabaseRoot) MarshalToVT ¶
func (m *DatabaseRoot) MarshalToVT(dAtA []byte) (int, error)
func (*DatabaseRoot) MarshalVT ¶
func (m *DatabaseRoot) MarshalVT() (dAtA []byte, err error)
func (*DatabaseRoot) ProtoMessage ¶
func (*DatabaseRoot) ProtoMessage()
func (*DatabaseRoot) Reset ¶
func (x *DatabaseRoot) Reset()
func (*DatabaseRoot) SizeVT ¶
func (m *DatabaseRoot) SizeVT() (n int)
func (*DatabaseRoot) String ¶
func (x *DatabaseRoot) String() string
func (*DatabaseRoot) UnmarshalBlock ¶
func (r *DatabaseRoot) UnmarshalBlock(data []byte) error
UnmarshalBlock unmarshals the block to the object. This is the final step of decoding, after transformations.
func (*DatabaseRoot) UnmarshalJSON ¶
func (x *DatabaseRoot) UnmarshalJSON(b []byte) error
UnmarshalJSON unmarshals the DatabaseRoot from JSON.
func (*DatabaseRoot) UnmarshalProtoJSON ¶
func (x *DatabaseRoot) UnmarshalProtoJSON(s *json.UnmarshalState)
UnmarshalProtoJSON unmarshals the DatabaseRoot message from JSON.
func (*DatabaseRoot) UnmarshalVT ¶
func (m *DatabaseRoot) UnmarshalVT(dAtA []byte) error
func (*DatabaseRoot) Validate ¶
func (r *DatabaseRoot) Validate() error
Validate validates the database root block.
type DatabaseRootTable ¶
type DatabaseRootTable struct {
// Name is the unique name of the table.
Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"`
// Ref is the block reference to the table root.
// Type: TableRoot.
Ref *block.BlockRef `protobuf:"bytes,2,opt,name=ref,proto3" json:"ref,omitempty"`
// contains filtered or unexported fields
}
DatabaseRootTable contains the reference to the TableRoot.
func (*DatabaseRootTable) ApplyBlockRef ¶
func (r *DatabaseRootTable) ApplyBlockRef(id uint32, ptr *block.BlockRef) error
ApplyBlockRef applies a ref change with a field id. The reference may be nil if the child block is nil.
func (*DatabaseRootTable) CloneMessageVT ¶
func (m *DatabaseRootTable) CloneMessageVT() protobuf_go_lite.CloneMessage
func (*DatabaseRootTable) CloneVT ¶
func (m *DatabaseRootTable) CloneVT() *DatabaseRootTable
func (*DatabaseRootTable) EqualMessageVT ¶
func (this *DatabaseRootTable) EqualMessageVT(thatMsg any) bool
func (*DatabaseRootTable) EqualVT ¶
func (this *DatabaseRootTable) EqualVT(that *DatabaseRootTable) bool
func (*DatabaseRootTable) GetBlockRefCtor ¶
func (r *DatabaseRootTable) GetBlockRefCtor(id uint32) block.Ctor
GetBlockRefCtor returns the constructor for the block at the ref id. Return nil to indicate invalid ref ID or unknown.
func (*DatabaseRootTable) GetBlockRefs ¶
func (r *DatabaseRootTable) GetBlockRefs() (map[uint32]*block.BlockRef, error)
GetBlockRefs returns all block references by ID. May return nil, and values may also be nil. Note: this does not include pending references (in a cursor)
func (*DatabaseRootTable) GetName ¶
func (x *DatabaseRootTable) GetName() string
func (*DatabaseRootTable) GetRef ¶
func (x *DatabaseRootTable) GetRef() *block.BlockRef
func (*DatabaseRootTable) IsNil ¶
func (r *DatabaseRootTable) IsNil() bool
IsNil returns if the object is nil.
func (*DatabaseRootTable) MarshalJSON ¶
func (x *DatabaseRootTable) MarshalJSON() ([]byte, error)
MarshalJSON marshals the DatabaseRootTable to JSON.
func (*DatabaseRootTable) MarshalProtoJSON ¶
func (x *DatabaseRootTable) MarshalProtoJSON(s *json.MarshalState)
MarshalProtoJSON marshals the DatabaseRootTable message to JSON.
func (*DatabaseRootTable) MarshalProtoText ¶
func (x *DatabaseRootTable) MarshalProtoText() string
func (*DatabaseRootTable) MarshalToSizedBufferVT ¶
func (m *DatabaseRootTable) MarshalToSizedBufferVT(dAtA []byte) (int, error)
func (*DatabaseRootTable) MarshalToVT ¶
func (m *DatabaseRootTable) MarshalToVT(dAtA []byte) (int, error)
func (*DatabaseRootTable) MarshalVT ¶
func (m *DatabaseRootTable) MarshalVT() (dAtA []byte, err error)
func (*DatabaseRootTable) ProtoMessage ¶
func (*DatabaseRootTable) ProtoMessage()
func (*DatabaseRootTable) Reset ¶
func (x *DatabaseRootTable) Reset()
func (*DatabaseRootTable) SizeVT ¶
func (m *DatabaseRootTable) SizeVT() (n int)
func (*DatabaseRootTable) String ¶
func (x *DatabaseRootTable) String() string
func (*DatabaseRootTable) UnmarshalJSON ¶
func (x *DatabaseRootTable) UnmarshalJSON(b []byte) error
UnmarshalJSON unmarshals the DatabaseRootTable from JSON.
func (*DatabaseRootTable) UnmarshalProtoJSON ¶
func (x *DatabaseRootTable) UnmarshalProtoJSON(s *json.UnmarshalState)
UnmarshalProtoJSON unmarshals the DatabaseRootTable message from JSON.
func (*DatabaseRootTable) UnmarshalVT ¶
func (m *DatabaseRootTable) UnmarshalVT(dAtA []byte) error
func (*DatabaseRootTable) Validate ¶
func (r *DatabaseRootTable) Validate() error
Validate performs cursory validation.
type DriverProvider ¶
type DriverProvider struct {
// contains filtered or unexported fields
}
DriverProvider implements the Provider interface for the sql driver.
func NewDriverProvider ¶
func NewDriverProvider(ctx context.Context, sqlTx *Tx) *DriverProvider
NewDriverProvider constructs a driver provider.
ctx is used for the Resolve() function
func (*DriverProvider) NewContext ¶
func (p *DriverProvider) NewContext( ctx context.Context, conn *gdriver.Conn, opts ...sql.ContextOption, ) (*sql.Context, error)
NewContext constructs the SQL context for the conn.
func (*DriverProvider) NewSession ¶
func (p *DriverProvider) NewSession( ctx context.Context, id uint32, conn *gdriver.Connector, ) (sql.Session, error)
NewSession builds a session for the connection.
func (*DriverProvider) Resolve ¶
func (p *DriverProvider) Resolve(name string, options *gdriver.Options) (string, sql.DatabaseProvider, error)
Resolve is called in OpenConnector to lookup the database with the given name.
type Mysql ¶
type Mysql struct {
// contains filtered or unexported fields
}
Mysql is the root of a mysql server data structure, containing named databases.
func NewMysql ¶
func NewMysql(rootCursor *bucket_lookup.Cursor, commitFn CommitFn) *Mysql
NewMysql creates a handle with an optional root object cursor pointing to the tree. The cursor ref can be empty to indicate a new tree.
func (*Mysql) GetRootNodeRef ¶
GetRootNodeRef returns the reference to the root node.
func (*Mysql) NewMysqlTransaction ¶
NewMysqlTransaction returns a transaction against the db.
func (*Mysql) NewSqlTransaction ¶
func (t *Mysql) NewSqlTransaction(ctx context.Context, write bool, dsn string) (sql.SqlTransaction, error)
NewTransaction returns a new SqlDB transaction.
type Root ¶
type Root struct {
// Databases contains the root set of databases, sorted by name.
Databases []*RootDb `protobuf:"bytes,1,rep,name=databases,proto3" json:"databases,omitempty"`
// contains filtered or unexported fields
}
Root is the root object of the mysql database.
func (*Root) ApplySubBlock ¶
ApplySubBlock applies a sub-block change with a field id.
func (*Root) CloneMessageVT ¶
func (m *Root) CloneMessageVT() protobuf_go_lite.CloneMessage
func (*Root) EqualMessageVT ¶
func (*Root) GetDatabases ¶
func (*Root) GetRootDbSet ¶
func (n *Root) GetRootDbSet(bcs *block.Cursor) *namedsbset.NamedSubBlockSet
GetRootDbSet returns the root db set sub-block.
bcs is optional
func (*Root) GetSubBlockCtor ¶
func (n *Root) GetSubBlockCtor(id uint32) block.SubBlockCtor
GetSubBlockCtor returns a function which creates or returns the existing sub-block at reference id. Can return nil to indicate invalid reference id.
func (*Root) GetSubBlocks ¶
GetSubBlocks returns all constructed sub-blocks by ID. May return nil, and values may also be nil.
func (*Root) InsertDatabase ¶
func (n *Root) InsertDatabase(name string, ref *block.BlockRef, bcs *block.Cursor) (*RootDb, *block.Cursor)
InsertDatabase inserts a new database. Caller should check if it doesn't exist before calling.
Returns new cursor located at *RootDb, added. bcs can be nil, or should be located at root of db.
func (*Root) MarshalBlock ¶
MarshalBlock marshals the block to binary. This is the initial step of marshaling, before transformations.
func (*Root) MarshalJSON ¶
MarshalJSON marshals the Root to JSON.
func (*Root) MarshalProtoJSON ¶
func (x *Root) MarshalProtoJSON(s *json.MarshalState)
MarshalProtoJSON marshals the Root message to JSON.
func (*Root) MarshalProtoText ¶
func (*Root) MarshalToSizedBufferVT ¶
func (*Root) ProtoMessage ¶
func (*Root) ProtoMessage()
func (*Root) UnmarshalBlock ¶
UnmarshalBlock unmarshals the block to the object. This is the final step of decoding, after transformations.
func (*Root) UnmarshalJSON ¶
UnmarshalJSON unmarshals the Root from JSON.
func (*Root) UnmarshalProtoJSON ¶
func (x *Root) UnmarshalProtoJSON(s *json.UnmarshalState)
UnmarshalProtoJSON unmarshals the Root message from JSON.
func (*Root) UnmarshalVT ¶
type RootDb ¶
type RootDb struct {
// Name is the unique name of the database.
Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"`
// Ref is the block reference to the database root.
// If empty, the database is empty.
// Type: DatabaseRoot.
Ref *block.BlockRef `protobuf:"bytes,2,opt,name=ref,proto3" json:"ref,omitempty"`
// contains filtered or unexported fields
}
RootDb contains the root definition of a database.
func (*RootDb) ApplyBlockRef ¶
ApplyBlockRef applies a ref change with a field id. The reference may be nil if the child block is nil.
func (*RootDb) CloneMessageVT ¶
func (m *RootDb) CloneMessageVT() protobuf_go_lite.CloneMessage
func (*RootDb) EqualMessageVT ¶
func (*RootDb) GetBlockRefCtor ¶
GetBlockRefCtor returns the constructor for the block at the ref id. Return nil to indicate invalid ref ID or unknown.
func (*RootDb) GetBlockRefs ¶
GetBlockRefs returns all block references by ID. May return nil, and values may also be nil. Note: this does not include pending references (in a cursor)
func (*RootDb) MarshalJSON ¶
MarshalJSON marshals the RootDb to JSON.
func (*RootDb) MarshalProtoJSON ¶
func (x *RootDb) MarshalProtoJSON(s *json.MarshalState)
MarshalProtoJSON marshals the RootDb message to JSON.
func (*RootDb) MarshalProtoText ¶
func (*RootDb) MarshalToSizedBufferVT ¶
func (*RootDb) ProtoMessage ¶
func (*RootDb) ProtoMessage()
func (*RootDb) UnmarshalJSON ¶
UnmarshalJSON unmarshals the RootDb from JSON.
func (*RootDb) UnmarshalProtoJSON ¶
func (x *RootDb) UnmarshalProtoJSON(s *json.UnmarshalState)
UnmarshalProtoJSON unmarshals the RootDb message from JSON.
func (*RootDb) UnmarshalVT ¶
type SqlTx ¶
type SqlTx struct {
*Tx
// contains filtered or unexported fields
}
SqlTx implements sql.Transaction with a *Tx.
func (*SqlTx) GetReadOnly ¶
GetReadOnly returns if the transaction is read-only.
type Table ¶
type Table struct {
// contains filtered or unexported fields
}
Table is the block-graph backed data table cursor. NOTE: calls are not concurrency-safe.
func (*Table) AutoIncrementSetter ¶
func (t *Table) AutoIncrementSetter(sqlCtx *sql.Context) sql.AutoIncrementSetter
AutoIncrementSetter returns an AutoIncrementSetter.
func (*Table) Collation ¶
func (t *Table) Collation() sql.CollationID
Collation returns the collation type ID.
func (*Table) GetNextAutoIncrementValue ¶
GetNextAutoIncrementValue gets the next AUTO_INCREMENT value. In the case that a table with an autoincrement column is passed in a row with the autoinc column failed, the next auto increment value must update its internal state accordingly and use the insert val at runtime. Implementations are responsible for updating their state to provide the correct values.
func (*Table) Inserter ¶
func (t *Table) Inserter(sqlCtx *sql.Context) sql.RowInserter
Inserter returns a row inserter for the table.
func (*Table) NewTableEditor ¶
func (t *Table) NewTableEditor(sqlCtx *sql.Context) *TableEditor
NewTableEditor constructs a new table editor.
func (*Table) PartitionAtIndex ¶
func (t *Table) PartitionAtIndex(ix int) (*TablePartition, error)
PartitionAtIndex returns the partition at an index.
Returns io.EOF if out of range.
func (*Table) PartitionCount ¶
PartitionCount returns the number of partitions.
func (*Table) PartitionRows ¶
PartitionRows returns a table iterator for the rows in a partition.
func (*Table) Partitions ¶
Partitions returns an iterator for the table partitions.
func (*Table) PeekNextAutoIncrementValue ¶
PeekNextAutoIncrementValue peeks at the next AUTO_INCREMENT value
func (*Table) PrimaryKeySchema ¶
func (t *Table) PrimaryKeySchema(*sql.Context) sql.PrimaryKeySchema
PrimaryKeySchema returns this table's PrimaryKeySchema
func (*Table) SelectPartition ¶
func (t *Table) SelectPartition(nonce uint64) (*TablePartition, int, error)
SelectPartition selects the partition based on the index (round-robin).
func (*Table) SetIndexLookup ¶
func (t *Table) SetIndexLookup(lookup *sql.IndexLookup)
SetIndexLookup sets the index lookup.
type TableColumn ¶
type TableColumn struct {
// Value contains the SQL value. If no field is set, the column is NULL.
//
// Types that are assignable to Value:
//
// *TableColumn_BoolValue
// *TableColumn_IntValue
// *TableColumn_UintValue
// *TableColumn_FloatValue
// *TableColumn_StringBlob
// *TableColumn_BytesBlob
// *TableColumn_JsonBlob
// *TableColumn_TimestampValue
// *TableColumn_TimespanMicros
Value isTableColumn_Value `protobuf_oneof:"value"`
// contains filtered or unexported fields
}
TableColumn is an entry in a table row.
func BuildTableColumn ¶
func BuildTableColumn( ctx context.Context, bcs *block.Cursor, opts *blob.BuildBlobOpts, col any, ) (*TableColumn, error)
BuildTableColumn constructs a TableColumn by marshaling a col.
bcs must be set.
func (*TableColumn) ApplySubBlock ¶
func (t *TableColumn) ApplySubBlock(id uint32, next block.SubBlock) error
ApplySubBlock applies a sub-block change with a field id.
func (*TableColumn) CloneMessageVT ¶
func (m *TableColumn) CloneMessageVT() protobuf_go_lite.CloneMessage
func (*TableColumn) CloneVT ¶
func (m *TableColumn) CloneVT() *TableColumn
func (*TableColumn) EqualMessageVT ¶
func (this *TableColumn) EqualMessageVT(thatMsg any) bool
func (*TableColumn) EqualVT ¶
func (this *TableColumn) EqualVT(that *TableColumn) bool
func (*TableColumn) FetchSqlColumn ¶
FetchSqlColumn converts the row back into a sql column.
func (*TableColumn) GetBoolValue ¶
func (x *TableColumn) GetBoolValue() bool
func (*TableColumn) GetBytesBlob ¶
func (x *TableColumn) GetBytesBlob() *blob.Blob
func (*TableColumn) GetFloatValue ¶
func (x *TableColumn) GetFloatValue() float64
func (*TableColumn) GetIntValue ¶
func (x *TableColumn) GetIntValue() int64
func (*TableColumn) GetJsonBlob ¶
func (x *TableColumn) GetJsonBlob() *blob.Blob
func (*TableColumn) GetStringBlob ¶
func (x *TableColumn) GetStringBlob() *blob.Blob
func (*TableColumn) GetSubBlockCtor ¶
func (t *TableColumn) GetSubBlockCtor(id uint32) block.SubBlockCtor
GetSubBlockCtor returns a function which creates or returns the existing sub-block at reference id. Can return nil to indicate invalid reference id.
func (*TableColumn) GetSubBlocks ¶
func (t *TableColumn) GetSubBlocks() map[uint32]block.SubBlock
GetSubBlocks returns all constructed sub-blocks by ID. May return nil, and values may also be nil.
func (*TableColumn) GetTimespanMicros ¶
func (x *TableColumn) GetTimespanMicros() int64
func (*TableColumn) GetTimestampValue ¶
func (x *TableColumn) GetTimestampValue() *TableTimestamp
func (*TableColumn) GetUintValue ¶
func (x *TableColumn) GetUintValue() uint64
func (*TableColumn) GetValue ¶
func (m *TableColumn) GetValue() isTableColumn_Value
func (*TableColumn) IsEmpty ¶
func (t *TableColumn) IsEmpty() bool
IsEmpty checks if the table column is empty.
func (*TableColumn) MarshalBlock ¶
func (t *TableColumn) MarshalBlock() ([]byte, error)
MarshalBlock marshals the block to binary. This is the initial step of marshaling, before transformations.
func (*TableColumn) MarshalJSON ¶
func (x *TableColumn) MarshalJSON() ([]byte, error)
MarshalJSON marshals the TableColumn to JSON.
func (*TableColumn) MarshalProtoJSON ¶
func (x *TableColumn) MarshalProtoJSON(s *json.MarshalState)
MarshalProtoJSON marshals the TableColumn message to JSON.
func (*TableColumn) MarshalProtoText ¶
func (x *TableColumn) MarshalProtoText() string
func (*TableColumn) MarshalToSizedBufferVT ¶
func (m *TableColumn) MarshalToSizedBufferVT(dAtA []byte) (int, error)
func (*TableColumn) MarshalToVT ¶
func (m *TableColumn) MarshalToVT(dAtA []byte) (int, error)
func (*TableColumn) MarshalVT ¶
func (m *TableColumn) MarshalVT() (dAtA []byte, err error)
func (*TableColumn) ProtoMessage ¶
func (*TableColumn) ProtoMessage()
func (*TableColumn) Reset ¶
func (x *TableColumn) Reset()
func (*TableColumn) SizeVT ¶
func (m *TableColumn) SizeVT() (n int)
func (*TableColumn) String ¶
func (x *TableColumn) String() string
func (*TableColumn) UnmarshalBlock ¶
func (t *TableColumn) UnmarshalBlock(data []byte) error
UnmarshalBlock unmarshals the block to the object. This is the final step of decoding, after transformations.
func (*TableColumn) UnmarshalJSON ¶
func (x *TableColumn) UnmarshalJSON(b []byte) error
UnmarshalJSON unmarshals the TableColumn from JSON.
func (*TableColumn) UnmarshalProtoJSON ¶
func (x *TableColumn) UnmarshalProtoJSON(s *json.UnmarshalState)
UnmarshalProtoJSON unmarshals the TableColumn message from JSON.
func (*TableColumn) UnmarshalVT ¶
func (m *TableColumn) UnmarshalVT(dAtA []byte) error
func (*TableColumn) Validate ¶
func (t *TableColumn) Validate() error
Validate performs cursory validation of the table column.
type TableColumn_BoolValue ¶
type TableColumn_BoolValue struct {
// BoolValue is a boolean SQL value.
BoolValue bool `protobuf:"varint,2,opt,name=bool_value,json=boolValue,proto3,oneof"`
}
func (*TableColumn_BoolValue) CloneOneofVT ¶
func (m *TableColumn_BoolValue) CloneOneofVT() isTableColumn_Value
func (*TableColumn_BoolValue) CloneVT ¶
func (m *TableColumn_BoolValue) CloneVT() *TableColumn_BoolValue
func (*TableColumn_BoolValue) EqualVT ¶
func (this *TableColumn_BoolValue) EqualVT(thatIface isTableColumn_Value) bool
func (*TableColumn_BoolValue) MarshalToSizedBufferVT ¶
func (m *TableColumn_BoolValue) MarshalToSizedBufferVT(dAtA []byte) (int, error)
func (*TableColumn_BoolValue) MarshalToVT ¶
func (m *TableColumn_BoolValue) MarshalToVT(dAtA []byte) (int, error)
func (*TableColumn_BoolValue) SizeVT ¶
func (m *TableColumn_BoolValue) SizeVT() (n int)
type TableColumn_BytesBlob ¶
type TableColumn_BytesBlob struct {
// BytesBlob is a binary SQL value.
BytesBlob *blob.Blob `protobuf:"bytes,7,opt,name=bytes_blob,json=bytesBlob,proto3,oneof"`
}
func (*TableColumn_BytesBlob) CloneOneofVT ¶
func (m *TableColumn_BytesBlob) CloneOneofVT() isTableColumn_Value
func (*TableColumn_BytesBlob) CloneVT ¶
func (m *TableColumn_BytesBlob) CloneVT() *TableColumn_BytesBlob
func (*TableColumn_BytesBlob) EqualVT ¶
func (this *TableColumn_BytesBlob) EqualVT(thatIface isTableColumn_Value) bool
func (*TableColumn_BytesBlob) MarshalToSizedBufferVT ¶
func (m *TableColumn_BytesBlob) MarshalToSizedBufferVT(dAtA []byte) (int, error)
func (*TableColumn_BytesBlob) MarshalToVT ¶
func (m *TableColumn_BytesBlob) MarshalToVT(dAtA []byte) (int, error)
func (*TableColumn_BytesBlob) SizeVT ¶
func (m *TableColumn_BytesBlob) SizeVT() (n int)
type TableColumn_FloatValue ¶
type TableColumn_FloatValue struct {
// FloatValue is a floating-point SQL value.
FloatValue float64 `protobuf:"fixed64,5,opt,name=float_value,json=floatValue,proto3,oneof"`
}
func (*TableColumn_FloatValue) CloneOneofVT ¶
func (m *TableColumn_FloatValue) CloneOneofVT() isTableColumn_Value
func (*TableColumn_FloatValue) CloneVT ¶
func (m *TableColumn_FloatValue) CloneVT() *TableColumn_FloatValue
func (*TableColumn_FloatValue) EqualVT ¶
func (this *TableColumn_FloatValue) EqualVT(thatIface isTableColumn_Value) bool
func (*TableColumn_FloatValue) MarshalToSizedBufferVT ¶
func (m *TableColumn_FloatValue) MarshalToSizedBufferVT(dAtA []byte) (int, error)
func (*TableColumn_FloatValue) MarshalToVT ¶
func (m *TableColumn_FloatValue) MarshalToVT(dAtA []byte) (int, error)
func (*TableColumn_FloatValue) SizeVT ¶
func (m *TableColumn_FloatValue) SizeVT() (n int)
type TableColumn_IntValue ¶
type TableColumn_IntValue struct {
// IntValue is a signed integer SQL value.
IntValue int64 `protobuf:"varint,3,opt,name=int_value,json=intValue,proto3,oneof"`
}
func (*TableColumn_IntValue) CloneOneofVT ¶
func (m *TableColumn_IntValue) CloneOneofVT() isTableColumn_Value
func (*TableColumn_IntValue) CloneVT ¶
func (m *TableColumn_IntValue) CloneVT() *TableColumn_IntValue
func (*TableColumn_IntValue) EqualVT ¶
func (this *TableColumn_IntValue) EqualVT(thatIface isTableColumn_Value) bool
func (*TableColumn_IntValue) MarshalToSizedBufferVT ¶
func (m *TableColumn_IntValue) MarshalToSizedBufferVT(dAtA []byte) (int, error)
func (*TableColumn_IntValue) MarshalToVT ¶
func (m *TableColumn_IntValue) MarshalToVT(dAtA []byte) (int, error)
func (*TableColumn_IntValue) SizeVT ¶
func (m *TableColumn_IntValue) SizeVT() (n int)
type TableColumn_JsonBlob ¶
type TableColumn_JsonBlob struct {
// JsonBlob is a JSON SQL value encoded as UTF-8 text.
JsonBlob *blob.Blob `protobuf:"bytes,8,opt,name=json_blob,json=jsonBlob,proto3,oneof"`
}
func (*TableColumn_JsonBlob) CloneOneofVT ¶
func (m *TableColumn_JsonBlob) CloneOneofVT() isTableColumn_Value
func (*TableColumn_JsonBlob) CloneVT ¶
func (m *TableColumn_JsonBlob) CloneVT() *TableColumn_JsonBlob
func (*TableColumn_JsonBlob) EqualVT ¶
func (this *TableColumn_JsonBlob) EqualVT(thatIface isTableColumn_Value) bool
func (*TableColumn_JsonBlob) MarshalToSizedBufferVT ¶
func (m *TableColumn_JsonBlob) MarshalToSizedBufferVT(dAtA []byte) (int, error)
func (*TableColumn_JsonBlob) MarshalToVT ¶
func (m *TableColumn_JsonBlob) MarshalToVT(dAtA []byte) (int, error)
func (*TableColumn_JsonBlob) SizeVT ¶
func (m *TableColumn_JsonBlob) SizeVT() (n int)
type TableColumn_StringBlob ¶
type TableColumn_StringBlob struct {
// StringBlob is a string SQL value encoded as UTF-8 bytes.
StringBlob *blob.Blob `protobuf:"bytes,6,opt,name=string_blob,json=stringBlob,proto3,oneof"`
}
func (*TableColumn_StringBlob) CloneOneofVT ¶
func (m *TableColumn_StringBlob) CloneOneofVT() isTableColumn_Value
func (*TableColumn_StringBlob) CloneVT ¶
func (m *TableColumn_StringBlob) CloneVT() *TableColumn_StringBlob
func (*TableColumn_StringBlob) EqualVT ¶
func (this *TableColumn_StringBlob) EqualVT(thatIface isTableColumn_Value) bool
func (*TableColumn_StringBlob) MarshalToSizedBufferVT ¶
func (m *TableColumn_StringBlob) MarshalToSizedBufferVT(dAtA []byte) (int, error)
func (*TableColumn_StringBlob) MarshalToVT ¶
func (m *TableColumn_StringBlob) MarshalToVT(dAtA []byte) (int, error)
func (*TableColumn_StringBlob) SizeVT ¶
func (m *TableColumn_StringBlob) SizeVT() (n int)
type TableColumn_TimespanMicros ¶
type TableColumn_TimespanMicros struct {
// TimespanMicros is a TIME SQL value in microseconds.
TimespanMicros int64 `protobuf:"varint,10,opt,name=timespan_micros,json=timespanMicros,proto3,oneof"`
}
func (*TableColumn_TimespanMicros) CloneOneofVT ¶
func (m *TableColumn_TimespanMicros) CloneOneofVT() isTableColumn_Value
func (*TableColumn_TimespanMicros) CloneVT ¶
func (m *TableColumn_TimespanMicros) CloneVT() *TableColumn_TimespanMicros
func (*TableColumn_TimespanMicros) EqualVT ¶
func (this *TableColumn_TimespanMicros) EqualVT(thatIface isTableColumn_Value) bool
func (*TableColumn_TimespanMicros) MarshalToSizedBufferVT ¶
func (m *TableColumn_TimespanMicros) MarshalToSizedBufferVT(dAtA []byte) (int, error)
func (*TableColumn_TimespanMicros) MarshalToVT ¶
func (m *TableColumn_TimespanMicros) MarshalToVT(dAtA []byte) (int, error)
func (*TableColumn_TimespanMicros) SizeVT ¶
func (m *TableColumn_TimespanMicros) SizeVT() (n int)
type TableColumn_TimestampValue ¶
type TableColumn_TimestampValue struct {
// TimestampValue is a timestamp, datetime, or date SQL value.
TimestampValue *TableTimestamp `protobuf:"bytes,9,opt,name=timestamp_value,json=timestampValue,proto3,oneof"`
}
func (*TableColumn_TimestampValue) CloneOneofVT ¶
func (m *TableColumn_TimestampValue) CloneOneofVT() isTableColumn_Value
func (*TableColumn_TimestampValue) CloneVT ¶
func (m *TableColumn_TimestampValue) CloneVT() *TableColumn_TimestampValue
func (*TableColumn_TimestampValue) EqualVT ¶
func (this *TableColumn_TimestampValue) EqualVT(thatIface isTableColumn_Value) bool
func (*TableColumn_TimestampValue) MarshalToSizedBufferVT ¶
func (m *TableColumn_TimestampValue) MarshalToSizedBufferVT(dAtA []byte) (int, error)
func (*TableColumn_TimestampValue) MarshalToVT ¶
func (m *TableColumn_TimestampValue) MarshalToVT(dAtA []byte) (int, error)
func (*TableColumn_TimestampValue) SizeVT ¶
func (m *TableColumn_TimestampValue) SizeVT() (n int)
type TableColumn_UintValue ¶
type TableColumn_UintValue struct {
// UintValue is an unsigned integer SQL value.
UintValue uint64 `protobuf:"varint,4,opt,name=uint_value,json=uintValue,proto3,oneof"`
}
func (*TableColumn_UintValue) CloneOneofVT ¶
func (m *TableColumn_UintValue) CloneOneofVT() isTableColumn_Value
func (*TableColumn_UintValue) CloneVT ¶
func (m *TableColumn_UintValue) CloneVT() *TableColumn_UintValue
func (*TableColumn_UintValue) EqualVT ¶
func (this *TableColumn_UintValue) EqualVT(thatIface isTableColumn_Value) bool
func (*TableColumn_UintValue) MarshalToSizedBufferVT ¶
func (m *TableColumn_UintValue) MarshalToSizedBufferVT(dAtA []byte) (int, error)
func (*TableColumn_UintValue) MarshalToVT ¶
func (m *TableColumn_UintValue) MarshalToVT(dAtA []byte) (int, error)
func (*TableColumn_UintValue) SizeVT ¶
func (m *TableColumn_UintValue) SizeVT() (n int)
type TableEditor ¶
type TableEditor struct {
// contains filtered or unexported fields
}
TableEditor implements row management operations against a table.
Note: all table operations are (currently) not concurrency safe.
func NewTableEditor ¶
func NewTableEditor(ctx context.Context, t *Table) *TableEditor
NewTableEditor constructs a new table row inserter.
func (*TableEditor) AcquireAutoIncrementLock ¶
func (i *TableEditor) AcquireAutoIncrementLock(ctx *sql.Context) (func(), error)
AcquireAutoIncrementLock acquires (if necessary) an exclusive lock on generating auto-increment values for the underlying table. This is called when @@innodb_autoinc_lock_mode is set to 0 (traditional) or 1 (consecutive), in order to guarantee that insert operations get a consecutive range of generated ids. The function returns a callback to release the lock.
func (*TableEditor) Close ¶
func (i *TableEditor) Close(sqlCtx *sql.Context) error
Close finalizes the operation, persisting its result.
func (*TableEditor) DiscardChanges ¶
func (i *TableEditor) DiscardChanges(ctx *sql.Context, errorEncountered error) error
DiscardChanges is called if a statement encounters an error, and all current changes since the statement beginning should be discarded.
func (*TableEditor) Insert ¶
Insert inserts the row given, returning an error if it cannot. Insert will be called once for each row to process for the insert operation, which may involve many rows. After all rows in an operation have been processed, Close is called.
func (*TableEditor) SetAutoIncrementValue ¶
func (i *TableEditor) SetAutoIncrementValue(sqlCtx *sql.Context, val uint64) error
SetAutoIncrementValue sets a new AUTO_INCREMENT value.
func (*TableEditor) SetBuildBlobOpts ¶
func (i *TableEditor) SetBuildBlobOpts(opts *blob.BuildBlobOpts)
SetBuildBlobOpts sets the build blob options.
func (*TableEditor) StatementBegin ¶
func (i *TableEditor) StatementBegin(ctx *sql.Context)
StatementBegin is called before the first operation of a statement. Integrators should mark the state of the data in some way that it may be returned to in the case of an error.
func (*TableEditor) StatementComplete ¶
func (i *TableEditor) StatementComplete(ctx *sql.Context) error
StatementComplete is called after the last operation of the statement, indicating that it has successfully completed. The mark set in StatementBegin may be removed, and a new one should be created on the next StatementBegin.
type TablePartition ¶
type TablePartition struct {
// contains filtered or unexported fields
}
TablePartition is a table partition handle.
func NewTablePartition ¶
func NewTablePartition( idx int, t *TablePartitionRoot, bcs *block.Cursor, schema sql.Schema, lookup sql.IndexLookup, ) (*TablePartition, error)
NewTablePartition constructs a table partition handle.
bcs should be located at the TablePartitionRoot sub-block. lookup can be nil
func (*TablePartition) BuildTreeTx ¶
BuildTreeTx builds the avl tree transaction.
func (*TablePartition) IterateRows ¶
IterateRows returns a row iterator.
type TablePartitionIter ¶
type TablePartitionIter struct {
// contains filtered or unexported fields
}
TablePartitionIter is a table partition iterator.
func NewTablePartitionIter ¶
func NewTablePartitionIter(t *Table) *TablePartitionIter
NewTablePartitionIter constructs a new PartitionIter.
type TablePartitionRoot ¶
type TablePartitionRoot struct {
// RowKeyValue is the key/value tree of objects.
// Key: row_nonce uint64 encoded with big endian
// Value: cid.BlockRef -> Object
RowKeyValue *block1.KeyValueStore `protobuf:"bytes,1,opt,name=row_key_value,json=rowKeyValue,proto3" json:"rowKeyValue,omitempty"`
// contains filtered or unexported fields
}
TablePartitionRoot contains the root of a table partition.
func NewTablePartitionRoot ¶
func NewTablePartitionRoot() *TablePartitionRoot
NewTablePartitionRoot constructs a new table partition root object.
func (*TablePartitionRoot) ApplySubBlock ¶
func (r *TablePartitionRoot) ApplySubBlock(id uint32, next block.SubBlock) error
ApplySubBlock applies a sub-block change with a field id.
func (*TablePartitionRoot) CloneMessageVT ¶
func (m *TablePartitionRoot) CloneMessageVT() protobuf_go_lite.CloneMessage
func (*TablePartitionRoot) CloneVT ¶
func (m *TablePartitionRoot) CloneVT() *TablePartitionRoot
func (*TablePartitionRoot) EqualMessageVT ¶
func (this *TablePartitionRoot) EqualMessageVT(thatMsg any) bool
func (*TablePartitionRoot) EqualVT ¶
func (this *TablePartitionRoot) EqualVT(that *TablePartitionRoot) bool
func (*TablePartitionRoot) GetRowKeyValue ¶
func (x *TablePartitionRoot) GetRowKeyValue() *block1.KeyValueStore
func (*TablePartitionRoot) GetSubBlockCtor ¶
func (r *TablePartitionRoot) GetSubBlockCtor(id uint32) block.SubBlockCtor
GetSubBlockCtor returns a function which creates or returns the existing sub-block at reference id. Can return nil to indicate invalid reference id.
func (*TablePartitionRoot) GetSubBlocks ¶
func (r *TablePartitionRoot) GetSubBlocks() map[uint32]block.SubBlock
GetSubBlocks returns all constructed sub-blocks by ID. May return nil, and values may also be nil.
func (*TablePartitionRoot) IsNil ¶
func (r *TablePartitionRoot) IsNil() bool
IsNil returns if the object is nil.
func (*TablePartitionRoot) MarshalJSON ¶
func (x *TablePartitionRoot) MarshalJSON() ([]byte, error)
MarshalJSON marshals the TablePartitionRoot to JSON.
func (*TablePartitionRoot) MarshalProtoJSON ¶
func (x *TablePartitionRoot) MarshalProtoJSON(s *json.MarshalState)
MarshalProtoJSON marshals the TablePartitionRoot message to JSON.
func (*TablePartitionRoot) MarshalProtoText ¶
func (x *TablePartitionRoot) MarshalProtoText() string
func (*TablePartitionRoot) MarshalToSizedBufferVT ¶
func (m *TablePartitionRoot) MarshalToSizedBufferVT(dAtA []byte) (int, error)
func (*TablePartitionRoot) MarshalToVT ¶
func (m *TablePartitionRoot) MarshalToVT(dAtA []byte) (int, error)
func (*TablePartitionRoot) MarshalVT ¶
func (m *TablePartitionRoot) MarshalVT() (dAtA []byte, err error)
func (*TablePartitionRoot) ProtoMessage ¶
func (*TablePartitionRoot) ProtoMessage()
func (*TablePartitionRoot) Reset ¶
func (x *TablePartitionRoot) Reset()
func (*TablePartitionRoot) SizeVT ¶
func (m *TablePartitionRoot) SizeVT() (n int)
func (*TablePartitionRoot) String ¶
func (x *TablePartitionRoot) String() string
func (*TablePartitionRoot) UnmarshalJSON ¶
func (x *TablePartitionRoot) UnmarshalJSON(b []byte) error
UnmarshalJSON unmarshals the TablePartitionRoot from JSON.
func (*TablePartitionRoot) UnmarshalProtoJSON ¶
func (x *TablePartitionRoot) UnmarshalProtoJSON(s *json.UnmarshalState)
UnmarshalProtoJSON unmarshals the TablePartitionRoot message from JSON.
func (*TablePartitionRoot) UnmarshalVT ¶
func (m *TablePartitionRoot) UnmarshalVT(dAtA []byte) error
func (*TablePartitionRoot) Validate ¶
func (r *TablePartitionRoot) Validate() error
Validate performs cursory validation of the table partition root.
type TablePartitionRowIter ¶
type TablePartitionRowIter struct {
// contains filtered or unexported fields
}
TablePartitionRowIter is a table partition iterator.
func NewTablePartitionRowIter ¶
func NewTablePartitionRowIter( ctx context.Context, tree kvtx.BlockTx, schema sql.Schema, ) (*TablePartitionRowIter, error)
NewTablePartitionRowIter constructs a table partition row iterator.
func (*TablePartitionRowIter) Close ¶
func (i *TablePartitionRowIter) Close(sctx *sql.Context) error
Close the iterator.
func (*TablePartitionRowIter) GetRow ¶
func (i *TablePartitionRowIter) GetRow() (sql.Row, error)
GetRow returns the row at the index.
func (*TablePartitionRowIter) Next ¶
Next retrieves the next row. It will return io.EOF if it's the last row. After retrieving the last row, Close will be automatically closed.
type TableRoot ¶
type TableRoot struct {
// TableSchema is the table schema.
TableSchema *TableSchema `protobuf:"bytes,1,opt,name=table_schema,json=tableSchema,proto3" json:"tableSchema,omitempty"`
// PrimaryKeyOrdinals is the PkOrdinals field of PrimaryKeySchema.
PrimaryKeyOrdinals []int32 `protobuf:"varint,5,rep,packed,name=primary_key_ordinals,json=primaryKeyOrdinals,proto3" json:"primaryKeyOrdinals,omitempty"`
// TablePartitions contains the set of table partitions.
TablePartitions []*TablePartitionRoot `protobuf:"bytes,2,rep,name=table_partitions,json=tablePartitions,proto3" json:"tablePartitions,omitempty"`
// RowNonce is the row identifier nonce, incremented when a row is inserted.
RowNonce uint64 `protobuf:"varint,3,opt,name=row_nonce,json=rowNonce,proto3" json:"rowNonce,omitempty"`
// AutoIncrVal is the auto increment value, if necessary.
// Typically contains an integer or float.
// Empty if auto_incr_index is zero.
AutoIncrVal *TableColumn `protobuf:"bytes,4,opt,name=auto_incr_val,json=autoIncrVal,proto3" json:"autoIncrVal,omitempty"`
// CollationId is the method ID of the method used to control sorting.
CollationId uint32 `protobuf:"varint,6,opt,name=collation_id,json=collationId,proto3" json:"collationId,omitempty"`
// Comment is an additional comment on the table.
Comment string `protobuf:"bytes,7,opt,name=comment,proto3" json:"comment,omitempty"`
// contains filtered or unexported fields
}
TableRoot is the root object of the table.
func LoadTableRoot ¶
LoadTableRoot follows the database root cursor. may return nil
func (*TableRoot) ApplySubBlock ¶
ApplySubBlock applies a sub-block change with a field id.
func (*TableRoot) CloneMessageVT ¶
func (m *TableRoot) CloneMessageVT() protobuf_go_lite.CloneMessage
func (*TableRoot) EqualMessageVT ¶
func (*TableRoot) FetchAutoIncrVal ¶
func (r *TableRoot) FetchAutoIncrVal( ctx context.Context, bcs *block.Cursor, expectedType sql.Type, ) (any, sql.ConvertInRange, error)
FetchAutoIncrVal fetches and checks the auto-increment value
bcs should be located at the table root.
func (*TableRoot) GetAutoIncrVal ¶
func (x *TableRoot) GetAutoIncrVal() *TableColumn
func (*TableRoot) GetCollationId ¶
func (*TableRoot) GetComment ¶
func (*TableRoot) GetPrimaryKeyOrdinals ¶
func (*TableRoot) GetRowNonce ¶
func (*TableRoot) GetSubBlockCtor ¶
func (r *TableRoot) GetSubBlockCtor(id uint32) block.SubBlockCtor
GetSubBlockCtor returns a function which creates or returns the existing sub-block at reference id. Can return nil to indicate invalid reference id.
func (*TableRoot) GetSubBlocks ¶
GetSubBlocks returns all constructed sub-blocks by ID. May return nil, and values may also be nil.
func (*TableRoot) GetTablePartitions ¶
func (x *TableRoot) GetTablePartitions() []*TablePartitionRoot
func (*TableRoot) GetTableSchema ¶
func (x *TableRoot) GetTableSchema() *TableSchema
func (*TableRoot) MarshalBlock ¶
MarshalBlock marshals the block to binary. This is the initial step of marshaling, before transformations.
func (*TableRoot) MarshalJSON ¶
MarshalJSON marshals the TableRoot to JSON.
func (*TableRoot) MarshalProtoJSON ¶
func (x *TableRoot) MarshalProtoJSON(s *json.MarshalState)
MarshalProtoJSON marshals the TableRoot message to JSON.
func (*TableRoot) MarshalProtoText ¶
func (*TableRoot) MarshalToSizedBufferVT ¶
func (*TableRoot) ProtoMessage ¶
func (*TableRoot) ProtoMessage()
func (*TableRoot) StoreAutoIncrVal ¶
func (r *TableRoot) StoreAutoIncrVal( ctx context.Context, bcs *block.Cursor, buildBlobOpts *blob.BuildBlobOpts, val any, ) error
StoreAutoIncrVal stores the auto-increment value
bcs should be located at the table root.
func (*TableRoot) UnmarshalBlock ¶
UnmarshalBlock unmarshals the block to the object. This is the final step of decoding, after transformations.
func (*TableRoot) UnmarshalJSON ¶
UnmarshalJSON unmarshals the TableRoot from JSON.
func (*TableRoot) UnmarshalProtoJSON ¶
func (x *TableRoot) UnmarshalProtoJSON(s *json.UnmarshalState)
UnmarshalProtoJSON unmarshals the TableRoot message from JSON.
func (*TableRoot) UnmarshalVT ¶
type TableRow ¶
type TableRow struct {
// Columns contains the set of columns.
Columns []*TableColumn `protobuf:"bytes,1,rep,name=columns,proto3" json:"columns,omitempty"`
// contains filtered or unexported fields
}
TableRow is a row in a table.
func BuildTableRow ¶
func BuildTableRow( ctx context.Context, bcs *block.Cursor, row sql.Row, buildBlobOpts *blob.BuildBlobOpts, ) (*TableRow, error)
BuildTableRow constructs a TableRow by marshaling cols with msgpack blobs.
Stores sub-blocks and references using the cursor. Sets the block at the cursor. If columns are large enough, they will be sharded into separate blocks. Supports streaming decoding at a later time. buildBlobOpts is optional bcs is required autoIncIdx and autoIncVal are optional.
func UnmarshalTableRow ¶
UnmarshalTableRow unmarshals the TableRow block. Returns nil, nil if empty
func (*TableRow) ApplySubBlock ¶
ApplySubBlock applies a sub-block change with a field id.
func (*TableRow) CloneMessageVT ¶
func (m *TableRow) CloneMessageVT() protobuf_go_lite.CloneMessage
func (*TableRow) EqualMessageVT ¶
func (*TableRow) FetchSqlRow ¶
FetchSqlRow fetches columns into a sql.Row structure. This converts the encoded table column values into Go types. The resulting sql.Row should be checked against a schema.
func (*TableRow) GetColumns ¶
func (x *TableRow) GetColumns() []*TableColumn
func (*TableRow) GetSubBlockCtor ¶
func (r *TableRow) GetSubBlockCtor(id uint32) block.SubBlockCtor
GetSubBlockCtor returns a function which creates or returns the existing sub-block at reference id. Can return nil to indicate invalid reference id.
func (*TableRow) GetSubBlocks ¶
GetSubBlocks returns all constructed sub-blocks by ID. May return nil, and values may also be nil.
func (*TableRow) MarshalBlock ¶
MarshalBlock marshals the block to binary. This is the initial step of marshaling, before transformations.
func (*TableRow) MarshalJSON ¶
MarshalJSON marshals the TableRow to JSON.
func (*TableRow) MarshalProtoJSON ¶
func (x *TableRow) MarshalProtoJSON(s *json.MarshalState)
MarshalProtoJSON marshals the TableRow message to JSON.
func (*TableRow) MarshalProtoText ¶
func (*TableRow) MarshalToSizedBufferVT ¶
func (*TableRow) ProtoMessage ¶
func (*TableRow) ProtoMessage()
func (*TableRow) UnmarshalBlock ¶
UnmarshalBlock unmarshals the block to the object. This is the final step of decoding, after transformations.
func (*TableRow) UnmarshalJSON ¶
UnmarshalJSON unmarshals the TableRow from JSON.
func (*TableRow) UnmarshalProtoJSON ¶
func (x *TableRow) UnmarshalProtoJSON(s *json.UnmarshalState)
UnmarshalProtoJSON unmarshals the TableRow message from JSON.
func (*TableRow) UnmarshalVT ¶
type TableSchema ¶
type TableSchema struct {
// Columns is the list of columns in the table, sorted by name.
Columns []*TableSchemaColumn `protobuf:"bytes,1,rep,name=columns,proto3" json:"columns,omitempty"`
// contains filtered or unexported fields
}
TableSchema is the schema for a table.
func NewTableSchema ¶
func NewTableSchema(schema sql.Schema) *TableSchema
NewTableSchema constructs a table schema from sql schema.
func (*TableSchema) CloneMessageVT ¶
func (m *TableSchema) CloneMessageVT() protobuf_go_lite.CloneMessage
func (*TableSchema) CloneVT ¶
func (m *TableSchema) CloneVT() *TableSchema
func (*TableSchema) EqualMessageVT ¶
func (this *TableSchema) EqualMessageVT(thatMsg any) bool
func (*TableSchema) EqualVT ¶
func (this *TableSchema) EqualVT(that *TableSchema) bool
func (*TableSchema) GetColumns ¶
func (x *TableSchema) GetColumns() []*TableSchemaColumn
func (*TableSchema) MarshalJSON ¶
func (x *TableSchema) MarshalJSON() ([]byte, error)
MarshalJSON marshals the TableSchema to JSON.
func (*TableSchema) MarshalProtoJSON ¶
func (x *TableSchema) MarshalProtoJSON(s *json.MarshalState)
MarshalProtoJSON marshals the TableSchema message to JSON.
func (*TableSchema) MarshalProtoText ¶
func (x *TableSchema) MarshalProtoText() string
func (*TableSchema) MarshalToSizedBufferVT ¶
func (m *TableSchema) MarshalToSizedBufferVT(dAtA []byte) (int, error)
func (*TableSchema) MarshalToVT ¶
func (m *TableSchema) MarshalToVT(dAtA []byte) (int, error)
func (*TableSchema) MarshalVT ¶
func (m *TableSchema) MarshalVT() (dAtA []byte, err error)
func (*TableSchema) ProtoMessage ¶
func (*TableSchema) ProtoMessage()
func (*TableSchema) Reset ¶
func (x *TableSchema) Reset()
func (*TableSchema) SizeVT ¶
func (m *TableSchema) SizeVT() (n int)
func (*TableSchema) String ¶
func (x *TableSchema) String() string
func (*TableSchema) UnmarshalJSON ¶
func (x *TableSchema) UnmarshalJSON(b []byte) error
UnmarshalJSON unmarshals the TableSchema from JSON.
func (*TableSchema) UnmarshalProtoJSON ¶
func (x *TableSchema) UnmarshalProtoJSON(s *json.UnmarshalState)
UnmarshalProtoJSON unmarshals the TableSchema message from JSON.
func (*TableSchema) UnmarshalVT ¶
func (m *TableSchema) UnmarshalVT(dAtA []byte) error
func (*TableSchema) Validate ¶
func (s *TableSchema) Validate() error
Validate performs cursory validation of the table schema.
type TableSchemaColumn ¶
type TableSchemaColumn struct {
// Name is the name of the column.
Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"`
// ColumnType is the data type of the column.
ColumnType string `protobuf:"bytes,2,opt,name=column_type,json=columnType,proto3" json:"columnType,omitempty"`
// DefaultValueExpr is the default value expression, encoded to a string.
DefaultValueExpr string `protobuf:"bytes,3,opt,name=default_value_expr,json=defaultValueExpr,proto3" json:"defaultValueExpr,omitempty"`
// AutoIncrement is true if the column auto-increments.
AutoIncrement bool `protobuf:"varint,4,opt,name=auto_increment,json=autoIncrement,proto3" json:"autoIncrement,omitempty"`
// Nullable is true if the column can contain NULL values, or false otherwise.
Nullable bool `protobuf:"varint,5,opt,name=nullable,proto3" json:"nullable,omitempty"`
// Source is the name of the table this column came from.
Source string `protobuf:"bytes,6,opt,name=source,proto3" json:"source,omitempty"`
// PrimaryKey is true if the column is part of the primary key for its table.
PrimaryKey bool `protobuf:"varint,7,opt,name=primary_key,json=primaryKey,proto3" json:"primaryKey,omitempty"`
// Comment contains the string comment for this column.
Comment string `protobuf:"bytes,8,opt,name=comment,proto3" json:"comment,omitempty"`
// Extra contains any additional information to put in the `extra` column under `information_schema.columns`.
Extra string `protobuf:"bytes,9,opt,name=extra,proto3" json:"extra,omitempty"`
// contains filtered or unexported fields
}
TableSchemaColumn is the definition of a column for a table schema.
func NewTableSchemaColumn ¶
func NewTableSchemaColumn(col *sql.Column) *TableSchemaColumn
NewTableSchemaColumn constructs a table column from sql schema.
func (*TableSchemaColumn) CloneMessageVT ¶
func (m *TableSchemaColumn) CloneMessageVT() protobuf_go_lite.CloneMessage
func (*TableSchemaColumn) CloneVT ¶
func (m *TableSchemaColumn) CloneVT() *TableSchemaColumn
func (*TableSchemaColumn) EqualMessageVT ¶
func (this *TableSchemaColumn) EqualMessageVT(thatMsg any) bool
func (*TableSchemaColumn) EqualVT ¶
func (this *TableSchemaColumn) EqualVT(that *TableSchemaColumn) bool
func (*TableSchemaColumn) GetAutoIncrement ¶
func (x *TableSchemaColumn) GetAutoIncrement() bool
func (*TableSchemaColumn) GetColumnType ¶
func (x *TableSchemaColumn) GetColumnType() string
func (*TableSchemaColumn) GetComment ¶
func (x *TableSchemaColumn) GetComment() string
func (*TableSchemaColumn) GetDefaultValueExpr ¶
func (x *TableSchemaColumn) GetDefaultValueExpr() string
func (*TableSchemaColumn) GetExtra ¶
func (x *TableSchemaColumn) GetExtra() string
func (*TableSchemaColumn) GetName ¶
func (x *TableSchemaColumn) GetName() string
func (*TableSchemaColumn) GetNullable ¶
func (x *TableSchemaColumn) GetNullable() bool
func (*TableSchemaColumn) GetPrimaryKey ¶
func (x *TableSchemaColumn) GetPrimaryKey() bool
func (*TableSchemaColumn) GetSource ¶
func (x *TableSchemaColumn) GetSource() string
func (*TableSchemaColumn) MarshalJSON ¶
func (x *TableSchemaColumn) MarshalJSON() ([]byte, error)
MarshalJSON marshals the TableSchemaColumn to JSON.
func (*TableSchemaColumn) MarshalProtoJSON ¶
func (x *TableSchemaColumn) MarshalProtoJSON(s *json.MarshalState)
MarshalProtoJSON marshals the TableSchemaColumn message to JSON.
func (*TableSchemaColumn) MarshalProtoText ¶
func (x *TableSchemaColumn) MarshalProtoText() string
func (*TableSchemaColumn) MarshalToSizedBufferVT ¶
func (m *TableSchemaColumn) MarshalToSizedBufferVT(dAtA []byte) (int, error)
func (*TableSchemaColumn) MarshalToVT ¶
func (m *TableSchemaColumn) MarshalToVT(dAtA []byte) (int, error)
func (*TableSchemaColumn) MarshalVT ¶
func (m *TableSchemaColumn) MarshalVT() (dAtA []byte, err error)
func (*TableSchemaColumn) ParseColumnType ¶
func (t *TableSchemaColumn) ParseColumnType() (sql.Type, error)
ParseColumnType parses the column type to sql type.
func (*TableSchemaColumn) ParseDefaultValueExpr ¶
func (t *TableSchemaColumn) ParseDefaultValueExpr(ctx *sql.Context) (*sql.ColumnDefaultValue, error)
ParseDefaultValueExpr parses the default value expression.
Returns nil if the field is empty. If ctx is nil, uses default context.
func (*TableSchemaColumn) ProtoMessage ¶
func (*TableSchemaColumn) ProtoMessage()
func (*TableSchemaColumn) Reset ¶
func (x *TableSchemaColumn) Reset()
func (*TableSchemaColumn) SizeVT ¶
func (m *TableSchemaColumn) SizeVT() (n int)
func (*TableSchemaColumn) String ¶
func (x *TableSchemaColumn) String() string
func (*TableSchemaColumn) ToSqlColumn ¶
ToSqlColumn converts the proto into a sql column.
Ctx is optional
func (*TableSchemaColumn) UnmarshalJSON ¶
func (x *TableSchemaColumn) UnmarshalJSON(b []byte) error
UnmarshalJSON unmarshals the TableSchemaColumn from JSON.
func (*TableSchemaColumn) UnmarshalProtoJSON ¶
func (x *TableSchemaColumn) UnmarshalProtoJSON(s *json.UnmarshalState)
UnmarshalProtoJSON unmarshals the TableSchemaColumn message from JSON.
func (*TableSchemaColumn) UnmarshalVT ¶
func (m *TableSchemaColumn) UnmarshalVT(dAtA []byte) error
func (*TableSchemaColumn) Validate ¶
func (t *TableSchemaColumn) Validate() error
Validate performs cursory validation of the table column.
type TableTimestamp ¶
type TableTimestamp struct {
// UnixSeconds is seconds since Unix epoch.
UnixSeconds int64 `protobuf:"varint,1,opt,name=unix_seconds,json=unixSeconds,proto3" json:"unixSeconds,omitempty"`
// Nanos is the nanosecond offset within UnixSeconds.
Nanos int32 `protobuf:"varint,2,opt,name=nanos,proto3" json:"nanos,omitempty"`
// contains filtered or unexported fields
}
TableTimestamp is a timestamp-like SQL value.
func (*TableTimestamp) CloneMessageVT ¶
func (m *TableTimestamp) CloneMessageVT() protobuf_go_lite.CloneMessage
func (*TableTimestamp) CloneVT ¶
func (m *TableTimestamp) CloneVT() *TableTimestamp
func (*TableTimestamp) EqualMessageVT ¶
func (this *TableTimestamp) EqualMessageVT(thatMsg any) bool
func (*TableTimestamp) EqualVT ¶
func (this *TableTimestamp) EqualVT(that *TableTimestamp) bool
func (*TableTimestamp) GetNanos ¶
func (x *TableTimestamp) GetNanos() int32
func (*TableTimestamp) GetUnixSeconds ¶
func (x *TableTimestamp) GetUnixSeconds() int64
func (*TableTimestamp) MarshalJSON ¶
func (x *TableTimestamp) MarshalJSON() ([]byte, error)
MarshalJSON marshals the TableTimestamp to JSON.
func (*TableTimestamp) MarshalProtoJSON ¶
func (x *TableTimestamp) MarshalProtoJSON(s *json.MarshalState)
MarshalProtoJSON marshals the TableTimestamp message to JSON.
func (*TableTimestamp) MarshalProtoText ¶
func (x *TableTimestamp) MarshalProtoText() string
func (*TableTimestamp) MarshalToSizedBufferVT ¶
func (m *TableTimestamp) MarshalToSizedBufferVT(dAtA []byte) (int, error)
func (*TableTimestamp) MarshalToVT ¶
func (m *TableTimestamp) MarshalToVT(dAtA []byte) (int, error)
func (*TableTimestamp) MarshalVT ¶
func (m *TableTimestamp) MarshalVT() (dAtA []byte, err error)
func (*TableTimestamp) ProtoMessage ¶
func (*TableTimestamp) ProtoMessage()
func (*TableTimestamp) Reset ¶
func (x *TableTimestamp) Reset()
func (*TableTimestamp) SizeVT ¶
func (m *TableTimestamp) SizeVT() (n int)
func (*TableTimestamp) String ¶
func (x *TableTimestamp) String() string
func (*TableTimestamp) UnmarshalJSON ¶
func (x *TableTimestamp) UnmarshalJSON(b []byte) error
UnmarshalJSON unmarshals the TableTimestamp from JSON.
func (*TableTimestamp) UnmarshalProtoJSON ¶
func (x *TableTimestamp) UnmarshalProtoJSON(s *json.UnmarshalState)
UnmarshalProtoJSON unmarshals the TableTimestamp message from JSON.
func (*TableTimestamp) UnmarshalVT ¶
func (m *TableTimestamp) UnmarshalVT(dAtA []byte) error
type Tx ¶
type Tx struct {
// contains filtered or unexported fields
}
Tx contains a transaction against the mysql data store.
func (*Tx) BuildDatabaseProvider ¶
BuildDatabaseProvider builds the database catalog from the available dbs.
func (*Tx) Commit ¶
Commit commits the transaction to storage. Can return an error to indicate tx failure.
func (*Tx) DatabaseCount ¶
DatabaseCount returns the number of databases in the tree.
func (*Tx) Discard ¶
func (t *Tx) Discard()
Discard cancels the transaction. If called after Commit, does nothing. Cannot return an error. Can be called unlimited times.
func (*Tx) GetBlockTransaction ¶
func (t *Tx) GetBlockTransaction() *block.Transaction
GetBlockTransaction returns the underlying block transaction.
Source Files
¶
- block-db-root-table.go
- block-db-root-tableset.go
- block-db-root.go
- block-root-db.go
- block-root-dbset.go
- block-root.go
- block-table-partition.go
- block-table-partitionset.go
- block-table-root.go
- block-table-row-columnset.go
- block-table-row.go
- database-table.go
- database.go
- db-ctx.go
- db.go
- driver-provider.go
- errors.go
- gorm.go
- mysql.go
- mysql.pb.go
- parse-column.go
- session.go
- sql-tx.go
- table-column.go
- table-editor.go
- table-partition-iter.go
- table-partition-row-iter.go
- table-partition.go
- table-row-key.go
- table-row.go
- table-schema-column.go
- table-schema.go
- table.go
- tx.go