Skip to content

Commit 3dcbcdd

Browse files
committed
Remove unused files
1 parent dba7539 commit 3dcbcdd

File tree

4 files changed

+2
-223
lines changed

4 files changed

+2
-223
lines changed

internal/orchestrator/chain_tracker.go

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

internal/orchestrator/orchestrator.go

Lines changed: 0 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -87,16 +87,6 @@ func (o *Orchestrator) Start() {
8787
}()
8888
}
8989

90-
// The chain tracker is always running
91-
o.wg.Add(1)
92-
go func() {
93-
defer o.wg.Done()
94-
chainTracker := NewChainTracker(o.rpc)
95-
chainTracker.Start(ctx)
96-
97-
log.Info().Msg("Chain tracker completed")
98-
}()
99-
10090
// Waiting for all goroutines to complete
10191
o.wg.Wait()
10292

internal/orchestrator/work_mode_monitor.go

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

internal/rpc/rpc.go

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,7 @@ import (
1313
"github.com/rs/zerolog/log"
1414
config "github.com/thirdweb-dev/indexer/configs"
1515
"github.com/thirdweb-dev/indexer/internal/common"
16+
"github.com/thirdweb-dev/indexer/internal/metrics"
1617
)
1718

1819
type GetFullBlockResult struct {
@@ -305,6 +306,7 @@ func (rpc *Client) GetLatestBlockNumber(ctx context.Context) (*big.Int, error) {
305306
if err != nil {
306307
return nil, fmt.Errorf("failed to get latest block number: %v", err)
307308
}
309+
metrics.ChainHead.Set(float64(blockNumber))
308310
return new(big.Int).SetUint64(blockNumber), nil
309311
}
310312

0 commit comments

Comments
 (0)