Skip to main content

Crate m4a_product_example

Crate m4a_product_example 

Source
Expand description

The example product server: library surface (router + store) so a real product can reuse or replace each piece, and tests can run it in-process.

Re-exports§

pub use app::router;
pub use app::ProductApp;
pub use store::SqliteStore;

Modules§

app
HTTP surface of the example product server. /product/v1/* is the product’s own API; everything else goes through the signing link.
store
SQLite implementation of the kit’s UserStore: the example product’s own database. This is part of what a real product throws away (it has its own user database). The storage engine is tesserax-store (SQLCipher, one writer, WAL): every trait method is one short closure on the writer connection, so no lock outlives a call and no async request holds one across a call to the edge. The trait is synchronous, so callers on the async runtime reach it through spawn_blocking; the engine refuses to block a runtime thread.