rangedloop

package
v0.0.0-...-e477e18 Latest Latest
Warning

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

Go to latest
Published: May 3, 2024 License: AGPL-3.0 Imports: 23 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var Error = errs.Class("rs")

Functions

func Run

func Run(satelliteConn *pgx.Conn, loop RangedLoop) error

Types

type Bucket

type Bucket struct {
	ID   []byte
	Name []byte
}

type Count

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

func NewCount

func NewCount() *Count

func (*Count) Finish

func (c *Count) Finish(ctx context.Context) error

func (*Count) Fork

func (c *Count) Fork(ctx context.Context) (rangedloop.Partial, error)

func (*Count) Join

func (c *Count) Join(ctx context.Context, partial rangedloop.Partial) error

func (*Count) Process

func (c *Count) Process(ctx context.Context, segments []rangedloop.Segment) error

func (*Count) Start

func (c *Count) Start(ctx context.Context, time time.Time) error

func (*Count) Stats

func (c *Count) Stats(cb func(key monkit.SeriesKey, field string, val float64))

type FullScan

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

func NewFullScan

func NewFullScan(db *metabase.DB, scanType string) *FullScan

func (*FullScan) CreateRanges

func (f *FullScan) CreateRanges(nRanges int, batchSize int) ([]rangedloop.SegmentProvider, error)

type FullSelectedNode

type FullSelectedNode struct {
	nodeselection.SelectedNode
	Email  string
	Wallet string
}

func GetParticipatingNodes

func GetParticipatingNodes(ctx context.Context, db tagsql.DB) (records []*FullSelectedNode, err error)

GetParticipatingNodes returns all known participating nodes (this includes all known nodes excluding nodes that have been disqualified or gracefully exited).

type Node

type Node struct {
	NodeID    storj.NodeID
	Address   string
	Email     string
	Country   location.CountryCode
	LastNet   string
	UpdatedAt time.Time
}

type Object

type Object struct {
	StreamID     []byte
	PieceAliases []byte
	ObjectKey    []byte
}

type Project

type Project struct {
	ID   []byte
	Name string
}

type RangedLoop

type RangedLoop struct {
	ScanType  string
	ScanParam int
}

func (RangedLoop) Run

func (r RangedLoop) Run() error

type SQLProvider

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

func (*SQLProvider) Iterate

func (s *SQLProvider) Iterate(ctx context.Context, fn func([]rangedloop.Segment) error) error

func (*SQLProvider) Range

func (s *SQLProvider) Range() rangedloop.UUIDRange

type Segment

type Segment struct {
	StreamID  []byte
	NodeAlias []byte
	Position  int
	Placement int
}

Jump to

Keyboard shortcuts

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