For lightweight nodes, it use useful to be able to store and provide headers (or leaves), but never store payloads and other large stuff, and not worry about fetching anything we don't already have (since consensus guarantees that some lightweight nodes have every leaf, and the query service guarantees that an archival node will eventually get it as long as someone has it).
Add a LeafOnlyDataSource which wraps an AvailabilityStorage + NodeStorage in the same way as FetchingDataSource, but LeafOnlyDataSource
For lightweight nodes, it use useful to be able to store and provide headers (or leaves), but never store payloads and other large stuff, and not worry about fetching anything we don't already have (since consensus guarantees that some lightweight nodes have every leaf, and the query service guarantees that an archival node will eventually get it as long as someone has it).
Add a
LeafOnlyDataSource
which wraps anAvailabilityStorage + NodeStorage
in the same way asFetchingDataSource
, butLeafOnlyDataSource