mirror of
https://github.com/dolthub/dolt.git
synced 2026-03-13 01:54:38 -05:00
[no-release-notes] Unique ids bump (#7067)
* [no-release-notes] Unique ids bump * bump
This commit is contained in:
committed by
GitHub
parent
b977298464
commit
de1e666cd0
@@ -59,7 +59,7 @@ require (
|
||||
github.com/cespare/xxhash v1.1.0
|
||||
github.com/creasty/defaults v1.6.0
|
||||
github.com/dolthub/flatbuffers/v23 v23.3.3-dh.2
|
||||
github.com/dolthub/go-mysql-server v0.17.1-0.20231128212821-dcb38e62c6af
|
||||
github.com/dolthub/go-mysql-server v0.17.1-0.20231201021351-97a2867b8225
|
||||
github.com/dolthub/swiss v0.1.0
|
||||
github.com/goccy/go-json v0.10.2
|
||||
github.com/google/shlex v0.0.0-20191202100458-e7afc7fbc510
|
||||
|
||||
@@ -181,8 +181,8 @@ github.com/dolthub/fslock v0.0.3 h1:iLMpUIvJKMKm92+N1fmHVdxJP5NdyDK5bK7z7Ba2s2U=
|
||||
github.com/dolthub/fslock v0.0.3/go.mod h1:QWql+P17oAAMLnL4HGB5tiovtDuAjdDTPbuqx7bYfa0=
|
||||
github.com/dolthub/go-icu-regex v0.0.0-20230524105445-af7e7991c97e h1:kPsT4a47cw1+y/N5SSCkma7FhAPw7KeGmD6c9PBZW9Y=
|
||||
github.com/dolthub/go-icu-regex v0.0.0-20230524105445-af7e7991c97e/go.mod h1:KPUcpx070QOfJK1gNe0zx4pA5sicIK1GMikIGLKC168=
|
||||
github.com/dolthub/go-mysql-server v0.17.1-0.20231128212821-dcb38e62c6af h1:HqF5xFLyLu3U2CZ2HvIv9sUqaJOwCN6EibSIQShQHEM=
|
||||
github.com/dolthub/go-mysql-server v0.17.1-0.20231128212821-dcb38e62c6af/go.mod h1:vXlRKS39WHav9N51VsfYphKhmSA2t5FkhHmW3BtwH5I=
|
||||
github.com/dolthub/go-mysql-server v0.17.1-0.20231201021351-97a2867b8225 h1:6+FqniHHZRWNfuXtIlvSLUWoZhJEixyWYcgSsPlT69U=
|
||||
github.com/dolthub/go-mysql-server v0.17.1-0.20231201021351-97a2867b8225/go.mod h1:vXlRKS39WHav9N51VsfYphKhmSA2t5FkhHmW3BtwH5I=
|
||||
github.com/dolthub/ishell v0.0.0-20221214210346-d7db0b066488 h1:0HHu0GWJH0N6a6keStrHhUAK5/o9LVfkh44pvsV4514=
|
||||
github.com/dolthub/ishell v0.0.0-20221214210346-d7db0b066488/go.mod h1:ehexgi1mPxRTk0Mok/pADALuHbvATulTh6gzr7NzZto=
|
||||
github.com/dolthub/jsonpath v0.0.2-0.20230525180605-8dc13778fd72 h1:NfWmngMi1CYUWU4Ix8wM+USEhjc+mhPlT9JUR/anvbQ=
|
||||
|
||||
@@ -45,6 +45,8 @@ type DiffStatTableFunction struct {
|
||||
dotCommitExpr sql.Expression
|
||||
tableNameExpr sql.Expression
|
||||
database sql.Database
|
||||
tabId sql.TableId
|
||||
colset sql.ColSet
|
||||
}
|
||||
|
||||
var diffStatTableSchema = sql.Schema{
|
||||
@@ -77,6 +79,26 @@ func (ds *DiffStatTableFunction) NewInstance(ctx *sql.Context, db sql.Database,
|
||||
return node, nil
|
||||
}
|
||||
|
||||
func (ds *DiffStatTableFunction) WithId(id sql.TableId) sql.TableIdNode {
|
||||
ret := *ds
|
||||
ret.tabId = id
|
||||
return &ret
|
||||
}
|
||||
|
||||
func (ds *DiffStatTableFunction) Id() sql.TableId {
|
||||
return ds.tabId
|
||||
}
|
||||
|
||||
func (ds *DiffStatTableFunction) WithColumns(set sql.ColSet) sql.TableIdNode {
|
||||
ret := *ds
|
||||
ds.colset = set
|
||||
return &ret
|
||||
}
|
||||
|
||||
func (ds *DiffStatTableFunction) Columns() sql.ColSet {
|
||||
return ds.colset
|
||||
}
|
||||
|
||||
func (ds *DiffStatTableFunction) DataLength(ctx *sql.Context) (uint64, error) {
|
||||
numBytesPerRow := schema.SchemaAvgLength(ds.Schema())
|
||||
numRows, _, err := ds.RowCount(ctx)
|
||||
|
||||
@@ -42,6 +42,8 @@ type DiffSummaryTableFunction struct {
|
||||
dotCommitExpr sql.Expression
|
||||
tableNameExpr sql.Expression
|
||||
database sql.Database
|
||||
tabId sql.TableId
|
||||
colset sql.ColSet
|
||||
}
|
||||
|
||||
var diffSummaryTableSchema = sql.Schema{
|
||||
@@ -67,6 +69,26 @@ func (ds *DiffSummaryTableFunction) NewInstance(ctx *sql.Context, db sql.Databas
|
||||
return node, nil
|
||||
}
|
||||
|
||||
func (ds *DiffSummaryTableFunction) WithId(id sql.TableId) sql.TableIdNode {
|
||||
ret := *ds
|
||||
ret.tabId = id
|
||||
return &ret
|
||||
}
|
||||
|
||||
func (ds *DiffSummaryTableFunction) Id() sql.TableId {
|
||||
return ds.tabId
|
||||
}
|
||||
|
||||
func (ds *DiffSummaryTableFunction) WithColumns(set sql.ColSet) sql.TableIdNode {
|
||||
ret := *ds
|
||||
ret.colset = set
|
||||
return &ret
|
||||
}
|
||||
|
||||
func (ds *DiffSummaryTableFunction) Columns() sql.ColSet {
|
||||
return ds.colset
|
||||
}
|
||||
|
||||
func (ds *DiffSummaryTableFunction) DataLength(ctx *sql.Context) (uint64, error) {
|
||||
numBytesPerRow := schema.SchemaAvgLength(ds.Schema())
|
||||
numRows, _, err := ds.RowCount(ctx)
|
||||
|
||||
@@ -54,6 +54,29 @@ type DiffTableFunction struct {
|
||||
tableDelta diff.TableDelta
|
||||
fromDate *types.Timestamp
|
||||
toDate *types.Timestamp
|
||||
|
||||
tabId sql.TableId
|
||||
colset sql.ColSet
|
||||
}
|
||||
|
||||
func (dtf *DiffTableFunction) WithId(id sql.TableId) sql.TableIdNode {
|
||||
ret := *dtf
|
||||
ret.tabId = id
|
||||
return &ret
|
||||
}
|
||||
|
||||
func (dtf *DiffTableFunction) Id() sql.TableId {
|
||||
return dtf.tabId
|
||||
}
|
||||
|
||||
func (dtf *DiffTableFunction) WithColumns(set sql.ColSet) sql.TableIdNode {
|
||||
ret := *dtf
|
||||
ret.colset = set
|
||||
return &ret
|
||||
}
|
||||
|
||||
func (dtf *DiffTableFunction) Columns() sql.ColSet {
|
||||
return dtf.colset
|
||||
}
|
||||
|
||||
// NewInstance creates a new instance of TableFunction interface
|
||||
|
||||
@@ -48,6 +48,9 @@ type LogTableFunction struct {
|
||||
showParents bool
|
||||
decoration string
|
||||
|
||||
tabId sql.TableId
|
||||
colset sql.ColSet
|
||||
|
||||
database sql.Database
|
||||
}
|
||||
|
||||
@@ -74,6 +77,26 @@ func (ltf *LogTableFunction) NewInstance(ctx *sql.Context, db sql.Database, expr
|
||||
return node, nil
|
||||
}
|
||||
|
||||
func (ltf *LogTableFunction) WithId(id sql.TableId) sql.TableIdNode {
|
||||
ret := *ltf
|
||||
ret.tabId = id
|
||||
return &ret
|
||||
}
|
||||
|
||||
func (ltf *LogTableFunction) Id() sql.TableId {
|
||||
return ltf.tabId
|
||||
}
|
||||
|
||||
func (ltf *LogTableFunction) WithColumns(set sql.ColSet) sql.TableIdNode {
|
||||
ret := *ltf
|
||||
ret.colset = set
|
||||
return &ret
|
||||
}
|
||||
|
||||
func (ltf *LogTableFunction) Columns() sql.ColSet {
|
||||
return ltf.colset
|
||||
}
|
||||
|
||||
// Database implements the sql.Databaser interface
|
||||
func (ltf *LogTableFunction) Database() sql.Database {
|
||||
return ltf.database
|
||||
|
||||
@@ -74,6 +74,28 @@ type PatchTableFunction struct {
|
||||
dotCommitExpr sql.Expression
|
||||
tableNameExpr sql.Expression
|
||||
database sql.Database
|
||||
tabId sql.TableId
|
||||
colset sql.ColSet
|
||||
}
|
||||
|
||||
func (p *PatchTableFunction) WithId(id sql.TableId) sql.TableIdNode {
|
||||
ret := *p
|
||||
ret.tabId = id
|
||||
return &ret
|
||||
}
|
||||
|
||||
func (p *PatchTableFunction) Id() sql.TableId {
|
||||
return p.tabId
|
||||
}
|
||||
|
||||
func (p *PatchTableFunction) WithColumns(set sql.ColSet) sql.TableIdNode {
|
||||
ret := *p
|
||||
ret.colset = set
|
||||
return &ret
|
||||
}
|
||||
|
||||
func (p *PatchTableFunction) Columns() sql.ColSet {
|
||||
return p.colset
|
||||
}
|
||||
|
||||
func (p *PatchTableFunction) DataLength(ctx *sql.Context) (uint64, error) {
|
||||
|
||||
@@ -45,6 +45,29 @@ type QueryDiffTableFunction struct {
|
||||
rowIter2 sql.RowIter
|
||||
schema1 sql.Schema
|
||||
schema2 sql.Schema
|
||||
|
||||
tabId sql.TableId
|
||||
colset sql.ColSet
|
||||
}
|
||||
|
||||
func (tf *QueryDiffTableFunction) WithId(id sql.TableId) sql.TableIdNode {
|
||||
ret := *tf
|
||||
ret.tabId = id
|
||||
return &ret
|
||||
}
|
||||
|
||||
func (tf *QueryDiffTableFunction) Id() sql.TableId {
|
||||
return tf.tabId
|
||||
}
|
||||
|
||||
func (tf *QueryDiffTableFunction) WithColumns(set sql.ColSet) sql.TableIdNode {
|
||||
ret := *tf
|
||||
ret.colset = set
|
||||
return &ret
|
||||
}
|
||||
|
||||
func (tf *QueryDiffTableFunction) Columns() sql.ColSet {
|
||||
return tf.colset
|
||||
}
|
||||
|
||||
// NewInstance creates a new instance of TableFunction interface
|
||||
|
||||
@@ -60,6 +60,9 @@ type SchemaDiffTableFunction struct {
|
||||
tableNameExpr sql.Expression
|
||||
|
||||
database sql.Database
|
||||
|
||||
tabId sql.TableId
|
||||
colset sql.ColSet
|
||||
}
|
||||
|
||||
var schemaDiffTableSchema = sql.Schema{
|
||||
@@ -84,6 +87,25 @@ func (ds *SchemaDiffTableFunction) NewInstance(ctx *sql.Context, db sql.Database
|
||||
return node, nil
|
||||
}
|
||||
|
||||
func (ds *SchemaDiffTableFunction) WithId(id sql.TableId) sql.TableIdNode {
|
||||
//TODO implement me
|
||||
panic("implement me")
|
||||
}
|
||||
|
||||
func (ds *SchemaDiffTableFunction) Id() sql.TableId {
|
||||
return ds.tabId
|
||||
}
|
||||
|
||||
func (ds *SchemaDiffTableFunction) WithColumns(set sql.ColSet) sql.TableIdNode {
|
||||
ret := *ds
|
||||
ds.colset = set
|
||||
return &ret
|
||||
}
|
||||
|
||||
func (ds *SchemaDiffTableFunction) Columns() sql.ColSet {
|
||||
return ds.colset
|
||||
}
|
||||
|
||||
func (ds *SchemaDiffTableFunction) DataLength(ctx *sql.Context) (uint64, error) {
|
||||
numBytesPerRow := schema.SchemaAvgLength(ds.Schema())
|
||||
numRows, _, err := ds.RowCount(ctx)
|
||||
|
||||
@@ -1984,7 +1984,7 @@ func TestBrokenSystemTableQueries(t *testing.T) {
|
||||
}
|
||||
|
||||
func TestHistorySystemTable(t *testing.T) {
|
||||
harness := newDoltHarness(t).WithParallelism(2)
|
||||
harness := newDoltHarness(t).WithParallelism(1)
|
||||
defer harness.Close()
|
||||
harness.Setup(setup.MydbData)
|
||||
for _, test := range HistorySystemTableScriptTests {
|
||||
|
||||
@@ -419,6 +419,7 @@ func (ht *HistoryTable) Collation() sql.CollationID {
|
||||
|
||||
// Partitions returns a PartitionIter which will be used in getting partitions each of which is used to create RowIter.
|
||||
func (ht *HistoryTable) Partitions(ctx *sql.Context) (sql.PartitionIter, error) {
|
||||
// TODO reset ht.cmItr on close
|
||||
iter, err := ht.filterIter(ctx, ht.cmItr)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
@@ -460,7 +461,8 @@ func (cp commitPartitioner) Next(ctx *sql.Context) (sql.Partition, error) {
|
||||
}
|
||||
|
||||
// Close closes the partitioner
|
||||
func (cp commitPartitioner) Close(*sql.Context) error {
|
||||
func (cp commitPartitioner) Close(ctx *sql.Context) error {
|
||||
cp.cmItr.Reset(ctx)
|
||||
return nil
|
||||
}
|
||||
|
||||
|
||||
@@ -32,6 +32,8 @@ type ReflogTableFunction struct {
|
||||
ctx *sql.Context
|
||||
database sql.Database
|
||||
refExpr sql.Expression
|
||||
tabId sql.TableId
|
||||
colset sql.ColSet
|
||||
}
|
||||
|
||||
var _ sql.TableFunction = (*ReflogTableFunction)(nil)
|
||||
@@ -58,6 +60,26 @@ func (rltf *ReflogTableFunction) NewInstance(ctx *sql.Context, database sql.Data
|
||||
return node, nil
|
||||
}
|
||||
|
||||
func (rltf *ReflogTableFunction) WithId(id sql.TableId) sql.TableIdNode {
|
||||
ret := *rltf
|
||||
ret.tabId = id
|
||||
return &ret
|
||||
}
|
||||
|
||||
func (rltf *ReflogTableFunction) Id() sql.TableId {
|
||||
return rltf.tabId
|
||||
}
|
||||
|
||||
func (rltf *ReflogTableFunction) WithColumns(set sql.ColSet) sql.TableIdNode {
|
||||
ret := *rltf
|
||||
ret.colset = set
|
||||
return &ret
|
||||
}
|
||||
|
||||
func (rltf *ReflogTableFunction) Columns() sql.ColSet {
|
||||
return rltf.colset
|
||||
}
|
||||
|
||||
func (rltf *ReflogTableFunction) RowIter(ctx *sql.Context, row sql.Row) (sql.RowIter, error) {
|
||||
sqlDb, ok := rltf.database.(dsess.SqlDatabase)
|
||||
if !ok {
|
||||
|
||||
Reference in New Issue
Block a user