full

package
v0.21.0-arabica Latest Latest
Warning

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

Go to latest
Published: Jan 20, 2025 License: Apache-2.0 Imports: 14 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var ErrDisallowRevertToArchival = errors.New(
	"node has been run with pruner enabled before, it is not safe to convert to an archival" +
		"Run with --experimental-pruning enabled or consider re-initializing the store")

ErrDisallowRevertToArchival is returned when a node has been run with pruner enabled before and launching it with archival mode.

Functions

func ConvertFromArchivalToPruned

func ConvertFromArchivalToPruned(ctx context.Context, ds datastore.Datastore, isArchival bool) (bool, error)

ConvertFromArchivalToPruned ensures that a node has not been run with pruning enabled before cannot revert to archival mode. It returns true only if the node is converting to pruned mode for the first time.

Types

type Option

type Option func(*params)

Option is a function that configures light availability Parameters

func WithArchivalMode

func WithArchivalMode() Option

WithArchivalMode is a functional option to tell the full availability implementation that the node wants to sync *all* blocks, not just those within the sampling window.

type ShareAvailability

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

ShareAvailability implements share.Availability using the full data square recovery technique. It is considered "full" because it is required to download enough shares to fully reconstruct the data square.

func NewShareAvailability

func NewShareAvailability(
	store *store.Store,
	getter shwap.Getter,
	opts ...Option,
) *ShareAvailability

NewShareAvailability creates a new full ShareAvailability.

func (*ShareAvailability) Prune

func (*ShareAvailability) SharesAvailable

func (fa *ShareAvailability) SharesAvailable(ctx context.Context, header *header.ExtendedHeader) error

SharesAvailable reconstructs the data committed to the given Root by requesting enough Shares from the network.

Jump to

Keyboard shortcuts

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