IntersectMBO / IntersectMBO/ouroboros-network
data diffusion startup in cardano-node
- Dominant language
- Haskell
- Stars
- 296
- Forks
- 104
- Avg merge
- 2d 10h
- Merged PRs (30d)
- 4
Description
Currently the flow of data in `cardano-node` is not very clear. Partially the
confusion comes from the fact that `runDataDiffusion` is run by consensus
application. The current flow is:
_environment_ (genesis, config, cli options)
→ _consensus protocol setup_
→ _consensus options & network options_
→ _consensus_ starts data diffusion
Some network options go into consensus like network magic (it's needed to start
protocols), some not (node addresses for diffusion). We should have something
like this:
```
runDataDiffusion
∷ DiffusionArguments
→ (NetworkArgumentsRequiredByConsensus → m NodeToNodeProtocols)
→ m Void
```
`NetworkArgumentsRequiredByConsensus` would be passed as part of
`DiffusionArguments` and they can come from _environment_ (genesis, CLI args,
etc), without going through consensus setup first (the `protocolInfo` and
friends).
Contributor guide
Assessment
This issue has not been assessed yet.