Documentation
¶
Index ¶
Constants ¶
View Source
const DefaultBatchSize = 1000
Variables ¶
This section is empty.
Functions ¶
func ValidateConfig ¶
ValidateConfig validates the base backup configuration
Types ¶
type Config ¶
type Config struct { ToBlock *uint64 // the right bound for the block range; latest if not specified FromBlock uint64 // the left bound for the block range Watch bool // flag indicating if incoming tx data should be backed up SkipFailedTx bool // flag indicating if failed txs should be ignored }
Config is the base chain backup configuration
func DefaultConfig ¶
func DefaultConfig() Config
DefaultConfig returns the default backup configuration
type Option ¶
type Option func(s *Service)
func WithBatchSize ¶ added in v0.5.0
WithBatchSize specifies the number of requests to batch
func WithLogger ¶
WithLogger specifies the logger for the backup service
func WithSkipFailedTxs ¶ added in v0.5.0
WithSkipFailedTxs specifies if failed txs should be backed up
type Service ¶
type Service struct {
// contains filtered or unexported fields
}
Service is the chain backup service
func NewService ¶
NewService creates a new backup service
Click to show internal directories.
Click to hide internal directories.