common

package
v0.29.6 Latest Latest
Warning

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

Go to latest
Published: Jan 19, 2023 License: AGPL-3.0 Imports: 19 Imported by: 0

Documentation

Index

Constants

View Source
const (
	FlowID getIdentityRequestType = iota
	PeerID
)
View Source
const (
	ID requestType = iota
	Height
	Final
	Sealed
)

Variables

This section is empty.

Functions

func NewGetIdentityCommand

func NewGetIdentityCommand(idProvider module.IdentityProvider) commands.AdminCommand

func NewReadProtocolStateBlocksCommand

func NewReadProtocolStateBlocksCommand(state protocol.State, storage storage.Blocks) commands.AdminCommand

Types

type GetConfigCommand

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

GetConfigCommand is an admin command which retrieves the current value of a dynamically updatable config.

func NewGetConfigCommand

func NewGetConfigCommand(configs *updatable_configs.Manager) *GetConfigCommand

func (*GetConfigCommand) Handler

func (s *GetConfigCommand) Handler(_ context.Context, req *admin.CommandRequest) (interface{}, error)

func (*GetConfigCommand) Validator

func (s *GetConfigCommand) Validator(req *admin.CommandRequest) error

Validator validates the request. Returns admin.InvalidAdminReqError for invalid/malformed requests.

type GetIdentityCommand

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

func (*GetIdentityCommand) Handler

func (r *GetIdentityCommand) Handler(ctx context.Context, req *admin.CommandRequest) (interface{}, error)

func (*GetIdentityCommand) Validator

func (r *GetIdentityCommand) Validator(req *admin.CommandRequest) error

Validator validates the request. Returns admin.InvalidAdminReqError for invalid/malformed requests.

type ListConfigCommand

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

ListConfigCommand is an admin command which lists all config fields which may by dynamically modified via admin command.

func NewListConfigCommand

func NewListConfigCommand(configs *updatable_configs.Manager) *ListConfigCommand

func (*ListConfigCommand) Handler

func (s *ListConfigCommand) Handler(_ context.Context, _ *admin.CommandRequest) (interface{}, error)

func (*ListConfigCommand) Validator

func (s *ListConfigCommand) Validator(req *admin.CommandRequest) error

type ReadProtocolStateBlocksCommand

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

func (*ReadProtocolStateBlocksCommand) Handler

func (r *ReadProtocolStateBlocksCommand) Handler(_ context.Context, req *admin.CommandRequest) (interface{}, error)

func (*ReadProtocolStateBlocksCommand) Validator

Validator validates the request. Returns admin.InvalidAdminReqError for invalid/malformed requests.

type SetConfigCommand

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

SetConfigCommand is an admin command which enables setting any config field which has registered as dynamically updatable with the config Manager.

func NewSetConfigCommand

func NewSetConfigCommand(configs *updatable_configs.Manager) *SetConfigCommand

func (*SetConfigCommand) Handler

func (s *SetConfigCommand) Handler(_ context.Context, req *admin.CommandRequest) (interface{}, error)

func (*SetConfigCommand) Validator

func (s *SetConfigCommand) Validator(req *admin.CommandRequest) error

Validator validates the request. Returns admin.InvalidAdminReqError for invalid/malformed requests.

type SetGologLevelCommand

type SetGologLevelCommand struct{}

func (*SetGologLevelCommand) Handler

func (s *SetGologLevelCommand) Handler(ctx context.Context, req *admin.CommandRequest) (interface{}, error)

func (*SetGologLevelCommand) Validator

func (s *SetGologLevelCommand) Validator(req *admin.CommandRequest) error

type SetLogLevelCommand

type SetLogLevelCommand struct{}

func (*SetLogLevelCommand) Handler

func (s *SetLogLevelCommand) Handler(_ context.Context, req *admin.CommandRequest) (interface{}, error)

func (*SetLogLevelCommand) Validator

func (s *SetLogLevelCommand) Validator(req *admin.CommandRequest) error

Validator validates the request. Returns admin.InvalidAdminReqError for invalid/malformed requests.

Jump to

Keyboard shortcuts

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