Documentation ¶
Index ¶
- func ExtractMinerPreCommitEvents(extState extraction.State, preCommits *miner.PreCommitChanges) minermodel.MinerSectorEventList
- func ExtractMinerSectorEvents(extState extraction.State, sectors *miner.SectorChanges, ...) minermodel.MinerSectorEventList
- func ExtractMinerSectorStateEvents(extState extraction.State, events *SectorStateEvents) (minermodel.MinerSectorEventList, error)
- func ExtractSectorDealsModel(ctx context.Context, ec extraction.State) (minermodel.MinerSectorDealList, error)
- func ExtractSectorEvents(extState extraction.State, sectorChanges *miner.SectorChanges, ...) (minermodel.MinerSectorEventList, error)
- type BeneficiaryExtractor
- type DeadlineInfoExtractor
- type FeeDebtExtractor
- type InfoExtractor
- type LockedFundsExtractor
- type MinerStateExtractionContext
- type PoStExtractor
- type PreCommitInfoExtractorV8
- type PreCommitInfoExtractorV9
- type SectorDealsExtractor
- type SectorEventsExtractor
- type SectorInfoExtractor
- type SectorStateEvents
- type SectorStates
- type V7SectorInfoExtractor
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func ExtractMinerPreCommitEvents ¶ added in v0.11.0
func ExtractMinerPreCommitEvents(extState extraction.State, preCommits *miner.PreCommitChanges) minermodel.MinerSectorEventList
ExtractMinerPreCommitEvents transforms the added PreCommits from `preCommits` to a MinerSectorEventList.
func ExtractMinerSectorEvents ¶ added in v0.11.0
func ExtractMinerSectorEvents(extState extraction.State, sectors *miner.SectorChanges, sectorAddedIDs map[uint64]bool) minermodel.MinerSectorEventList
ExtractMinerSectorEvents transforms the added, extended and snapped sectors from `sectors` to a MinerSectorEventList.
func ExtractMinerSectorStateEvents ¶ added in v0.12.0
func ExtractMinerSectorStateEvents(extState extraction.State, events *SectorStateEvents) (minermodel.MinerSectorEventList, error)
ExtractMinerSectorStateEvents transforms the removed, recovering, faulted, and recovered sectors from `events` to a MinerSectorEventList.
func ExtractSectorDealsModel ¶ added in v0.10.1
func ExtractSectorDealsModel(ctx context.Context, ec extraction.State) (minermodel.MinerSectorDealList, error)
func ExtractSectorEvents ¶ added in v0.11.0
func ExtractSectorEvents(extState extraction.State, sectorChanges *miner.SectorChanges, preCommitChanges *miner.PreCommitChanges, sectorStateChanges *SectorStateEvents, sectorAddedIDs map[uint64]bool) (minermodel.MinerSectorEventList, error)
ExtractSectorEvents transforms sectorChanges, preCommitChanges, and sectorStateChanges to a MinerSectorEventList.
Types ¶
type BeneficiaryExtractor ¶ added in v0.13.0
type BeneficiaryExtractor struct{}
func (BeneficiaryExtractor) Extract ¶ added in v0.13.0
func (BeneficiaryExtractor) Extract(ctx context.Context, a actorstate.ActorInfo, node actorstate.ActorStateAPI) (model.Persistable, error)
type DeadlineInfoExtractor ¶
type DeadlineInfoExtractor struct{}
func (DeadlineInfoExtractor) Extract ¶
func (DeadlineInfoExtractor) Extract(ctx context.Context, a actorstate.ActorInfo, node actorstate.ActorStateAPI) (model.Persistable, error)
type FeeDebtExtractor ¶
type FeeDebtExtractor struct{}
func (FeeDebtExtractor) Extract ¶
func (FeeDebtExtractor) Extract(ctx context.Context, a actorstate.ActorInfo, node actorstate.ActorStateAPI) (model.Persistable, error)
type InfoExtractor ¶
type InfoExtractor struct{}
func (InfoExtractor) Extract ¶
func (InfoExtractor) Extract(ctx context.Context, a actorstate.ActorInfo, node actorstate.ActorStateAPI) (model.Persistable, error)
type LockedFundsExtractor ¶
type LockedFundsExtractor struct{}
func (LockedFundsExtractor) Extract ¶
func (LockedFundsExtractor) Extract(ctx context.Context, a actorstate.ActorInfo, node actorstate.ActorStateAPI) (model.Persistable, error)
func (LockedFundsExtractor) Transform ¶ added in v0.17.0
func (LockedFundsExtractor) Transform(_ context.Context, data model.PersistableList) (model.PersistableList, error)
type MinerStateExtractionContext ¶
type MinerStateExtractionContext struct { PrevState miner.State PrevTs *types.TipSet CurrActor *types.Actor CurrState miner.State CurrTs *types.TipSet PreviousStatePresent bool }
func NewMinerStateExtractionContext ¶
func NewMinerStateExtractionContext(ctx context.Context, a actorstate.ActorInfo, node actorstate.ActorStateAPI) (*MinerStateExtractionContext, error)
func (*MinerStateExtractionContext) HasPreviousState ¶
func (m *MinerStateExtractionContext) HasPreviousState() bool
type PoStExtractor ¶
type PoStExtractor struct{}
func (PoStExtractor) Extract ¶
func (PoStExtractor) Extract(ctx context.Context, a actorstate.ActorInfo, node actorstate.ActorStateAPI) (model.Persistable, error)
type PreCommitInfoExtractorV8 ¶ added in v0.13.0
type PreCommitInfoExtractorV8 struct{}
PreCommitInfoExtractorV8 extracts precommit infos for all miners v8 and previous.
func (PreCommitInfoExtractorV8) Extract ¶ added in v0.13.0
func (PreCommitInfoExtractorV8) Extract(ctx context.Context, a actorstate.ActorInfo, node actorstate.ActorStateAPI) (model.Persistable, error)
func (PreCommitInfoExtractorV8) Transform ¶ added in v0.17.0
func (PreCommitInfoExtractorV8) Transform(_ context.Context, data model.PersistableList) (model.PersistableList, error)
type PreCommitInfoExtractorV9 ¶ added in v0.13.0
type PreCommitInfoExtractorV9 struct{}
func (PreCommitInfoExtractorV9) Extract ¶ added in v0.13.0
func (PreCommitInfoExtractorV9) Extract(ctx context.Context, a actorstate.ActorInfo, node actorstate.ActorStateAPI) (model.Persistable, error)
func (PreCommitInfoExtractorV9) Transform ¶ added in v0.17.0
func (PreCommitInfoExtractorV9) Transform(_ context.Context, data model.PersistableList) (model.PersistableList, error)
type SectorDealsExtractor ¶
type SectorDealsExtractor struct{}
func (SectorDealsExtractor) Extract ¶
func (SectorDealsExtractor) Extract(ctx context.Context, a actorstate.ActorInfo, node actorstate.ActorStateAPI) (model.Persistable, error)
func (SectorDealsExtractor) Transform ¶ added in v0.17.0
func (SectorDealsExtractor) Transform(_ context.Context, data model.PersistableList) (model.PersistableList, error)
type SectorEventsExtractor ¶
type SectorEventsExtractor struct{}
func (SectorEventsExtractor) Extract ¶
func (SectorEventsExtractor) Extract(ctx context.Context, a actorstate.ActorInfo, node actorstate.ActorStateAPI) (model.Persistable, error)
func (SectorEventsExtractor) Transform ¶ added in v0.17.0
func (SectorEventsExtractor) Transform(_ context.Context, data model.PersistableList) (model.PersistableList, error)
type SectorInfoExtractor ¶
type SectorInfoExtractor struct{}
func (SectorInfoExtractor) Extract ¶
func (SectorInfoExtractor) Extract(ctx context.Context, a actorstate.ActorInfo, node actorstate.ActorStateAPI) (model.Persistable, error)
type SectorStateEvents ¶ added in v0.12.0
type SectorStateEvents struct { // Removed sectors this epoch Removed bitfield.BitField // Recovering sectors this epoch Recovering bitfield.BitField // Faulted sectors this epoch Faulted bitfield.BitField // Recovered sectors this epoch Recovered bitfield.BitField }
SectorStateEvents contains bitfields for sectors that were removed, recovered, faulted, and recovering.
func DiffMinerSectorStates ¶ added in v0.12.0
func DiffMinerSectorStates(ctx context.Context, extState extraction.State) (*SectorStateEvents, error)
DiffMinerSectorStates loads the SectorStates for the current and parent miner states in parallel from `extState`. Then compares current and parent SectorStates to produce a SectorStateEvents structure containing all sectors that are removed, recovering, faulted, and recovered for the state transition from parent miner state to current miner state.
type SectorStates ¶ added in v0.12.0
type SectorStates struct { // Active sectors are those that are neither terminated nor faulty nor unproven, i.e. actively contributing power. Active bitfield.BitField // Live sectors are those that are not terminated (but may be faulty). Live bitfield.BitField // Faulty contains a subset of sectors detected/declared faulty and not yet recovered (excl. from PoSt). Faulty bitfield.BitField // Recovering contains a subset of faulty sectors expected to recover on next PoSt. Recovering bitfield.BitField }
SectorStates contains a set of bitfields for active, live, fault, and recovering sectors.
func LoadSectorState ¶ added in v0.12.0
LoadSectorState loads all sectors from a miners partitions and returns a SectorStates structure containing individual bitfields for all active, live, faulty and recovering sector.
type V7SectorInfoExtractor ¶
type V7SectorInfoExtractor struct{}
func (V7SectorInfoExtractor) Extract ¶
func (V7SectorInfoExtractor) Extract(ctx context.Context, a actorstate.ActorInfo, node actorstate.ActorStateAPI) (model.Persistable, error)
func (V7SectorInfoExtractor) Transform ¶ added in v0.17.0
func (V7SectorInfoExtractor) Transform(_ context.Context, data model.PersistableList) (model.PersistableList, error)