NewBatchStatsReporter create a new BatchStatsReporter instance
(intervalInSeconds int, memStore MemStore, shardOwner topology.ShardOwner)
| 30 | |
| 31 | // NewBatchStatsReporter create a new BatchStatsReporter instance |
| 32 | func NewBatchStatsReporter(intervalInSeconds int, memStore MemStore, shardOwner topology.ShardOwner) *BatchStatsReporter { |
| 33 | return &BatchStatsReporter{ |
| 34 | intervalInSeconds: intervalInSeconds, |
| 35 | memStore: memStore, |
| 36 | shardOwner: shardOwner, |
| 37 | stopChan: make(chan struct{}), |
| 38 | } |
| 39 | } |
| 40 | |
| 41 | // Run is a ticker function to run report periodically |
| 42 | func (batchStats *BatchStatsReporter) Run() { |
no outgoing calls
no test coverage detected