node

package
v1.2.1 Latest Latest
Warning

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

Go to latest
Published: Jun 9, 2021 License: GPL-3.0 Imports: 12 Imported by: 0

Documentation

Index

Constants

View Source
const AccStateCheckpointsKey = "erd_num_accounts_state_checkpoints"

AccStateCheckpointsKey is used as a key for the number of account state checkpoints in the api response

View Source
const PeerStateCheckpointsKey = "erd_num_peer_state_checkpoints"

PeerStateCheckpointsKey is used as a key for the number of peer state checkpoints in the api response

Variables

This section is empty.

Functions

func HeartbeatStatus

func HeartbeatStatus(c *gin.Context)

HeartbeatStatus respond with the heartbeat status of the node

func P2pStatusMetrics

func P2pStatusMetrics(c *gin.Context)

P2pStatusMetrics returns the node's p2p statistics exported by a StatusMetricsHandler

func PeerInfo added in v1.0.130

func PeerInfo(c *gin.Context)

PeerInfo returns the information of a provided p2p peer ID

func PrometheusMetrics added in v1.0.147

func PrometheusMetrics(c *gin.Context)

PrometheusMetrics is the endpoint which will return the data in the way that prometheus expects them

func QueryDebug added in v1.0.110

func QueryDebug(c *gin.Context)

QueryDebug returns the debug information after the query has been interpreted

func Routes

func Routes(router *wrapper.RouterWrapper)

Routes defines node related routes

func Statistics

func Statistics(c *gin.Context)

Statistics returns the blockchain statistics

func StatusMetrics

func StatusMetrics(c *gin.Context)

StatusMetrics returns the node statistics exported by an StatusMetricsHandler without p2p statistics

Types

type FacadeHandler

type FacadeHandler interface {
	GetHeartbeats() ([]data.PubKeyHeartbeat, error)
	TpsBenchmark() statistics.TPSBenchmark
	StatusMetrics() external.StatusMetricsHandler
	GetQueryHandler(name string) (debug.QueryHandler, error)
	GetPeerInfo(pid string) ([]core.QueryP2PPeerInfo, error)
	GetNumCheckpointsFromAccountState() uint32
	GetNumCheckpointsFromPeerState() uint32
	IsInterfaceNil() bool
}

FacadeHandler interface defines methods that can be used by the gin webserver

type QueryDebugRequest added in v1.0.110

type QueryDebugRequest struct {
	Name   string `form:"name" json:"name"`
	Search string `form:"search" json:"search"`
}

QueryDebugRequest represents the structure on which user input for querying a debug info will validate against

Jump to

Keyboard shortcuts

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