Skip to content

Add Deep Core Style#4925

Open
cloutiertyler wants to merge 3 commits intomasterfrom
tyler/programming-standards
Open

Add Deep Core Style#4925
cloutiertyler wants to merge 3 commits intomasterfrom
tyler/programming-standards

Conversation

@cloutiertyler
Copy link
Copy Markdown
Contributor

@cloutiertyler cloutiertyler commented Apr 30, 2026

Summary

Adds docs/DEEP_CORE_STYLE.md, a style guide for the core of SpacetimeDB (datastore, commitlog, snapshotting, replication).

Read the rendered document

The document is organized around seven principles:

  1. Work towards zero dependencies
  2. Work towards deterministic simulation testing
  3. Work towards thread-per-core
  4. Work towards no_std
  5. Think in terms of persistent data structures
  6. Think in terms of pipelining
  7. Think in terms of unreliable processes

A short style section follows the principles, covering assertions, bounded loops and queues, error handling, control flow, naming, and formatting. Inspired by TIGER STYLE, narrowed and adapted for Rust and our principles.

This is a seed document. It will grow as we make the principles operational in code and as the practices that serve them become clearer with use.

Test plan

  • Read the document and review the principles
  • Discuss any principle the team disagrees with before merging

Replaces SPACETIME_PROGRAMMING_STANDARDS.md with DEEP_CORE_STYLE.md.
The document is reorganized around seven principles for the core
(datastore, commitlog, snapshotting, replication):

1. Work towards zero dependencies
2. Work towards deterministic simulation testing
3. Work towards thread-per-core
4. Work towards no_std
5. Think in terms of persistent data structures
6. Think in terms of pipelining
7. Think in terms of unreliable processes

A short style section follows the principles, covering assertions,
bounded loops and queues, error handling, control flow, naming, and
formatting.
@cloutiertyler cloutiertyler requested a review from aasoni May 1, 2026 14:39
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant