Method
initScanner
(ctx context.Context, cfg *Config)
Source from the content-addressed store, hash-verified
| 328 | } |
| 329 | |
| 330 | func (n *EsNode) initScanner(ctx context.Context, cfg *Config) { |
| 331 | if cfg.Scanner == nil { |
| 332 | // not enabled |
| 333 | return |
| 334 | } |
| 335 | n.scanner = scanner.New( |
| 336 | ctx, |
| 337 | *cfg.Scanner, |
| 338 | n.storageManager, |
| 339 | n.p2pNode.FetchBlob, |
| 340 | n.l1Source, |
| 341 | n.feed, |
| 342 | n.lg, |
| 343 | ) |
| 344 | n.scanner.Start() |
| 345 | } |
| 346 | |
| 347 | func (n *EsNode) Start(ctx context.Context, cfg *Config) error { |
| 348 | n.startL1(cfg) |
Tested by
no test coverage detected