offline

package
v0.0.4 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jan 7, 2022 License: Apache-2.0 Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type CSVSource added in v0.0.4

type CSVSource struct {
	Reader    *bufio.Reader
	Delimiter string
}

type CreateTableOpt added in v0.0.4

type CreateTableOpt struct {
	TableName string
	Entity    *types.Entity
	Features  types.FeatureList
	IsCDC     bool
}

type ExportOpt

type ExportOpt struct {
	SnapshotTable string
	EntityName    string
	Features      types.FeatureList
	Limit         *uint64
}

type ImportOpt

type ImportOpt struct {
	Entity            *types.Entity
	Features          types.FeatureList
	Header            []string
	Revision          *int64
	SnapshotTableName string
	Source            *CSVSource
	NoPK              bool // TODO: to import cdc data temporarily for testing
}

type JoinOneGroupOpt added in v0.0.3

type JoinOneGroupOpt struct {
	GroupName           string
	Category            types.Category
	Features            types.FeatureList
	RevisionRanges      []*RevisionRange
	Entity              types.Entity
	EntityRowsTableName string
	ValueNames          []string
}

type JoinOpt

type JoinOpt struct {
	Entity           types.Entity
	EntityRows       <-chan types.EntityRow
	FeatureMap       map[string]types.FeatureList
	RevisionRangeMap map[string][]*RevisionRange
	ValueNames       []string
}

type PushOpt added in v0.0.4

type PushOpt struct {
	GroupID      int
	Revision     int64
	EntityName   string
	FeatureNames []string
	Records      []types.StreamRecord
}

type RevisionRange added in v0.0.4

type RevisionRange struct {
	MinRevision   int64
	MaxRevision   int64
	SnapshotTable string
	CdcTable      string
}

type SnapshotOpt added in v0.0.4

type SnapshotOpt struct {
	Group        *types.Group
	Features     types.FeatureList
	Revision     int64
	PrevRevision int64
}

type Store

type Store interface {
	Join(ctx context.Context, opt JoinOpt) (*types.JoinResult, error)
	Export(ctx context.Context, opt ExportOpt) (<-chan types.ExportRecord, <-chan error)
	Import(ctx context.Context, opt ImportOpt) (int64, error)
	Push(ctx context.Context, opt PushOpt) error

	CreateTable(ctx context.Context, opt CreateTableOpt) error
	TableSchema(ctx context.Context, tableName string) (*types.DataTableSchema, error)
	Snapshot(ctx context.Context, opt SnapshotOpt) error

	Ping(ctx context.Context) error
	io.Closer
}

Directories

Path Synopsis
Package mock_offline is a generated GoMock package.
Package mock_offline is a generated GoMock package.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL