eventdispatch

package
v1.0.0-alpha02 Latest Latest
Warning

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

Go to latest
Published: Dec 30, 2022 License: Apache-2.0 Imports: 8 Imported by: ? modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Index

Constants

This section is empty.

Variables

View Source
var ErrDispatch = coderr.NewCodeError(coderr.Internal, "event dispatch failed")

Functions

This section is empty.

Types

type CloseShardRequest

type CloseShardRequest struct {
	ShardID uint32
}

type CreateTableOnShardRequest

type CreateTableOnShardRequest struct {
	UpdateShardInfo      UpdateShardInfo
	TableInfo            cluster.TableInfo
	EncodedSchema        []byte
	Engine               string
	CreateIfNotExist     bool
	Options              map[string]string
	EncodedPartitionInfo []byte
}

type Dispatch

type Dispatch interface {
	OpenShard(context context.Context, address string, request OpenShardRequest) error
	CloseShard(context context.Context, address string, request CloseShardRequest) error
	CreateTableOnShard(context context.Context, address string, request CreateTableOnShardRequest) error
	DropTableOnShard(context context.Context, address string, request DropTableOnShardRequest) error
}

type DispatchImpl

type DispatchImpl struct {
	// contains filtered or unexported fields
}

func NewDispatchImpl

func NewDispatchImpl() *DispatchImpl

func (*DispatchImpl) CloseShard

func (d *DispatchImpl) CloseShard(ctx context.Context, addr string, request CloseShardRequest) error

func (*DispatchImpl) CreateTableOnShard

func (d *DispatchImpl) CreateTableOnShard(ctx context.Context, addr string, request CreateTableOnShardRequest) error

func (*DispatchImpl) DropTableOnShard

func (d *DispatchImpl) DropTableOnShard(ctx context.Context, addr string, request DropTableOnShardRequest) error

func (*DispatchImpl) OpenShard

func (d *DispatchImpl) OpenShard(ctx context.Context, addr string, request OpenShardRequest) error

type DropTableOnShardRequest

type DropTableOnShardRequest struct {
	UpdateShardInfo UpdateShardInfo
	TableInfo       cluster.TableInfo
}

type OpenShardRequest

type OpenShardRequest struct {
	Shard cluster.ShardInfo
}

type UpdateShardInfo

type UpdateShardInfo struct {
	CurrShardInfo cluster.ShardInfo
	PrevVersion   uint64
}

Jump to

Keyboard shortcuts

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