Daemon HTTP Endpoints: The Wire Contract
A walk through the actual HTTP surface mongreldb-server exposes, from /sql and /txn to sessions, pagination cursors, and the /kit/* typed routes, and why plain HTTP was the right transport bet.
10 posts filed under core.
A walk through the actual HTTP surface mongreldb-server exposes, from /sql and /txn to sessions, pagination cursors, and the /kit/* typed routes, and why plain HTTP was the right transport bet.
MongrelDB ships as one compiled binary per platform and one shared library per ABI, with cluster and cloud integrations excluded at compile time, and that shape is an economic decision as much as an engineering one.
MongrelDB evaluates unique, foreign-key, and CHECK constraints atomically at transaction commit instead of per statement, which changes what a batch import can promise and what it has to fear.
A JSON column in MongrelDB is a typed column that the engine validates at write time and queries from the inside, so the schema-versus-schemaless argument stops being a binary you have to pick a side of.
A column type is not documentation, it is a promise the storage engine can spend, and MongrelDB's type system covers fixed-width integers, decimal128 money, five flavors of time, sortable UUIDs, native JSON, and typed arrays so the engine can plan bytes instead of guessing at strings.
A pure embedded engine never has to think about other processes, but MongrelDB is also a server, so it takes an exclusive advisory lock at open, fails fast by default, waits politely when you ask it to, and pushes genuine multi-process access through the daemon instead of through the filesystem.
Most database auth lives in middleware, which means every code path that skips the middleware skips the auth. MongrelDB stores Argon2id-hashed users and roles in the catalog and can enforce permissions on every transaction at the storage layer itself.
MongrelDB reconstructs change events from its own WAL and streams committed records to follower copies, so an embedded database can participate in replication and change data capture without bolting on a separate toolchain.
MongrelDB binds idempotency keys into the commit log itself, so a retried write is safe across process crashes and restarts, not just across network drops.
MongrelDB separates accepted writes from fsync-backed durable commits, batches WAL work with group commit, and flushes log-structured columnar runs later.