Skip to content

Commit 409565d

Browse files
small fixes
1 parent 1a793e8 commit 409565d

File tree

4 files changed

+6
-98
lines changed

4 files changed

+6
-98
lines changed

cmd/access/index/reporter.go

Lines changed: 0 additions & 73 deletions
This file was deleted.

cmd/access/node_builder/access_node_builder.go

Lines changed: 5 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,6 @@ import (
2828
stateSyncCommands "github.com/onflow/flow-go/admin/commands/state_synchronization"
2929
storageCommands "github.com/onflow/flow-go/admin/commands/storage"
3030
"github.com/onflow/flow-go/cmd"
31-
"github.com/onflow/flow-go/cmd/access/index"
3231
"github.com/onflow/flow-go/consensus"
3332
"github.com/onflow/flow-go/consensus/hotstuff"
3433
"github.com/onflow/flow-go/consensus/hotstuff/committees"
@@ -296,7 +295,6 @@ type FlowAccessNodeBuilder struct {
296295
ScriptExecutor *backend.ScriptExecutor
297296
RegistersAsyncStore *execution.RegistersAsyncStore
298297
EventsIndex *backend.EventsIndex
299-
Reporter *index.Reporter
300298
TxResultsIndex *backend.TransactionResultsIndex
301299
IndexerDependencies *cmd.DependencyList
302300
collectionExecutedMetric module.CollectionExecutedMetric
@@ -874,11 +872,6 @@ func (builder *FlowAccessNodeBuilder) BuildExecutionSyncComponents() *FlowAccess
874872
builder.programCacheSize > 0,
875873
)
876874

877-
err = builder.Reporter.Initialize(builder.ExecutionIndexer)
878-
if err != nil {
879-
return nil, err
880-
}
881-
882875
err = builder.ScriptExecutor.Initialize(builder.ExecutionIndexer, scripts)
883876
if err != nil {
884877
return nil, err
@@ -1651,7 +1644,11 @@ func (builder *FlowAccessNodeBuilder) Build() (cmd.Node, error) {
16511644
}).
16521645
Module("transaction result error messages storage", func(node *cmd.NodeConfig) error {
16531646
if builder.storeTxResultErrorMessages {
1654-
builder.Storage.TransactionResultErrorMessages = bstorage.NewTransactionResultErrorMessages(node.Metrics.Cache, node.DB, bstorage.DefaultCacheSize)
1647+
builder.Storage.TransactionResultErrorMessages = bstorage.NewTransactionResultErrorMessages(
1648+
node.Metrics.Cache,
1649+
node.DB,
1650+
bstorage.DefaultCacheSize,
1651+
)
16551652
}
16561653

16571654
return nil
@@ -1709,12 +1706,6 @@ func (builder *FlowAccessNodeBuilder) Build() (cmd.Node, error) {
17091706
return nil, fmt.Errorf("transaction result query mode 'compare' is not supported")
17101707
}
17111708

1712-
// If execution data syncing and indexing is disabled, pass nil indexReporter
1713-
var indexReporter state_synchronization.IndexReporter
1714-
if builder.executionDataSyncEnabled && builder.executionDataIndexingEnabled {
1715-
indexReporter = builder.Reporter
1716-
}
1717-
17181709
preferredENIdentifiers, err := commonrpc.IdentifierList(backendConfig.PreferredExecutionNodeIDs)
17191710
if err != nil {
17201711
return nil, fmt.Errorf("failed to convert node id string to Flow Identifier for preferred EN map: %w", err)
@@ -1760,7 +1751,6 @@ func (builder *FlowAccessNodeBuilder) Build() (cmd.Node, error) {
17601751
TxResultQueryMode: txResultQueryMode,
17611752
TxResultsIndex: builder.TxResultsIndex,
17621753
LastFullBlockHeight: lastFullBlockHeight,
1763-
IndexReporter: indexReporter,
17641754
ExecNodeIdentitiesProvider: builder.ExecNodeIdentitiesProvider,
17651755
})
17661756
if err != nil {

cmd/observer/node_builder/observer_builder.go

Lines changed: 0 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,6 @@ import (
3030
"github.com/onflow/flow-go/admin/commands"
3131
stateSyncCommands "github.com/onflow/flow-go/admin/commands/state_synchronization"
3232
"github.com/onflow/flow-go/cmd"
33-
"github.com/onflow/flow-go/cmd/access/index"
3433
"github.com/onflow/flow-go/consensus"
3534
"github.com/onflow/flow-go/consensus/hotstuff"
3635
"github.com/onflow/flow-go/consensus/hotstuff/committees"
@@ -245,7 +244,6 @@ type ObserverServiceBuilder struct {
245244
ExecutionDataStore execution_data.ExecutionDataStore
246245

247246
RegistersAsyncStore *execution.RegistersAsyncStore
248-
Reporter *index.Reporter
249247
EventsIndex *backend.EventsIndex
250248

251249
// available until after the network has started. Hence, a factory function that needs to be called just before
@@ -1564,12 +1562,6 @@ func (builder *ObserverServiceBuilder) enqueueRPCServer() {
15641562
),
15651563
}
15661564

1567-
// If execution data syncing and indexing is disabled, pass nil indexReporter
1568-
var indexReporter state_synchronization.IndexReporter
1569-
if builder.executionDataSyncEnabled && builder.executionDataIndexingEnabled {
1570-
indexReporter = builder.Reporter
1571-
}
1572-
15731565
preferredENIdentifiers, err := commonrpc.IdentifierList(backendConfig.PreferredExecutionNodeIDs)
15741566
if err != nil {
15751567
return nil, fmt.Errorf("failed to convert node id string to Flow Identifier for preferred EN map: %w", err)
@@ -1604,7 +1596,6 @@ func (builder *ObserverServiceBuilder) enqueueRPCServer() {
16041596
Log: node.Logger,
16051597
SnapshotHistoryLimit: backend.DefaultSnapshotHistoryLimit,
16061598
Communicator: backend.NewNodeCommunicator(backendConfig.CircuitBreakerConfig.Enabled),
1607-
IndexReporter: indexReporter,
16081599
ExecNodeIdentitiesProvider: execNodeIdentitiesProvider,
16091600
})
16101601
if err != nil {

integration/localnet/Makefile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -148,7 +148,7 @@ clean-data:
148148
rm -rf ./bootstrap
149149
rm -rf ./trie
150150
rm -rf ./profiler
151-
rm -f ./targets.nodes.json
151+
rm -rf ./targets.nodes.json
152152
rm -f ./docker-compose.nodes.yml
153153

154154
# deletes the stopped environment-clean container(s) - running this command inside another target doesn't delete the containers so it's isolated to run in a separate target

0 commit comments

Comments
 (0)