statesync/rpc: metrics for the statesync and the rpc SyncInfo (#6795)

This commit is contained in:
JayT106
2021-09-21 09:22:16 +02:00
committed by GitHub
parent 9dfdc62eb7
commit 84ffaaaf37
14 changed files with 500 additions and 52 deletions
+112
View File
@@ -0,0 +1,112 @@
// Code generated by mockery 2.9.4. DO NOT EDIT.
package mocks
import (
mock "github.com/stretchr/testify/mock"
time "time"
)
// Metricer is an autogenerated mock type for the Metricer type
type Metricer struct {
mock.Mock
}
// BackFillBlocksTotal provides a mock function with given fields:
func (_m *Metricer) BackFillBlocksTotal() int64 {
ret := _m.Called()
var r0 int64
if rf, ok := ret.Get(0).(func() int64); ok {
r0 = rf()
} else {
r0 = ret.Get(0).(int64)
}
return r0
}
// BackFilledBlocks provides a mock function with given fields:
func (_m *Metricer) BackFilledBlocks() int64 {
ret := _m.Called()
var r0 int64
if rf, ok := ret.Get(0).(func() int64); ok {
r0 = rf()
} else {
r0 = ret.Get(0).(int64)
}
return r0
}
// ChunkProcessAvgTime provides a mock function with given fields:
func (_m *Metricer) ChunkProcessAvgTime() time.Duration {
ret := _m.Called()
var r0 time.Duration
if rf, ok := ret.Get(0).(func() time.Duration); ok {
r0 = rf()
} else {
r0 = ret.Get(0).(time.Duration)
}
return r0
}
// SnapshotChunksCount provides a mock function with given fields:
func (_m *Metricer) SnapshotChunksCount() int64 {
ret := _m.Called()
var r0 int64
if rf, ok := ret.Get(0).(func() int64); ok {
r0 = rf()
} else {
r0 = ret.Get(0).(int64)
}
return r0
}
// SnapshotChunksTotal provides a mock function with given fields:
func (_m *Metricer) SnapshotChunksTotal() int64 {
ret := _m.Called()
var r0 int64
if rf, ok := ret.Get(0).(func() int64); ok {
r0 = rf()
} else {
r0 = ret.Get(0).(int64)
}
return r0
}
// SnapshotHeight provides a mock function with given fields:
func (_m *Metricer) SnapshotHeight() int64 {
ret := _m.Called()
var r0 int64
if rf, ok := ret.Get(0).(func() int64); ok {
r0 = rf()
} else {
r0 = ret.Get(0).(int64)
}
return r0
}
// TotalSnapshots provides a mock function with given fields:
func (_m *Metricer) TotalSnapshots() int64 {
ret := _m.Called()
var r0 int64
if rf, ok := ret.Get(0).(func() int64); ok {
r0 = rf()
} else {
r0 = ret.Get(0).(int64)
}
return r0
}