repo

package
v0.3.1-0...-ee1233d Latest Latest
Warning

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

Go to latest
Published: Mar 15, 2024 License: MIT Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	ErrNoDB = errors.Validation.NewWithKeyAndDetail("ERR_NO_DB", "no db")
)

Functions

This section is empty.

Types

type BlobHashRepository

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

func NewBlobHashRepository

func NewBlobHashRepository(db DB) (*BlobHashRepository, error)

func (*BlobHashRepository) DeleteAllAfterBlockID

func (r *BlobHashRepository) DeleteAllAfterBlockID(blockID uint64) error

DeleteAllAfterBlockID is used when a reorg is detected

func (*BlobHashRepository) FindLatestBlockID

func (r *BlobHashRepository) FindLatestBlockID() (uint64, error)

func (*BlobHashRepository) FirstByBlobHash

func (r *BlobHashRepository) FirstByBlobHash(blobHash string) (*blobstorage.BlobHash, error)

func (*BlobHashRepository) Save

type DB

type DB interface {
	DB() (*sql.DB, error)
	GormDB() *gorm.DB
}

Jump to

Keyboard shortcuts

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