Tessera docs

Launch Tessera

Launch

Database

Transactions

Group writes so they succeed or fail together.

Running a transaction

Wrap related writes in db.transaction(). If any statement throws, every write in the block is rolled back.

TypeScript
await db.transaction(async (tx) => {  const invoice = await tx.invoices.insert({ customerId, total })  await tx.balances.update(customerId, { owed: sql`owed + ${total}` })})

Isolation levels

Transactions default to read committed. Pass isolation: "serializable" for workflows that must never interleave.

Keep them short

Long transactions hold locks. Avoid network calls inside the callback; do them before or after.

Retries

Serialization failures are retried up to three times automatically. Make the callback safe to run more than once.

Was this helpful?

© 2026 Tessera, Inc.

Support

Status

Create a free website with Framer, the website builder loved by startups, designers and agencies.