Skip to content

Commit ad04f27

Browse files
committed
Pusher engine refactor: remove unused collection metrics
1 parent aad332c commit ad04f27

File tree

4 files changed

+2
-7
lines changed

4 files changed

+2
-7
lines changed

cmd/collection/main.go

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -481,7 +481,6 @@ func main() {
481481
node.State,
482482
node.Metrics.Engine,
483483
node.Metrics.Mempool,
484-
colMetrics,
485484
node.Me,
486485
node.Storage.Collections,
487486
node.Storage.Transactions,

engine/collection/pusher/engine.go

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,6 @@ import (
3131
type Engine struct {
3232
log zerolog.Logger
3333
engMetrics module.EngineMetrics
34-
colMetrics module.CollectionMetrics
3534
conduit network.Conduit
3635
me module.Local
3736
state protocol.State
@@ -56,7 +55,6 @@ func New(
5655
state protocol.State,
5756
engMetrics module.EngineMetrics,
5857
mempoolMetrics module.MempoolMetrics,
59-
colMetrics module.CollectionMetrics,
6058
me module.Local,
6159
collections storage.Collections,
6260
transactions storage.Transactions,
@@ -76,7 +74,6 @@ func New(
7674
e := &Engine{
7775
log: log.With().Str("engine", "pusher").Logger(),
7876
engMetrics: engMetrics,
79-
colMetrics: colMetrics,
8077
me: me,
8178
state: state,
8279
collections: collections,
@@ -100,7 +97,7 @@ func New(
10097
return e, nil
10198
}
10299

103-
// outboundQueueWorker implements a component worker which broadcasts collection guarantees,
100+
// outboundQueueWorker implements a component worker which broadcasts collection guarantees,
104101
// enqueued by the Finalizer upon finalization, to Consensus Nodes.
105102
func (e *Engine) outboundQueueWorker(ctx irrecoverable.SignalerContext, ready component.ReadyFunc) {
106103
ready()

engine/collection/pusher/engine_test.go

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -72,7 +72,6 @@ func (suite *Suite) SetupTest() {
7272
suite.state,
7373
metrics,
7474
metrics,
75-
metrics,
7675
suite.me,
7776
suite.collections,
7877
suite.transactions,

engine/testutil/nodes.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -313,7 +313,7 @@ func CollectionNode(t *testing.T, hub *stub.Hub, identity bootstrap.NodeInfo, ro
313313
retrieve)
314314
require.NoError(t, err)
315315

316-
pusherEngine, err := pusher.New(node.Log, node.Net, node.State, node.Metrics, node.Metrics, node.Metrics, node.Me, collections, transactions)
316+
pusherEngine, err := pusher.New(node.Log, node.Net, node.State, node.Metrics, node.Metrics, node.Me, collections, transactions)
317317
require.NoError(t, err)
318318

319319
clusterStateFactory, err := factories.NewClusterStateFactory(

0 commit comments

Comments
 (0)