Remove or improve I/O ByteStream?
Created by: anonimal
By submitting this issue, I confirm the following:
- I have read and understood the contributor guide in kovri-docs.
- I have checked that the issue I am reporting can be replicated or that the feature I am suggesting is not present.
- I have checked opened or recently closed pull requests for existing solutions/implementations to my issue/suggestion.
From https://github.com/monero-project/kovri/pull/810
In all, I'm becoming very irritated with the bytestream implementation / concept as a whole. While #140 has had the best of intentions, the bytestream is building on - and revolving around - previous spaghetti-code pointer concepts rather then a usable, modular, OOP design. The current bytestream design also prevents us from managing memory in a more guaranteed and interoperable way.
- We should wrap existing libraries rather then trying to re-invent the wheel
- Instead of enabling bad designs by "streaming", we should allocate contiguous memory when it's needed - as this is a majority of ByteStream use-cases! If we really need need sinks, then use a real streaming library that guarantees memory safety!