@@ -129,19 +129,11 @@ func (s *Submitter) Start(ctx context.Context) error {
129129 // Start DA submission loop if signer is available (aggregator nodes only)
130130 if s .signer != nil {
131131 s .logger .Info ().Msg ("starting DA submission loop" )
132- s .wg .Add (1 )
133- go func () {
134- defer s .wg .Done ()
135- s .daSubmissionLoop ()
136- }()
132+ s .wg .Go (s .daSubmissionLoop )
137133 }
138134
139135 // Start DA inclusion processing loop (both sync and aggregator nodes)
140- s .wg .Add (1 )
141- go func () {
142- defer s .wg .Done ()
143- s .processDAInclusionLoop ()
144- }()
136+ s .wg .Go (s .processDAInclusionLoop )
145137
146138 return nil
147139}
@@ -345,9 +337,9 @@ func (s *Submitter) processDAInclusionLoop() {
345337
346338 s .logger .Debug ().Uint64 ("height" , nextHeight ).Msg ("advancing DA included height" )
347339
348- // Set sequencer height to DA height mapping using already retrieved data
349- if err := s .setSequencerHeightToDAHeight (s .ctx , nextHeight , header , data , currentDAIncluded == 0 ); err != nil {
350- s .logger .Error ().Err (err ).Uint64 ("height" , nextHeight ).Msg ("failed to set sequencer height to DA height mapping" )
340+ // Set node height to DA height mapping using already retrieved data
341+ if err := s .setNodeHeightToDAHeight (s .ctx , nextHeight , header , data , currentDAIncluded == 0 ); err != nil {
342+ s .logger .Error ().Err (err ).Uint64 ("height" , nextHeight ).Msg ("failed to set node height to DA height mapping" )
351343 break
352344 }
353345
@@ -435,14 +427,14 @@ func (s *Submitter) sendCriticalError(err error) {
435427 }
436428}
437429
438- // setSequencerHeightToDAHeight stores the mapping from a ev-node block height to the corresponding
430+ // setNodeHeightToDAHeight stores the mapping from a ev-node block height to the corresponding
439431// DA (Data Availability) layer heights where the block's header and data were included.
440432// This mapping is persisted in the store metadata and is used to track which DA heights
441433// contain the block components for a given ev-node height.
442434//
443435// For blocks with empty transactions, both header and data use the same DA height since
444436// empty transaction data is not actually published to the DA layer.
445- func (s * Submitter ) setSequencerHeightToDAHeight (ctx context.Context , height uint64 , header * types.SignedHeader , data * types.Data , genesisInclusion bool ) error {
437+ func (s * Submitter ) setNodeHeightToDAHeight (ctx context.Context , height uint64 , header * types.SignedHeader , data * types.Data , genesisInclusion bool ) error {
446438 headerHash , dataHash := header .Hash (), data .DACommitment ()
447439
448440 headerDaHeightBytes := make ([]byte , 8 )
0 commit comments