Cache, Store, and Serve All in One: Manage Your Website with SQLite Power

gc-victor

Víctor García

Posted on April 16, 2024

Cache, Store, and Serve All in One: Manage Your Website with SQLite Power

Query is a one-file system that uses SQLite to cover most of the full-stack development and infrastructure needs for small websites.

Query Mental Model

This is a mental model to guide you when working with Query.

  1. I do not need a database server (PostgreSQL or MySQL), as I can connect to my SQLite databases remotely using the Query APIs, the CLI, and the functions.
  2. I do not need a JavaScript runtime (NodeJS, Deno, or Bun), as Query offers its own.
  3. I do not need a JavaScript backend framework (NextJS, Remix or Astro), as Query provides functions to serve Pages and APIs.
  4. I do not need a caching system (Redis) for my function, as Query caches them in SQLite and serves them.
  5. I do not need a storage system (S3) for my assets, as Query stores them in SQLite and serves them.
  6. I do not need a scaffolding tool to generate code, as Query offers its own.
  7. I do not need to develop a back office admin area, thanks to the Query generator, as I can build one just by executing a command.
  8. I can deploy in a couple of seconds to Query.
  9. I can distribute it in multiple regions, thanks to Fly.io and LiteFS.

The following links are related to each mental model concept.

[1] Query API
[1] Shell
[1] Functions

[2] Query JavaScript Runtime
[2] Runtime Compatibility

[3] Functions
[3] File-System Based Router

[4] Query Cache Control

[5] Query Generator

[6] Assets

[7] Query Generator
[7] Query Generator Templates

[8] Query Function CLI
[8] Query Assets CLI

[9] Fly.io
[9] LiteFS

💖 💪 🙅 🚩
gc-victor
Víctor García

Posted on April 16, 2024

Join Our Newsletter. No Spam, Only the good stuff.

Sign up to receive the latest update from our blog.

Related