News for hackers. Stuff that matters.
Re:How Fast can A Single Instance of Redis be? by segmondy on Tuesday June 18, 2019 @04:16PM (#20217914)
Your filesystem then is a database. You can even stretch it to include your text editor. Redis is not a database.
Re:How Fast can A Single Instance of Redis be? by KenanSulayman on Tuesday June 18, 2019 @05:08PM (#20218428)
Of course the filesystem is a database. In fact, bank mainframes still use distributed file systems as “databases” where file writes are auditable and fully reversible transactions. (I worked on such systems.)
Re:How Fast can A Single Instance of Redis be? by im3w1l on Tuesday June 18, 2019 @06:48PM (#20219220)
I think there is much to be learned by comparing databases and filesystems.

One thing I think that filesystems can learn from databases is the notion of a compound primary key. It would be neat if app-files were identified by an (app, type, id) tuple. This would bring the advantages of both the posix and the windows filesystem layouts.

For instance if we had(app=firefox, type=/usr/bin, id=main). Then we could easily find all firefox files by querying by app. Or we could easily find all binaries in PATH by querying by type.

ps. I think this would work better than the overly general tag-based filesystem people sometimes propose.

Re:How Fast can A Single Instance of Redis be? by dvirsky on Wednesday June 19, 2019 @12:51AM (#20220885)
Well, that's basically what directories are.
Re:How Fast can A Single Instance of Redis be? by im3w1l on Wednesday June 19, 2019 @09:02AM (#20222872)
The posix filesystem layout doesn't provide an easy way of enumerate all files belonging to a given program. The traditional windows (98?) layout of one app in one folder conversely doesn't easily allow enumerating all binaries. Or all manual entries. Etc
Re:How Fast can A Single Instance of Redis be? by dvirsky on Thursday June 20, 2019 @03:13AM (#20230610)
Ok, so let's say you arrange your folders to acommodate for that. you have /files/$user/$program/$file. That's basically what a primary key in a database looks like. If you want a secondary index, what databases often do is just create a second table with a different primary key, with the value being primary keys of the main table.

We can model that in a filesystem as well, of course. So if I want one filtering by file type and one filtering by month of creation, then I can create /files/$program/$file and then ln -s /files/$program/$file /files/month/$month/$file

Re:How Fast can A Single Instance of Redis be? by markbnj on Tuesday June 18, 2019 @04:21PM (#20217970)
You could argue this endlessly from different perspectives, but it's not at all relevant to what the article actually discusses. They're comparing redis against itself, not other examples of things that might or might not be databases.
Re:How Fast can A Single Instance of Redis be? by sk5t on Tuesday June 18, 2019 @10:35PM (#20220370)
In a few years, you may look back and wonder, incredulously, that you ever felt a filesystem might not be a kind of database. Look into filesystems long enough, and you may start to view an RDBMS as a specialized kind of filesystem.
Re:How Fast can A Single Instance of Redis be? by futureastronaut on Tuesday June 18, 2019 @04:33PM (#20218082)
If you use it as such, of course it is. Filesystem DBs been around forever. What point are you trying to make?
Re:How Fast can A Single Instance of Redis be? by nkozyra on Tuesday June 18, 2019 @08:38PM (#20219877)
> Your filesystem then is a database.

Absolutely