Skip to content

Commit

Permalink
update changes in connector
Browse files Browse the repository at this point in the history
  • Loading branch information
ssd04 committed May 8, 2024
1 parent 32810dc commit 042f242
Showing 1 changed file with 7 additions and 7 deletions.
14 changes: 7 additions & 7 deletions connector/connectorRunner.go
Original file line number Diff line number Diff line change
Expand Up @@ -67,33 +67,33 @@ func (cr *connectorRunner) Run() error {
CleanupInterval: cr.config.DataPool.PruningWindow,
FirstCommitableBlock: cr.config.DataPool.FirstCommitableBlock,
}
baseBlocksPool, err := process.NewBlocksPool(argsBlocksPool)
dataPool, err := process.NewDataPool(argsBlocksPool)
if err != nil {
return err
}

outportBlocksPool, err := process.NewHyperOutportBlocksPool(
baseBlocksPool,
blocksPool, err := process.NewBlocksPool(
dataPool,
protoMarshaller,
)
if err != nil {
return err
}

dataAggregator, err := process.NewDataAggregator(outportBlocksPool)
dataAggregator, err := process.NewDataAggregator(blocksPool)
if err != nil {
return err
}

publisher, err := factory.CreatePublisher(cr.config, cr.enableGrpcServer, blockContainer, outportBlocksPool, dataAggregator)
publisher, err := factory.CreatePublisher(cr.config, cr.enableGrpcServer, blockContainer, blocksPool, dataAggregator)
if err != nil {
return fmt.Errorf("cannot create publisher: %w", err)
}

dataProcessor, err := process.NewDataProcessor(
publisher,
gogoProtoMarshaller,
outportBlocksPool,
blocksPool,
dataAggregator,
outportBlockConverter,
cr.config.DataPool.FirstCommitableBlock,
Expand Down Expand Up @@ -126,7 +126,7 @@ func (cr *connectorRunner) Run() error {
log.Error(err.Error())
}

err = outportBlocksPool.Close()
err = blocksPool.Close()
if err != nil {
log.Error(err.Error())
}
Expand Down

0 comments on commit 042f242

Please sign in to comment.