Documentation ¶
Index ¶
- Constants
- type ClaimStatus
- type CreditExpectation
- type GameAgreementStatus
- type Metricer
- type Metrics
- func (m *Metrics) Document() []opmetrics.DocumentedMetric
- func (m *Metrics) RecordBondCollateral(addr common.Address, required *big.Int, available *big.Int)
- func (m *Metrics) RecordClaimResolutionDelayMax(delay float64)
- func (m *Metrics) RecordClaims(status ClaimStatus, count int)
- func (m *Metrics) RecordCredit(expectation CreditExpectation, count int)
- func (m *Metrics) RecordGameAgreement(status GameAgreementStatus, count int)
- func (m *Metrics) RecordGameResolutionStatus(complete bool, maxDurationReached bool, count int)
- func (m *Metrics) RecordInfo(version string)
- func (m *Metrics) RecordOutputFetchTime(timestamp float64)
- func (m *Metrics) RecordUnexpectedClaimResolution(address common.Address, count int)
- func (m *Metrics) RecordUp()
- func (m *Metrics) RecordWithdrawalRequests(delayedWeth common.Address, matches bool, count int)
- func (m *Metrics) Registry() *prometheus.Registry
- func (m *Metrics) Start(host string, port int) (*httputil.HTTPServer, error)
- func (m *Metrics) StartBalanceMetrics(l log.Logger, client *ethclient.Client, account common.Address) io.Closer
- type NoopMetricsImpl
- func (*NoopMetricsImpl) CacheAdd(_ string, _ int, _ bool)
- func (*NoopMetricsImpl) CacheGet(_ string, _ bool)
- func (i *NoopMetricsImpl) RecordBondCollateral(_ common.Address, _ *big.Int, _ *big.Int)
- func (*NoopMetricsImpl) RecordClaimResolutionDelayMax(_ float64)
- func (*NoopMetricsImpl) RecordClaims(_ ClaimStatus, _ int)
- func (*NoopMetricsImpl) RecordCredit(_ CreditExpectation, _ int)
- func (*NoopMetricsImpl) RecordGameAgreement(_ GameAgreementStatus, _ int)
- func (*NoopMetricsImpl) RecordGameResolutionStatus(_ bool, _ bool, _ int)
- func (*NoopMetricsImpl) RecordInfo(_ string)
- func (*NoopMetricsImpl) RecordOutputFetchTime(_ float64)
- func (*NoopMetricsImpl) RecordUnexpectedClaimResolution(_ common.Address, _ int)
- func (*NoopMetricsImpl) RecordUp()
- func (*NoopMetricsImpl) RecordWithdrawalRequests(_ common.Address, _ bool, _ int)
Constants ¶
View Source
const Namespace = "op_dispute_mon"
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type ClaimStatus ¶ added in v1.7.3
type ClaimStatus uint8
const ( // Claims where the game is in the first half FirstHalfExpiredResolved ClaimStatus = iota FirstHalfExpiredUnresolved FirstHalfNotExpiredResolved FirstHalfNotExpiredUnresolved // Claims where the game is in the second half SecondHalfExpiredResolved SecondHalfExpiredUnresolved SecondHalfNotExpiredResolved SecondHalfNotExpiredUnresolved )
type CreditExpectation ¶ added in v1.7.3
type CreditExpectation uint8
const ( // Max Duration reached CreditBelowMaxDuration CreditExpectation = iota CreditEqualMaxDuration CreditAboveMaxDuration // Max Duration not reached CreditBelowNonMaxDuration CreditEqualNonMaxDuration CreditAboveNonMaxDuration )
type GameAgreementStatus ¶ added in v1.7.0
type GameAgreementStatus uint8
const ( // In progress AgreeChallengerAhead GameAgreementStatus = iota DisagreeChallengerAhead AgreeDefenderAhead DisagreeDefenderAhead // Completed AgreeDefenderWins DisagreeDefenderWins AgreeChallengerWins DisagreeChallengerWins )
type Metricer ¶
type Metricer interface { RecordInfo(version string) RecordUp() RecordUnexpectedClaimResolution(address common.Address, count int) RecordGameResolutionStatus(complete bool, maxDurationReached bool, count int) RecordCredit(expectation CreditExpectation, count int) RecordClaims(status ClaimStatus, count int) RecordWithdrawalRequests(delayedWeth common.Address, matches bool, count int) RecordClaimResolutionDelayMax(delay float64) RecordOutputFetchTime(timestamp float64) RecordGameAgreement(status GameAgreementStatus, count int) RecordBondCollateral(addr common.Address, required *big.Int, available *big.Int) caching.Metrics contractMetrics.ContractMetricer }
var NoopMetrics Metricer = new(NoopMetricsImpl)
type Metrics ¶
type Metrics struct { *opmetrics.CacheMetrics *contractMetrics.ContractMetrics // contains filtered or unexported fields }
func NewMetrics ¶
func NewMetrics() *Metrics
func (*Metrics) Document ¶
func (m *Metrics) Document() []opmetrics.DocumentedMetric
func (*Metrics) RecordBondCollateral ¶ added in v1.7.2
func (*Metrics) RecordClaimResolutionDelayMax ¶ added in v1.7.2
func (*Metrics) RecordClaims ¶ added in v1.7.3
func (m *Metrics) RecordClaims(status ClaimStatus, count int)
func (*Metrics) RecordCredit ¶ added in v1.7.3
func (m *Metrics) RecordCredit(expectation CreditExpectation, count int)
func (*Metrics) RecordGameAgreement ¶ added in v1.6.1
func (m *Metrics) RecordGameAgreement(status GameAgreementStatus, count int)
func (*Metrics) RecordGameResolutionStatus ¶ added in v1.7.3
func (*Metrics) RecordInfo ¶
RecordInfo sets a pseudo-metric that contains versioning and config info for the op-proposer.
func (*Metrics) RecordOutputFetchTime ¶ added in v1.7.2
func (*Metrics) RecordUnexpectedClaimResolution ¶ added in v1.7.3
func (*Metrics) RecordWithdrawalRequests ¶ added in v1.7.3
func (*Metrics) Registry ¶
func (m *Metrics) Registry() *prometheus.Registry
type NoopMetricsImpl ¶
type NoopMetricsImpl struct {
contractMetrics.NoopMetrics
}
func (*NoopMetricsImpl) CacheGet ¶
func (*NoopMetricsImpl) CacheGet(_ string, _ bool)
func (*NoopMetricsImpl) RecordBondCollateral ¶ added in v1.7.2
func (*NoopMetricsImpl) RecordClaimResolutionDelayMax ¶ added in v1.7.2
func (*NoopMetricsImpl) RecordClaimResolutionDelayMax(_ float64)
func (*NoopMetricsImpl) RecordClaims ¶ added in v1.7.3
func (*NoopMetricsImpl) RecordClaims(_ ClaimStatus, _ int)
func (*NoopMetricsImpl) RecordCredit ¶ added in v1.7.3
func (*NoopMetricsImpl) RecordCredit(_ CreditExpectation, _ int)
func (*NoopMetricsImpl) RecordGameAgreement ¶ added in v1.6.1
func (*NoopMetricsImpl) RecordGameAgreement(_ GameAgreementStatus, _ int)
func (*NoopMetricsImpl) RecordGameResolutionStatus ¶ added in v1.7.3
func (*NoopMetricsImpl) RecordGameResolutionStatus(_ bool, _ bool, _ int)
func (*NoopMetricsImpl) RecordInfo ¶
func (*NoopMetricsImpl) RecordInfo(_ string)
func (*NoopMetricsImpl) RecordOutputFetchTime ¶ added in v1.7.2
func (*NoopMetricsImpl) RecordOutputFetchTime(_ float64)
func (*NoopMetricsImpl) RecordUnexpectedClaimResolution ¶ added in v1.7.3
func (*NoopMetricsImpl) RecordUnexpectedClaimResolution(_ common.Address, _ int)
func (*NoopMetricsImpl) RecordUp ¶
func (*NoopMetricsImpl) RecordUp()
func (*NoopMetricsImpl) RecordWithdrawalRequests ¶ added in v1.7.3
func (*NoopMetricsImpl) RecordWithdrawalRequests(_ common.Address, _ bool, _ int)
Click to show internal directories.
Click to hide internal directories.