Hacker News new | ask | show | jobs
by onetimeuse92304 941 days ago
Many decades ago, before we had files, we had data storages that do what you describe. They stored records of data. No need for files.

What happened, is we discovered that files are really useful because you don't need to declare the format of data that goes into the file. So the operating system can handle things like reading and writing and the application can organise how it wants to keep the data in the file.

The same really is for sockets. It is really useful to have somebody transfer the data for you in a stream and you, the application, only worry about the format of the data.

1 comments

A junior engineer on my team asked me why we store bytes in our Blobstore/Filesystem rather than something structured like a DB.

Bytes are a "narrow waist" and in-fact DBs actually use our system for storage. By supporting bytes, anything that can be serialized can be stored by the next layer up and the contract is very simple.