Skip to content

Embedded vs Server Mode

Talon supports two deployment modes to fit different use cases.

Embedded Mode

Directly link Talon as a Rust library. Zero network overhead, zero serialization cost.

rust
use talon::Talon;

let db = Talon::open("./data")?;
db.run_sql("SELECT 1")?;

Best for:

  • Desktop applications (Tauri, Electron with native bindings)
  • CLI tools
  • Edge/IoT devices
  • Single-process applications
  • Maximum performance (no network overhead)

Server Mode

Run Talon as a standalone server exposing HTTP, TCP, and Redis protocol interfaces.

bash
./talon-server --http-port 8080 --tcp-port 9090 --redis-port 6380

Protocols:

ProtocolPortUse Case
HTTP REST8080Web apps, microservices, any language
TCP Binary9090High-throughput Rust/C clients
Redis RESP6380KV operations via any Redis client

Best for:

  • Multi-language applications (Python, Node.js, Go, etc.)
  • Microservice architectures
  • Shared database across processes
  • Remote access

Feature Parity

Both modes expose identical functionality. Every engine API available in embedded mode has a corresponding HTTP endpoint in server mode.

FeatureEmbeddedServer
SQL Enginedb.run_sql()POST /api/sql
KV Enginedb.kv()?.set()POST /api/kv/set or Redis SET
Vector Searchdb.vector()?.search()POST /api/vector/search
FTSdb.fts()?.search()POST /api/fts/search
AI Enginedb.ai()?.create_session()POST /api/ai/session
Clusterdb.cluster_status()GET /cluster/status

Released under the MIT License.