When I originally read that this included a SQLite provider I was hoping to find out it was based on the SQLite archive format, I was just wondering if you'd consider using it?
https://www.sqlite.org/sqlar.html
It's pretty niche, but I think the biggest benefit I can see is that you'd be able to easily create pre-made VFS's and export ones created from NodeJS into a format that sqlite itself already has tooling to dealing with: sqlite3 -A / sqlar
The only downside I can see is your schema includes a lot more metadata (as you'd expect from a filesystem vs a zip-like archive) but because it is just a sqlite database at the end of the day, you can add your own custom tables for metadata along side the sqlar table.
You might even be able to add new columns for the missing metadata to the sqlar table itself, but I've not tested that.
CREATE TABLE sqlar(
name TEXT PRIMARY KEY, -- name of the file
mode INT, -- access permissions
mtime INT, -- last modification time
sz INT, -- original file size
data BLOB -- (optionally) compressed content
);
vs
CREATE TABLE IF NOT EXISTS entries (
path TEXT PRIMARY KEY,
parent_path TEXT,
name TEXT,
type INTEGER NOT NULL,
content BLOB,
target TEXT,
mode INTEGER NOT NULL,
mtime REAL NOT NULL,
ctime REAL NOT NULL,
birthtime REAL NOT NULL
);
When I originally read that this included a SQLite provider I was hoping to find out it was based on the SQLite archive format, I was just wondering if you'd consider using it?
https://www.sqlite.org/sqlar.html
It's pretty niche, but I think the biggest benefit I can see is that you'd be able to easily create pre-made VFS's and export ones created from NodeJS into a format that sqlite itself already has tooling to dealing with:
sqlite3 -A/sqlarThe only downside I can see is your schema includes a lot more metadata (as you'd expect from a filesystem vs a zip-like archive) but because it is just a sqlite database at the end of the day, you can add your own custom tables for metadata along side the
sqlartable.You might even be able to add new columns for the missing metadata to the
sqlartable itself, but I've not tested that.vs