types

package
v12.0.0-rc6 Latest Latest
Warning

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

Go to latest
Published: Nov 20, 2024 License: Apache-2.0 Imports: 6 Imported by: 0

Documentation

Index

Constants

View Source
const (
	ModuleName = "plan"
)

Variables

View Source
var (
	ErrorInvalidMessage = sdkerrors.Register(ModuleName, 101, "invalid message")

	ErrorDuplicateNode     = sdkerrors.Register(ModuleName, 201, "duplicate node")
	ErrorInvalidNodeStatus = sdkerrors.Register(ModuleName, 202, "invalid node status")
	ErrorLeaseNotFound     = sdkerrors.Register(ModuleName, 203, "lease not found")
	ErrorNodeNotFound      = sdkerrors.Register(ModuleName, 204, "node not found")
	ErrorPlanNotFound      = sdkerrors.Register(ModuleName, 205, "plan not found")
	ErrorProviderNotFound  = sdkerrors.Register(ModuleName, 206, "provider not found")
	ErrorUnauthorized      = sdkerrors.Register(ModuleName, 207, "unauthorized")
)
View Source
var (
	CountKey = []byte{0x00}

	PlanKeyPrefix            = []byte{0x10}
	ActivePlanKeyPrefix      = append(PlanKeyPrefix, 0x01)
	InactivePlanKeyPrefix    = append(PlanKeyPrefix, 0x02)
	PlanForNodeKeyPrefix     = []byte{0x11}
	PlanForProviderKeyPrefix = []byte{0x12}
)

Functions

func ActivePlanKey

func ActivePlanKey(id uint64) []byte

func GetPlanForNodeByProviderKeyPrefix

func GetPlanForNodeByProviderKeyPrefix(nodeAddr base.NodeAddress, provAddr base.ProvAddress) []byte

func GetPlanForNodeKeyPrefix

func GetPlanForNodeKeyPrefix(addr base.NodeAddress) []byte

func GetPlanForProviderKeyPrefix

func GetPlanForProviderKeyPrefix(addr base.ProvAddress) []byte

func IDFromPlanForNodeByProviderKey

func IDFromPlanForNodeByProviderKey(key []byte) uint64

func IDFromPlanForProviderKey

func IDFromPlanForProviderKey(key []byte) uint64

func InactivePlanKey

func InactivePlanKey(id uint64) []byte

func NewErrorDuplicateNodeForPlan

func NewErrorDuplicateNodeForPlan(id uint64, addr base.NodeAddress) error

func NewErrorInvalidNodeStatus

func NewErrorInvalidNodeStatus(addr base.NodeAddress, status v1base.Status) error

func NewErrorLeaseNotFound

func NewErrorLeaseNotFound(nodeAddr base.NodeAddress, provAddr base.ProvAddress) error

func NewErrorNodeForPlanNotFound

func NewErrorNodeForPlanNotFound(id uint64, addr base.NodeAddress) error

func NewErrorNodeNotFound

func NewErrorNodeNotFound(addr base.NodeAddress) error

func NewErrorPlanNotFound

func NewErrorPlanNotFound(id uint64) error

func NewErrorProviderNotFound

func NewErrorProviderNotFound(addr base.ProvAddress) error

func NewErrorUnauthorized

func NewErrorUnauthorized(addr string) error

func PlanForNodeByProviderKey

func PlanForNodeByProviderKey(nodeAddr base.NodeAddress, provAddr base.ProvAddress, id uint64) []byte

func PlanForProviderKey

func PlanForProviderKey(addr base.ProvAddress, id uint64) []byte

Types

This section is empty.

Directories

Path Synopsis
Package v1 is a reverse proxy.
Package v1 is a reverse proxy.
Package v2 is a reverse proxy.
Package v2 is a reverse proxy.
Package v3 is a reverse proxy.
Package v3 is a reverse proxy.

Jump to

Keyboard shortcuts

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