Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type AppOptions ¶
type AppOptions interface {
Get(string) interface{}
}
AppOptions is an interface that provides the ability to retrieve options from the application.
type BeaconKitRuntime ¶
type BeaconKitRuntime struct {
// contains filtered or unexported fields
}
BeaconKitRuntime is a struct that holds the service registry.
func NewBeaconKitRuntime ¶
func NewBeaconKitRuntime( opts ...Option, ) (*BeaconKitRuntime, error)
NewBeaconKitRuntime creates a new BeaconKitRuntime and applies the provided options.
func NewDefaultBeaconKitRuntime ¶
func NewDefaultBeaconKitRuntime( cfg *config.Config, signer core.BLSSigner, jwtSecret *jwt.Secret, kzgTrustedSetup *gokzg4844.JSONTrustedSetup, bsb BeaconStorageBackend, logger log.Logger, ) (*BeaconKitRuntime, error)
NewDefaultBeaconKitRuntime creates a new BeaconKitRuntime with the default services.
func (*BeaconKitRuntime) BuildABCIComponents ¶
func (r *BeaconKitRuntime) BuildABCIComponents( nextPrepare sdk.PrepareProposalHandler, nextProcess sdk.ProcessProposalHandler, ) ( sdk.PrepareProposalHandler, sdk.ProcessProposalHandler, sdk.PreBlocker, )
BuildABCIComponents returns the ABCI components for the beacon runtime.
func (*BeaconKitRuntime) StartServices ¶
func (r *BeaconKitRuntime) StartServices( ctx context.Context, )
StartServices starts the services.
type BeaconStorageBackend ¶
type BeaconStorageBackend interface { AvailabilityStore(ctx context.Context) core.AvailabilityStore BeaconState(ctx context.Context) state.BeaconState }
BeaconStorageBackend is an interface that provides the beacon state to the runtime.
type Option ¶
type Option func(*BeaconKitRuntime) error
Option is a function that modifies the BeaconKitRuntime.
func WithBeaconStorageBackend ¶
func WithBeaconStorageBackend(fscp BeaconStorageBackend) Option
WithBeaconStorageBackend sets the BeaconStorageBackend of the BeaconKitRuntime.
func WithConfig ¶
WithConfig sets the configuration of the BeaconKitRuntime.
func WithLogger ¶
WithLogger sets the logger of the BeaconKitRuntime.
func WithServiceRegistry ¶
WithServiceRegistry sets the service registry of the BeaconKitRuntime.
type Service ¶
type Service interface { // Start spawns any goroutines required by the service. Start(ctx context.Context) // Status returns error if the service is not considered healthy. Status() error }
Service is a struct that can be registered into a ServiceRegistry for easy dependency management.