Documentation ¶
Index ¶
- type AccountEraSeq
- type Aggregate
- type BlockSeq
- type BlockSeqSummary
- type BlockSummary
- type DelegationChangeData
- type EraSequence
- type EventSeq
- type EventSeqWithTxHash
- type MissedNConsecutive
- type MissedNofMData
- type Model
- type PercentChangeData
- type Report
- type ReportKind
- type RewardEraSeq
- type RewardKind
- type Sequence
- type SessionSequence
- type Summary
- type Syncable
- type SyncableStatus
- type SystemEvent
- type SystemEventKind
- type TransactionKind
- type TransactionSeq
- type ValidatorAgg
- type ValidatorEraSeq
- type ValidatorEraSeqSummary
- type ValidatorSeq
- type ValidatorSessionSeq
- type ValidatorSessionSeqSummary
- type ValidatorSummary
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type AccountEraSeq ¶ added in v0.3.0
type AccountEraSeq struct { ID types.ID `json:"id"` *EraSequence // Origin accounts StashAccount string `json:"stash_account"` ControllerAccount string `json:"controller_account"` // Destination accounts ValidatorStashAccount string `json:"validator_stash_account"` ValidatorControllerAccount string `json:"validator_controller_account"` Stake types.Quantity `json:"own_stake"` }
func (*AccountEraSeq) Equal ¶ added in v0.3.0
func (s *AccountEraSeq) Equal(m AccountEraSeq) bool
func (AccountEraSeq) TableName ¶ added in v0.3.0
func (AccountEraSeq) TableName() string
func (*AccountEraSeq) Valid ¶ added in v0.3.0
func (s *AccountEraSeq) Valid() bool
type Aggregate ¶
type Aggregate struct { StartedAtHeight int64 `json:"started_at_height"` StartedAt types.Time `json:"started_at"` RecentAtHeight int64 `json:"recent_at_height"` RecentAt types.Time `json:"recent_at"` }
Aggregate is used for aggregate tables
type BlockSeq ¶
type BlockSeqSummary ¶ added in v0.4.5
type BlockSummary ¶
type BlockSummary struct { *Model *Summary Count int64 `json:"count"` BlockTimeAvg float64 `json:"block_time_avg"` }
swagger:response BlockSummary
func (BlockSummary) TableName ¶
func (BlockSummary) TableName() string
type DelegationChangeData ¶ added in v0.5.0
type DelegationChangeData struct {
StashAccounts []string `json:"stash_accounts"`
}
DelegationChangeData is data format for delegation system events
type EraSequence ¶ added in v0.1.2
type EraSequence struct { Era int64 `json:"era"` StartHeight int64 `json:"start_height"` EndHeight int64 `json:"end_height"` Time types.Time `json:"time"` }
EraSequence is used for sequences recorded per era
func (*EraSequence) Equal ¶ added in v0.1.2
func (s *EraSequence) Equal(m EraSequence) bool
func (*EraSequence) Valid ¶ added in v0.1.2
func (s *EraSequence) Valid() bool
type EventSeq ¶ added in v0.1.2
type EventSeqWithTxHash ¶ added in v0.4.4
type MissedNConsecutive ¶ added in v0.5.0
MissedNConsecutive is data format for missedNofM system events
type MissedNofMData ¶ added in v0.5.0
type MissedNofMData struct { Missed int64 `json:"missed"` Threshold int64 `json:"threshold"` MaxTotalSessions int64 `json:"max_total_sessions"` }
MissedNofMData is data format for missedNofM system events
type Model ¶
type Model struct { ID types.ID `json:"id"` CreatedAt types.Time `json:"created_at"` UpdatedAt types.Time `json:"updated_at"` }
Model is used for general table
type PercentChangeData ¶ added in v0.5.0
type PercentChangeData struct { Before int64 `json:"before"` After int64 `json:"after"` Change float64 `json:"change"` }
PercentChangeData is data format for change system events
type Report ¶
type Report struct { *Model Kind ReportKind IndexVersion int64 StartHeight int64 EndHeight int64 SuccessCount *int64 ErrorCount *int64 ErrorMsg *string Duration time.Duration CompletedAt *types.Time }
type ReportKind ¶
type ReportKind int
const ( ReportKindIndex ReportKind = iota + 1 ReportKindParallelReindex ReportKindSequentialReindex )
func (ReportKind) String ¶
func (k ReportKind) String() string
type RewardEraSeq ¶ added in v0.6.0
type RewardEraSeq struct { *EraSequence StashAccount string `json:"stash_account"` ValidatorStashAccount string `json:"validator_stash_account"` Amount string `json:"amount"` Kind RewardKind `json:"kind"` Claimed bool `json:"claimed"` TxHash string `json:"tx_hash"` }
func (RewardEraSeq) TableName ¶ added in v0.6.0
func (RewardEraSeq) TableName() string
type RewardKind ¶ added in v0.6.0
type RewardKind string
const ( RewardCommission RewardKind = "commission" RewardReward RewardKind = "reward" // for historical data, it's not possible to dissect reward from commission RewardCommissionAndReward RewardKind = "commission_and_reward" )
func (RewardKind) String ¶ added in v0.6.0
func (o RewardKind) String() string
type SessionSequence ¶ added in v0.1.2
type SessionSequence struct { Session int64 `json:"session"` StartHeight int64 `json:"start_height"` EndHeight int64 `json:"end_height"` Time types.Time `json:"time"` }
SessionSequence is used for sequences recorded per session
func (*SessionSequence) Equal ¶ added in v0.1.2
func (s *SessionSequence) Equal(m SessionSequence) bool
func (*SessionSequence) Valid ¶ added in v0.1.2
func (s *SessionSequence) Valid() bool
type Summary ¶
type Summary struct { IndexVersion int64 `json:"index_version"` TimeInterval types.SummaryInterval `json:"time_interval"` TimeBucket types.Time `json:"time_bucket"` }
Summary is used for summary tables
type Syncable ¶
type Syncable struct { *Model Height int64 `json:"height"` Time types.Time `json:"time"` SpecVersion string `json:"spec_version"` ChainUID string `json:"chain_uid"` Session int64 `json:"session"` Era int64 `json:"era"` LastInSession bool `json:"last_in_session"` LastInEra bool `json:"last_in_era"` IndexVersion int64 `json:"index_version"` Status SyncableStatus `json:"status"` ReportID types.ID `json:"report_id"` StartedAt types.Time `json:"started_at"` ProcessedAt *types.Time `json:"processed_at"` Duration time.Duration `json:"duration"` }
func (*Syncable) MarkProcessed ¶
func (*Syncable) SetStatus ¶
func (s *Syncable) SetStatus(newStatus SyncableStatus)
type SyncableStatus ¶
type SyncableStatus int
const ( SyncableStatusRunning SyncableStatus = iota + 1 SyncableStatusCompleted )
type SystemEvent ¶ added in v0.5.0
type SystemEventKind ¶ added in v0.5.0
type SystemEventKind string
const ( SystemEventActiveBalanceChange1 SystemEventKind = "active_balance_change_1" SystemEventActiveBalanceChange2 SystemEventKind = "active_balance_change_2" SystemEventActiveBalanceChange3 SystemEventKind = "active_balance_change_3" SystemEventCommissionChange1 SystemEventKind = "commission_change_1" SystemEventCommissionChange2 SystemEventKind = "commission_change_2" SystemEventCommissionChange3 SystemEventKind = "commission_change_3" SystemEventJoinedSet SystemEventKind = "joined_set" SystemEventLeftSet SystemEventKind = "left_set" SystemEventMissedNConsecutive SystemEventKind = "missed_n_consecutive" SystemEventDelegationLeft SystemEventKind = "delegation_left" SystemEventDelegationJoined SystemEventKind = "delegation_joined" )
func (SystemEventKind) String ¶ added in v0.5.0
func (o SystemEventKind) String() string
type TransactionKind ¶ added in v0.7.0
type TransactionSeq ¶ added in v0.4.4
type TransactionSeq struct { ID types.ID `json:"id"` *Sequence // Indexed data Index int64 `json:"index"` Hash string `json:"hash"` Method string `json:"method"` Section string `json:"section"` Args string `json:"args"` }
func (TransactionSeq) TableName ¶ added in v0.4.4
func (TransactionSeq) TableName() string
func (*TransactionSeq) Valid ¶ added in v0.4.4
func (t *TransactionSeq) Valid() bool
type ValidatorAgg ¶ added in v0.1.2
type ValidatorAgg struct { *Model *Aggregate StashAccount string `json:"stash_account"` DisplayName string `json:"display_name"` RecentAsValidatorHeight int64 `json:"recent_as_validator_height"` AccumulatedUptime int64 `json:"accumulated_uptime"` AccumulatedUptimeCount int64 `json:"accumulated_uptime_count"` }
func (*ValidatorAgg) Equal ¶ added in v0.1.2
func (s *ValidatorAgg) Equal(m ValidatorAgg) bool
func (*ValidatorAgg) Update ¶ added in v0.1.2
func (s *ValidatorAgg) Update(u *ValidatorAgg)
func (*ValidatorAgg) Valid ¶ added in v0.1.2
func (s *ValidatorAgg) Valid() bool
type ValidatorEraSeq ¶ added in v0.1.2
type ValidatorEraSeq struct { ID types.ID `json:"id"` *EraSequence StashAccount string `json:"stash_account"` ControllerAccount string `json:"controller_account"` SessionAccounts pq.StringArray `json:"session_accounts"` Index int64 `json:"index"` TotalStake types.Quantity `json:"total_stake"` OwnStake types.Quantity `json:"own_stake"` StakersStake types.Quantity `json:"stakers_stake"` RewardPoints int64 `json:"reward_points"` Commission int64 `json:"commission"` StakersCount int `json:"stakers_count"` }
func (*ValidatorEraSeq) Equal ¶ added in v0.1.2
func (s *ValidatorEraSeq) Equal(m ValidatorEraSeq) bool
func (ValidatorEraSeq) TableName ¶ added in v0.1.2
func (ValidatorEraSeq) TableName() string
func (*ValidatorEraSeq) Valid ¶ added in v0.1.2
func (s *ValidatorEraSeq) Valid() bool
type ValidatorEraSeqSummary ¶ added in v0.4.5
type ValidatorEraSeqSummary struct { StashAccount string `json:"stash_account"` TimeBucket types.Time `json:"time_bucket"` TotalStakeAvg types.Quantity `json:"total_stake_avg"` TotalStakeMin types.Quantity `json:"total_stake_min"` TotalStakeMax types.Quantity `json:"total_stake_max"` OwnStakeAvg types.Quantity `json:"own_stake_avg"` OwnStakeMin types.Quantity `json:"own_stake_min"` OwnStakeMax types.Quantity `json:"own_stake_max"` StakersStakeAvg types.Quantity `json:"stakers_stake_avg"` StakersStakeMin types.Quantity `json:"stakers_stake_min"` StakersStakeMax types.Quantity `json:"stakers_stake_max"` RewardPointsAvg float64 `json:"reward_points_avg"` RewardPointsMin int64 `json:"reward_points_min"` RewardPointsMax int64 `json:"reward_points_max"` CommissionAvg float64 `json:"commission_avg"` CommissionMin int64 `json:"commission_min"` CommissionMax int64 `json:"commission_max"` StakersCountAvg float64 `json:"stakers_count_avg"` StakersCountMin int64 `json:"stakers_count_min"` StakersCountMax int64 `json:"stakers_count_max"` }
type ValidatorSeq ¶ added in v0.5.0
type ValidatorSeq struct { ID types.ID `json:"id"` *Sequence StashAccount string `json:"stash_account"` ActiveBalance types.Quantity `json:"active_balance"` }
func (*ValidatorSeq) Equal ¶ added in v0.5.0
func (vs *ValidatorSeq) Equal(m ValidatorSeq) bool
func (ValidatorSeq) TableName ¶ added in v0.5.0
func (ValidatorSeq) TableName() string
func (*ValidatorSeq) Valid ¶ added in v0.5.0
func (vs *ValidatorSeq) Valid() bool
type ValidatorSessionSeq ¶ added in v0.1.2
type ValidatorSessionSeq struct { ID types.ID `json:"id"` *SessionSequence StashAccount string `json:"stash_account"` Online bool `json:"online"` }
func (*ValidatorSessionSeq) Equal ¶ added in v0.1.2
func (s *ValidatorSessionSeq) Equal(m ValidatorSessionSeq) bool
func (ValidatorSessionSeq) TableName ¶ added in v0.1.2
func (ValidatorSessionSeq) TableName() string
func (*ValidatorSessionSeq) Valid ¶ added in v0.1.2
func (s *ValidatorSessionSeq) Valid() bool
type ValidatorSessionSeqSummary ¶ added in v0.4.5
type ValidatorSummary ¶ added in v0.1.2
type ValidatorSummary struct { *Model *Summary StashAccount string `json:"address"` // Era info TotalStakeAvg types.Quantity `json:"total_stake_avg"` TotalStakeMin types.Quantity `json:"total_stake_min"` TotalStakeMax types.Quantity `json:"total_stake_max"` OwnStakeAvg types.Quantity `json:"own_stake_avg"` OwnStakeMin types.Quantity `json:"own_stake_min"` OwnStakeMax types.Quantity `json:"own_stake_max"` StakersStakeAvg types.Quantity `json:"stakers_stake_avg"` StakersStakeMin types.Quantity `json:"stakers_stake_min"` StakersStakeMax types.Quantity `json:"stakers_stake_max"` RewardPointsAvg float64 `json:"reward_points_avg"` RewardPointsMin int64 `json:"reward_points_min"` RewardPointsMax int64 `json:"reward_points_max"` CommissionAvg float64 `json:"commission_avg"` CommissionMin int64 `json:"commission_min"` CommissionMax int64 `json:"commission_max"` StakersCountAvg float64 `json:"stakers_count_avg"` StakersCountMin int64 `json:"stakers_count_min"` StakersCountMax int64 `json:"stakers_count_max"` // Session info UptimeAvg float64 `json:"uptime_avg"` UptimeMax int64 `json:"uptime_max"` UptimeMin int64 `json:"uptime_min"` }
func (ValidatorSummary) TableName ¶ added in v0.1.2
func (ValidatorSummary) TableName() string
Source Files ¶
- account_era_seq.go
- block_seq.go
- block_seq_summary.go
- block_summary.go
- common.go
- event_seq.go
- report.go
- reward_era_seq.go
- syncable.go
- system_event.go
- transaction_seq.go
- validator_agg.go
- validator_era_seq.go
- validator_era_seq_summary.go
- validator_seq.go
- validator_session_seq.go
- validator_session_seq_summary.go
- validator_summary.go
Click to show internal directories.
Click to hide internal directories.