mds

package
v0.1.4-alpha.4 Latest Latest
Warning

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

Go to latest
Published: Jun 2, 2022 License: AGPL-3.0 Imports: 34 Imported by: 0

Documentation

Index

Constants

View Source
const FastpathBatchMaxSize = 100
View Source
const FastpathMaxConcurrency = 500
View Source
const FastpathMaxTxnConcurrency = 100
View Source
const LoginVersion = "v0.1.4-alpha.2"
View Source
const MaxMuxWidth = 64
View Source
const MaxPreAuthWebSocketIncomingMessageSize = 1024 * 100 // 100KiB
View Source
const MaxWebSocketIncomingMessageSize = 1024 * 1024 * 20 // 20MiB
View Source
const PingInterval = 500 * time.Millisecond

Variables

View Source
var RetryableFastpathError = errors.New("retryable fastpath error")

Functions

func CompileScript

func CompileScript(script string) (*goja.Program, error)

Types

type Fastpath

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

func NewFastpath

func NewFastpath(logger *zap.Logger, cluster *MdsCluster, ss subspace.Subspace, perm StorePermission) *Fastpath

func (*Fastpath) Handle

func (fp *Fastpath) Handle(req *protocol.Request, stop <-chan struct{}, xmit func(proto.Message) error, kill func())

type Mds

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

func NewMds

func NewMds(logger *zap.Logger, webData fs.FS) *Mds

func (*Mds) ReplicaReadTransactor

func (m *Mds) ReplicaReadTransactor() fdb.ReadTransactor

func (*Mds) Run

func (m *Mds) Run() error

type MdsCluster

type MdsCluster struct {
	RawConfig []byte
	// contains filtered or unexported fields
}

func NewMdsCluster

func NewMdsCluster(logger *zap.Logger, tempDir, clusterName, region string, cluster *protocol.Cluster) (*MdsCluster, error)

func (*MdsCluster) PrimaryTransactor

func (s *MdsCluster) PrimaryTransactor() fdb.Transactor

func (*MdsCluster) ReplicaReadTransactor

func (s *MdsCluster) ReplicaReadTransactor() fdb.ReadTransactor

type MdsConfig

type MdsConfig struct {
	RootStore RootStoreConfig `yaml:"rootStore"`
	Region    string
}

type MdsSession

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

func NewMdsSession

func NewMdsSession(logger *zap.Logger, cluster *MdsCluster, ss subspace.Subspace, perm StorePermission) *MdsSession

func (*MdsSession) Run

func (s *MdsSession) Run(ingress <-chan *protocol.Request, stop <-chan struct{}, xmit func(proto.Message) error, kill func())

type RootStoreConfig

type RootStoreConfig struct {
	Primary  string `yaml:"primary"`
	Replica  string `yaml:"replica"`
	Subspace string `yaml:"subspace"`
}

type StorePermission

type StorePermission int
const (
	StorePermissionDenied StorePermission = iota
	StorePermissionReadOnly
	StorePermissionReadWrite
)

func (StorePermission) String

func (p StorePermission) String() string

Jump to

Keyboard shortcuts

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