496303471d
---ci--- project: atelier phase: 7 milestone: v0.1 status: complete phase_role: final milestone_complete: true requirements: covered: [ATELIER-01, ATELIER-02, ATELIER-03, ATELIER-04, ATELIER-05, ATELIER-06, ATELIER-07, ATELIER-08, ATELIER-09, ATELIER-10, ATELIER-11, ATELIER-12, ATELIER-13, ATELIER-14, ATELIER-15, ATELIER-16, ATELIER-17, ATELIER-18, ATELIER-19, ATELIER-20, ATELIER-21, ATELIER-22, ATELIER-23, ATELIER-24, ATELIER-25, ATELIER-26, ATELIER-27, ATELIER-28, ATELIER-29, ATELIER-30, ATELIER-31, ATELIER-32, ATELIER-33, ATELIER-34, ATELIER-35] partial: [] ship: milestone: v0.1 type: NFR tag: v0.0.7 merge: milestone/v0.1-atelier -> main release: https://git.cloudinit.dev/cloudinit-bot/atelier/releases/tag/v0.0.7 ---/ci--- Milestone v0.1 — Initial Framework (NFR, complete). 8 core principles (C1-C8), 11 domains, 110 domain principles, 27 derived docs, 4 good + 3 bad examples, 4 language docs, full matrix, 3 review docs. All 35 requirements covered. 7 patches (v0.0.0 pre-execution through v0.0.7 final). v0.0.7 IS the v0.1.0 milestone release.
43 lines
1.1 KiB
Markdown
43 lines
1.1 KiB
Markdown
# Data — First Principles
|
|
|
|
## 1. The Principles
|
|
|
|
### P1. Truth
|
|
The schema reflects the domain, not the application. If the data
|
|
model lies, every query lies.
|
|
|
|
### P2. Normalization Discipline
|
|
Duplication is a bug waiting to happen. The same fact lives in one
|
|
place.
|
|
|
|
### P3. Invariants in the Schema
|
|
Constraints live where the data lives. Application-layer checks are
|
|
defense, not enforcement.
|
|
|
|
### P4. Migration Safety
|
|
Schema changes are reversible, non-destructive, and tested. Production
|
|
data is sacred.
|
|
|
|
### P5. Indexing with Intent
|
|
Indexes exist for known query patterns. Every index earns its write
|
|
cost.
|
|
|
|
### P6. Naming Consistency
|
|
Same concept, same name, always. Across tables, columns, code, and
|
|
APIs.
|
|
|
|
### P7. Type Fidelity
|
|
Types match domain meaning. A `string` is rarely the right type for
|
|
an email, an ID, or a status.
|
|
|
|
### P8. Lifecycle Awareness
|
|
Data has a creation, a lifetime, and an end. Archival and deletion
|
|
are first-class.
|
|
|
|
### P9. Referential Integrity
|
|
Relationships are enforced, not assumed. Foreign keys exist. CASCADE
|
|
is intentional.
|
|
|
|
### P10. Performance Awareness
|
|
Schema choices have cost. Query plans are reviewed. Cardinality is
|
|
understood. |