instance

package
v0.0.0-...-0caea15 Latest Latest
Warning

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

Go to latest
Published: Apr 30, 2024 License: PostgreSQL Imports: 26 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type EtcdMetadataBootstraper

type EtcdMetadataBootstraper struct {
	QdbAddr string
}

func (*EtcdMetadataBootstraper) InitializeMetadata

func (e *EtcdMetadataBootstraper) InitializeMetadata(ctx context.Context, r RouterInstance) error

InitializeMetadata implements RouterMetadataBootstraper.

type InitSQLMetadataBootstraper

type InitSQLMetadataBootstraper struct {
	InitSQLFIle string
}

func (*InitSQLMetadataBootstraper) InitializeMetadata

func (i *InitSQLMetadataBootstraper) InitializeMetadata(ctx context.Context, r RouterInstance) error

InitializeMetadata implements RouterMetadataBootstraper.

type InstanceImpl

type InstanceImpl struct {
	RuleRouter rulerouter.RuleRouter
	Qrouter    qrouter.QueryRouter
	AdmConsole console.Console
	Mgr        meta.EntityMgr
	Writer     workloadlog.WorkloadLog
	// contains filtered or unexported fields
}

func NewRouter

func NewRouter(ctx context.Context, rcfg *config.Router, ns string, persist bool) (*InstanceImpl, error)

func (*InstanceImpl) Addr

func (r *InstanceImpl) Addr() string

func (*InstanceImpl) Config

func (r *InstanceImpl) Config() *config.Router

func (*InstanceImpl) Console

func (r *InstanceImpl) Console() console.Console

Console implements RouterInstance.

func (*InstanceImpl) ID

func (r *InstanceImpl) ID() string

func (*InstanceImpl) Initialize

func (r *InstanceImpl) Initialize() bool

func (*InstanceImpl) Initialized

func (r *InstanceImpl) Initialized() bool

func (*InstanceImpl) Run

func (r *InstanceImpl) Run(ctx context.Context, listener net.Listener, pt port.RouterPortType) error

func (*InstanceImpl) RunAdm

func (r *InstanceImpl) RunAdm(ctx context.Context, listener net.Listener) error

type RouterInstance

type RouterInstance interface {
	Addr() string
	ID() string
	Initialized() bool
	Initialize() bool

	Console() console.Console
	Config() *config.Router
}

type RouterMetadataBootstraper

type RouterMetadataBootstraper interface {
	InitializeMetadata(ctx context.Context, r RouterInstance) error
}

func NewEtcdMetadataBootstraper

func NewEtcdMetadataBootstraper(QdbAddr string) RouterMetadataBootstraper

func NewInitSQLMetadataBootstraper

func NewInitSQLMetadataBootstraper(InitSQLFIle string) RouterMetadataBootstraper

Jump to

Keyboard shortcuts

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