consensus

package
v0.2.0 Latest Latest
Warning

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

Go to latest
Published: Oct 22, 2025 License: GPL-3.0 Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Client

type Client interface {
	GetSyncStatus(ctx context.Context) (*SyncStatus, error)
	Name() string
}

Client defines the interface for consensus layer operations

func NewClient

func NewClient(log logrus.FieldLogger, name string, endpoint string) Client

NewClient creates a new consensus client

type NodeHealth

type NodeHealth struct {
	IsHealthy bool
	Status    string
}

NodeHealth represents the health status of a consensus node

type SyncStatus

type SyncStatus struct {
	HeadSlot     string `json:"head_slot"`
	SyncDistance string `json:"sync_distance"`
	IsSyncing    bool   `json:"is_syncing"`
	IsOptimistic bool   `json:"is_optimistic"`
	ElOffline    bool   `json:"el_offline"`
}

SyncStatus represents the sync status of the consensus client

Jump to

Keyboard shortcuts

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