Documentation
Architecture
How the Tauri shell, React interface, and Rust backend fit together.
TableR combines a Tauri desktop shell, a React interface, and a Rust backend. The frontend talks to native services through Tauri commands and events; the backend manages connection pools and engine adapters.
React workspace
|
| Tauri commands and events
v
Rust application services
|
| connection pools and engine adapters
v
PostgreSQL / MySQL / SQLite / SQL Server / NoSQL / cloud databasesTechnology
| Layer | Stack |
|---|---|
| Desktop runtime | Tauri 2 |
| Frontend | React 19, TypeScript 5, Vite |
| Styling | Tailwind CSS 4 |
| Native backend | Rust, Tokio |
| Database access | SQLx + engine-specific Rust drivers |
| Editor & terminal | Monaco Editor, Xterm.js |
| Data & diagrams | TanStack Table, Recharts, XYFlow |
| State management | Zustand |
How a query flows
When you run a statement, the frontend query store issues a request with a unique id and the active connection. The Rust backend registers a cancellation token for that request, then executes the SQL on a driver for the target engine.
- 1Request
The frontend creates a request id, stores the active connection, and calls the matching Tauri command.
- 2Register
The backend registers a cancellation token for the request so it can be stopped later.
- 3Execute
On PostgreSQL and MySQL, the driver takes a dedicated pool connection and records its backend/connection id, then runs your SQL on that connection.
- 4Finish or cancel
Results return with timing, or a cancel request stops the wait — and, where supported, the statement on the server.
Cancellation
Cancelling unblocks the waiting request immediately. On PostgreSQL, TableR issues pg_cancel_backend over a second pool connection; on MySQL/MariaDB it issues KILL QUERY the same way, so the cancel does not queue behind the running statement. A drop guard always cleans up the registry entry, even on timeout or panic.
Connection pooling
PostgreSQL and MySQL pools are capped at eight connections. Cancellation deliberately uses a separate connection so it never waits behind the in-flight query. Desktop usage is single-user, so a dedicated connection during a cancellable query is an acceptable trade-off.
Project layout
TableR/
├─ src/ React + TypeScript UI (components, hooks, stores, utils)
├─ src-tauri/ Rust backend, Tauri config, command handlers, drivers
├─ docs/ Architecture, security, product, and release docs
├─ website/ Next.js product website (this site)
└─ package.json Frontend scripts and dependenciesTableR runs on your machine. Credentials live in the OS keyring, and your data does not pass through this website.