@radicaltools/mcp 0.2.0 → 0.3.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +41 -23
- package/dist/{chunk-OGN3UW2D.js → chunk-2SZDTOYJ.js} +727 -89
- package/dist/{elkLayout-S62RLGTO.js → elkLayout-VYJDCCIT.js} +1 -1
- package/dist/hub-catalogue/concern/concern-api-collections.radical +1136 -0
- package/dist/hub-catalogue/concern/concern-api-errors.radical +1180 -0
- package/dist/hub-catalogue/concern/concern-api-evolution.radical +1174 -0
- package/dist/hub-catalogue/concern/concern-api-idempotency.radical +1218 -0
- package/dist/hub-catalogue/concern/concern-api-resource-design.radical +1102 -0
- package/dist/hub-catalogue/concern/concern-api-style-guide.radical +1210 -0
- package/dist/hub-catalogue/concern/concern-architecture-style.radical +1268 -0
- package/dist/hub-catalogue/concern/concern-audit-trail.radical +1096 -0
- package/dist/hub-catalogue/concern/concern-authentication.radical +895 -0
- package/dist/hub-catalogue/concern/concern-authorization.radical +1686 -0
- package/dist/hub-catalogue/concern/concern-availability.radical +1028 -0
- package/dist/hub-catalogue/concern/concern-backend-stack.radical +1037 -0
- package/dist/hub-catalogue/concern/concern-backup-recovery.radical +1560 -0
- package/dist/hub-catalogue/concern/concern-caching.radical +1294 -0
- package/dist/hub-catalogue/concern/concern-capacity.radical +915 -0
- package/dist/hub-catalogue/concern/concern-code-documentation.radical +1397 -0
- package/dist/hub-catalogue/concern/concern-code-quality-gate.radical +1409 -0
- package/dist/hub-catalogue/concern/concern-code-review-branching.radical +1416 -0
- package/dist/hub-catalogue/concern/concern-code-style.radical +1058 -0
- package/dist/hub-catalogue/concern/concern-communication-style.radical +1508 -0
- package/dist/hub-catalogue/concern/concern-data-classification.radical +970 -0
- package/dist/hub-catalogue/concern/concern-data-consistency.radical +1112 -0
- package/dist/hub-catalogue/concern/concern-data-store.radical +1282 -0
- package/dist/hub-catalogue/concern/concern-decomposition.radical +1318 -0
- package/dist/hub-catalogue/concern/concern-definition-of-done.radical +1214 -0
- package/dist/hub-catalogue/concern/concern-delivery-metrics.radical +966 -0
- package/dist/hub-catalogue/concern/concern-dependency-hygiene.radical +1345 -0
- package/dist/hub-catalogue/concern/concern-deployment.radical +1203 -0
- package/dist/hub-catalogue/concern/concern-encryption.radical +1318 -0
- package/dist/hub-catalogue/concern/concern-error-handling-logging.radical +1197 -0
- package/dist/hub-catalogue/concern/concern-eu-dora.radical +1321 -0
- package/dist/hub-catalogue/concern/concern-frontend-stack.radical +1647 -0
- package/dist/hub-catalogue/concern/concern-incident-management.radical +1204 -0
- package/dist/hub-catalogue/concern/concern-infrastructure.radical +2183 -0
- package/dist/hub-catalogue/concern/concern-integration-resilience.radical +1116 -0
- package/dist/hub-catalogue/concern/concern-messaging.radical +973 -0
- package/dist/hub-catalogue/concern/concern-module-boundaries.radical +867 -0
- package/dist/hub-catalogue/concern/concern-observability.radical +997 -0
- package/dist/hub-catalogue/concern/concern-operational-readiness.radical +1249 -0
- package/dist/hub-catalogue/concern/concern-personal-data.radical +1949 -0
- package/dist/hub-catalogue/concern/concern-quality-priorities.radical +1091 -0
- package/dist/hub-catalogue/concern/concern-rate-limiting.radical +1445 -0
- package/dist/hub-catalogue/concern/concern-release-versioning.radical +1358 -0
- package/dist/hub-catalogue/concern/concern-retention.radical +1399 -0
- package/dist/hub-catalogue/concern/concern-secrets.radical +1284 -0
- package/dist/hub-catalogue/concern/concern-secure-coding.radical +1379 -0
- package/dist/hub-catalogue/concern/concern-secure-development.radical +1245 -0
- package/dist/hub-catalogue/concern/concern-security-detection.radical +1153 -0
- package/dist/hub-catalogue/concern/concern-supply-chain.radical +1386 -0
- package/dist/hub-catalogue/concern/concern-technical-debt.radical +1450 -0
- package/dist/hub-catalogue/concern/concern-technology-lifecycle.radical +1145 -0
- package/dist/hub-catalogue/concern/concern-tenant-isolation.radical +1440 -0
- package/dist/hub-catalogue/concern/concern-test-strategy.radical +1212 -0
- package/dist/hub-catalogue/concern/concern-threat-modelling.radical +1143 -0
- package/dist/index.js +10321 -3964
- package/package.json +1 -1
- package/dist/hub-catalogue/adr/adr-api-versioning.radical +0 -53
- package/dist/hub-catalogue/adr/adr-auth-strategy.radical +0 -53
- package/dist/hub-catalogue/adr/adr-caching-strategy.radical +0 -59
- package/dist/hub-catalogue/adr/adr-data-consistency-model.radical +0 -40
- package/dist/hub-catalogue/adr/adr-data-store.radical +0 -47
- package/dist/hub-catalogue/adr/adr-deployment-strategy.radical +0 -53
- package/dist/hub-catalogue/adr/adr-event-schema-evolution.radical +0 -53
- package/dist/hub-catalogue/adr/adr-integration-style.radical +0 -50
- package/dist/hub-catalogue/adr/adr-ledger-reconciliation-strategy.radical +0 -38
- package/dist/hub-catalogue/adr/adr-llm-provider-strategy.radical +0 -40
- package/dist/hub-catalogue/adr/adr-marketplace-payments-model.radical +0 -39
- package/dist/hub-catalogue/adr/adr-multi-region.radical +0 -60
- package/dist/hub-catalogue/adr/adr-multi-tenancy-strategy.radical +0 -41
- package/dist/hub-catalogue/adr/adr-observability.radical +0 -59
- package/dist/hub-catalogue/adr/adr-realtime-transport.radical +0 -38
- package/dist/hub-catalogue/adr/adr-tech-stack.radical +0 -45
- package/dist/hub-catalogue/adr/adr-zero-trust-network.radical +0 -40
- package/dist/hub-catalogue/blueprint/bp-ai-assistant-platform.radical +0 -1641
- package/dist/hub-catalogue/blueprint/bp-analytical-data-platform.radical +0 -1428
- package/dist/hub-catalogue/blueprint/bp-ecommerce-platform.radical +0 -1989
- package/dist/hub-catalogue/blueprint/bp-fintech-ledger-platform.radical +0 -1701
- package/dist/hub-catalogue/blueprint/bp-marketplace-platform.radical +0 -1792
- package/dist/hub-catalogue/blueprint/bp-realtime-collaboration.radical +0 -1421
- package/dist/hub-catalogue/blueprint/bp-saas-b2b-platform.radical +0 -1713
- package/dist/hub-catalogue/fitness-function/ff-accessibility-scan.radical +0 -34
- package/dist/hub-catalogue/fitness-function/ff-ai-eval-gate.radical +0 -52
- package/dist/hub-catalogue/fitness-function/ff-api-contract.radical +0 -36
- package/dist/hub-catalogue/fitness-function/ff-capacity-load-test.radical +0 -67
- package/dist/hub-catalogue/fitness-function/ff-carbon-footprint-guard.radical +0 -62
- package/dist/hub-catalogue/fitness-function/ff-change-failure-rate.radical +0 -45
- package/dist/hub-catalogue/fitness-function/ff-chaos-resilience-test.radical +0 -53
- package/dist/hub-catalogue/fitness-function/ff-cost-efficiency-guard.radical +0 -64
- package/dist/hub-catalogue/fitness-function/ff-coupling-guard.radical +0 -45
- package/dist/hub-catalogue/fitness-function/ff-data-integrity-check.radical +0 -51
- package/dist/hub-catalogue/fitness-function/ff-data-residency.radical +0 -43
- package/dist/hub-catalogue/fitness-function/ff-dependency-rules.radical +0 -37
- package/dist/hub-catalogue/fitness-function/ff-deploy-frequency.radical +0 -46
- package/dist/hub-catalogue/fitness-function/ff-dr-drill-success.radical +0 -52
- package/dist/hub-catalogue/fitness-function/ff-duplication-guard.radical +0 -53
- package/dist/hub-catalogue/fitness-function/ff-error-budget.radical +0 -59
- package/dist/hub-catalogue/fitness-function/ff-fail-safe-verification.radical +0 -34
- package/dist/hub-catalogue/fitness-function/ff-infra-drift.radical +0 -34
- package/dist/hub-catalogue/fitness-function/ff-latency-slo.radical +0 -59
- package/dist/hub-catalogue/fitness-function/ff-lead-time.radical +0 -44
- package/dist/hub-catalogue/fitness-function/ff-ledger-balance-integrity.radical +0 -45
- package/dist/hub-catalogue/fitness-function/ff-license-compliance.radical +0 -43
- package/dist/hub-catalogue/fitness-function/ff-mttr.radical +0 -45
- package/dist/hub-catalogue/fitness-function/ff-noisy-neighbor-guard.radical +0 -66
- package/dist/hub-catalogue/fitness-function/ff-sast-scan.radical +0 -35
- package/dist/hub-catalogue/fitness-function/ff-scale-out-verification.radical +0 -66
- package/dist/hub-catalogue/fitness-function/ff-security-scan.radical +0 -45
- package/dist/hub-catalogue/fitness-function/ff-startup-shutdown-check.radical +0 -66
- package/dist/hub-catalogue/fitness-function/ff-sync-convergence-test.radical +0 -45
- package/dist/hub-catalogue/fitness-function/ff-test-coverage.radical +0 -43
- package/dist/hub-catalogue/fitness-function/ff-web-vitals.radical +0 -57
- package/dist/hub-catalogue/pattern/pattern-anti-corruption-layer.radical +0 -88
- package/dist/hub-catalogue/pattern/pattern-api-gateway.radical +0 -168
- package/dist/hub-catalogue/pattern/pattern-bff.radical +0 -179
- package/dist/hub-catalogue/pattern/pattern-bulkhead.radical +0 -114
- package/dist/hub-catalogue/pattern/pattern-circuit-breaker.radical +0 -219
- package/dist/hub-catalogue/pattern/pattern-cqrs.radical +0 -195
- package/dist/hub-catalogue/pattern/pattern-crdt-sync.radical +0 -200
- package/dist/hub-catalogue/pattern/pattern-event-driven.radical +0 -210
- package/dist/hub-catalogue/pattern/pattern-event-sourced-ledger.radical +0 -211
- package/dist/hub-catalogue/pattern/pattern-hexagonal.radical +0 -196
- package/dist/hub-catalogue/pattern/pattern-microservices.radical +0 -262
- package/dist/hub-catalogue/pattern/pattern-rag-pipeline.radical +0 -213
- package/dist/hub-catalogue/pattern/pattern-rate-limiter.radical +0 -114
- package/dist/hub-catalogue/pattern/pattern-saga.radical +0 -208
- package/dist/hub-catalogue/pattern/pattern-sidecar.radical +0 -123
- package/dist/hub-catalogue/pattern/pattern-strangler-fig.radical +0 -227
- package/dist/hub-catalogue/pattern/pattern-transactional-outbox.radical +0 -209
- package/dist/hub-catalogue/requirement/req-accessibility.radical +0 -48
- package/dist/hub-catalogue/requirement/req-ai-autonomous-resolution.radical +0 -51
- package/dist/hub-catalogue/requirement/req-ai-groundedness.radical +0 -45
- package/dist/hub-catalogue/requirement/req-ai-human-handoff.radical +0 -46
- package/dist/hub-catalogue/requirement/req-alerting.radical +0 -52
- package/dist/hub-catalogue/requirement/req-api-response-time.radical +0 -51
- package/dist/hub-catalogue/requirement/req-api-standard.radical +0 -45
- package/dist/hub-catalogue/requirement/req-audit-logging.radical +0 -43
- package/dist/hub-catalogue/requirement/req-auth-response-time.radical +0 -45
- package/dist/hub-catalogue/requirement/req-auth.radical +0 -43
- package/dist/hub-catalogue/requirement/req-autoscaling.radical +0 -62
- package/dist/hub-catalogue/requirement/req-availability.radical +0 -50
- package/dist/hub-catalogue/requirement/req-backward-compatibility.radical +0 -46
- package/dist/hub-catalogue/requirement/req-batch-job-completion.radical +0 -50
- package/dist/hub-catalogue/requirement/req-carbon-efficiency.radical +0 -64
- package/dist/hub-catalogue/requirement/req-centralised-logging.radical +0 -45
- package/dist/hub-catalogue/requirement/req-ci-pipeline-time.radical +0 -43
- package/dist/hub-catalogue/requirement/req-code-complexity.radical +0 -43
- package/dist/hub-catalogue/requirement/req-config-propagation.radical +0 -45
- package/dist/hub-catalogue/requirement/req-data-integrity.radical +0 -35
- package/dist/hub-catalogue/requirement/req-data-retention.radical +0 -44
- package/dist/hub-catalogue/requirement/req-db-query-response.radical +0 -44
- package/dist/hub-catalogue/requirement/req-disaster-recovery.radical +0 -59
- package/dist/hub-catalogue/requirement/req-distributed-tracing.radical +0 -45
- package/dist/hub-catalogue/requirement/req-encryption.radical +0 -49
- package/dist/hub-catalogue/requirement/req-error-rate.radical +0 -45
- package/dist/hub-catalogue/requirement/req-error-recovery.radical +0 -34
- package/dist/hub-catalogue/requirement/req-event-schema-compatibility.radical +0 -37
- package/dist/hub-catalogue/requirement/req-fail-safe-default.radical +0 -55
- package/dist/hub-catalogue/requirement/req-fast-startup-graceful-shutdown.radical +0 -69
- package/dist/hub-catalogue/requirement/req-gdpr-erasure.radical +0 -44
- package/dist/hub-catalogue/requirement/req-graceful-degradation.radical +0 -39
- package/dist/hub-catalogue/requirement/req-health-checks.radical +0 -43
- package/dist/hub-catalogue/requirement/req-iac.radical +0 -36
- package/dist/hub-catalogue/requirement/req-idempotency.radical +0 -47
- package/dist/hub-catalogue/requirement/req-input-validation.radical +0 -37
- package/dist/hub-catalogue/requirement/req-least-privilege.radical +0 -47
- package/dist/hub-catalogue/requirement/req-ledger-immutability.radical +0 -38
- package/dist/hub-catalogue/requirement/req-mfa.radical +0 -36
- package/dist/hub-catalogue/requirement/req-ml-extraction-accuracy.radical +0 -42
- package/dist/hub-catalogue/requirement/req-onboarding-time.radical +0 -42
- package/dist/hub-catalogue/requirement/req-page-load-time.radical +0 -59
- package/dist/hub-catalogue/requirement/req-payout-latency.radical +0 -46
- package/dist/hub-catalogue/requirement/req-presence-latency.radical +0 -46
- package/dist/hub-catalogue/requirement/req-rate-limiting.radical +0 -45
- package/dist/hub-catalogue/requirement/req-report-generation.radical +0 -44
- package/dist/hub-catalogue/requirement/req-resource-efficiency.radical +0 -64
- package/dist/hub-catalogue/requirement/req-resource-headroom.radical +0 -53
- package/dist/hub-catalogue/requirement/req-resource-isolation.radical +0 -37
- package/dist/hub-catalogue/requirement/req-search-response-time.radical +0 -44
- package/dist/hub-catalogue/requirement/req-secrets-management.radical +0 -45
- package/dist/hub-catalogue/requirement/req-task-success-rate.radical +0 -42
- package/dist/hub-catalogue/requirement/req-test-coverage.radical +0 -42
- package/dist/hub-catalogue/requirement/req-throughput.radical +0 -55
- package/dist/hub-catalogue/requirement/req-vulnerability-scanning.radical +0 -52
- package/dist/hub-catalogue/requirement/req-zero-downtime-deploy.radical +0 -39
|
@@ -0,0 +1,1282 @@
|
|
|
1
|
+
{
|
|
2
|
+
"hub": {
|
|
3
|
+
"id": "concern-data-store",
|
|
4
|
+
"category": "concern",
|
|
5
|
+
"name": "Data store",
|
|
6
|
+
"description": "Which kind of data store keeps the element's data and which product, how consistent reads are, who runs the engine, and how its schema changes.",
|
|
7
|
+
"tags": [
|
|
8
|
+
"technology",
|
|
9
|
+
"database",
|
|
10
|
+
"data store",
|
|
11
|
+
"postgresql",
|
|
12
|
+
"mongodb",
|
|
13
|
+
"dynamodb",
|
|
14
|
+
"redis",
|
|
15
|
+
"schema migrations"
|
|
16
|
+
],
|
|
17
|
+
"requiredMetamodel": "c4-ddd-governance-builtin",
|
|
18
|
+
"concern": {
|
|
19
|
+
"id": "data-store",
|
|
20
|
+
"trigger": "LIST NODES WHERE type = \"database\" AND external != true",
|
|
21
|
+
"why": "these elements keep the system's data, so the kind of store, the product, who runs it and how its schema changes have to be decided.",
|
|
22
|
+
"group": "technology"
|
|
23
|
+
},
|
|
24
|
+
"sources": [
|
|
25
|
+
{
|
|
26
|
+
"title": "Pramod Sadalage, Martin Fowler: Evolutionary Database Design",
|
|
27
|
+
"url": "https://martinfowler.com/articles/evodb.html"
|
|
28
|
+
},
|
|
29
|
+
{
|
|
30
|
+
"title": "Martin Fowler: PolyglotPersistence",
|
|
31
|
+
"url": "https://martinfowler.com/bliki/PolyglotPersistence.html"
|
|
32
|
+
},
|
|
33
|
+
{
|
|
34
|
+
"title": "Martin Kleppmann: Designing Data-Intensive Applications",
|
|
35
|
+
"url": "https://dataintensive.net/"
|
|
36
|
+
},
|
|
37
|
+
{
|
|
38
|
+
"title": "endoflife.date: database support lifecycles",
|
|
39
|
+
"url": "https://endoflife.date/"
|
|
40
|
+
},
|
|
41
|
+
{
|
|
42
|
+
"title": "PostgreSQL versioning policy",
|
|
43
|
+
"url": "https://www.postgresql.org/support/versioning/"
|
|
44
|
+
},
|
|
45
|
+
{
|
|
46
|
+
"title": "PostgreSQL documentation: constraints",
|
|
47
|
+
"url": "https://www.postgresql.org/docs/current/ddl-constraints.html"
|
|
48
|
+
},
|
|
49
|
+
{
|
|
50
|
+
"title": "Amazon DynamoDB best practices",
|
|
51
|
+
"url": "https://docs.aws.amazon.com/amazondynamodb/latest/developerguide/best-practices.html"
|
|
52
|
+
},
|
|
53
|
+
{
|
|
54
|
+
"title": "MongoDB schema validation",
|
|
55
|
+
"url": "https://www.mongodb.com/docs/manual/core/schema-validation/"
|
|
56
|
+
},
|
|
57
|
+
{
|
|
58
|
+
"title": "MongoDB: the Schema Versioning pattern",
|
|
59
|
+
"url": "https://www.mongodb.com/blog/post/building-with-patterns-the-schema-versioning-pattern"
|
|
60
|
+
},
|
|
61
|
+
{
|
|
62
|
+
"title": "Regulation (EU) 2022/2554 (DORA), Art. 28: ICT third-party risk and exit strategies",
|
|
63
|
+
"url": "https://eur-lex.europa.eu/eli/reg/2022/2554/oj"
|
|
64
|
+
}
|
|
65
|
+
],
|
|
66
|
+
"templateParams": [
|
|
67
|
+
{
|
|
68
|
+
"key": "MODEL",
|
|
69
|
+
"title": "Data model",
|
|
70
|
+
"label": "What kind of store keeps the data?",
|
|
71
|
+
"hint": "The data model decides which queries are easy, which are expensive and which are impossible. Choose by how the data is read and changed, not by fashion.",
|
|
72
|
+
"defaultValue": "relational",
|
|
73
|
+
"options": [
|
|
74
|
+
{
|
|
75
|
+
"value": "relational",
|
|
76
|
+
"label": "a relational database (PostgreSQL or MySQL)",
|
|
77
|
+
"description": "Tables, joins, constraints and transactions across rows. Pick it by default, and whenever the data is related, queried in ways not all known up front (reports, search, back office), or must stay consistent across entities."
|
|
78
|
+
},
|
|
79
|
+
{
|
|
80
|
+
"value": "document",
|
|
81
|
+
"label": "a document database (MongoDB)",
|
|
82
|
+
"description": "Each aggregate is one JSON document read and written whole. Pick it when the data is naturally a tree read by id, its shape varies between records, and queries across documents are few and known."
|
|
83
|
+
},
|
|
84
|
+
{
|
|
85
|
+
"value": "keyvalue",
|
|
86
|
+
"label": "a key-value store (DynamoDB or Redis)",
|
|
87
|
+
"description": "Items read and written by key, with access patterns designed up front. Pick it for very high volume with a few known lookups (sessions, carts, counters, device state) needing single-digit-millisecond latency at any scale. DynamoDB is only managed; self-hosting means Redis or Valkey."
|
|
88
|
+
}
|
|
89
|
+
]
|
|
90
|
+
},
|
|
91
|
+
{
|
|
92
|
+
"key": "CONSISTENCY",
|
|
93
|
+
"title": "Consistency",
|
|
94
|
+
"label": "How consistent must reads be?",
|
|
95
|
+
"hint": "Strong consistency is simplest to program against; eventual consistency buys scale, availability and replicas in other regions at the cost of reading old data for a while.",
|
|
96
|
+
"defaultValue": "strong",
|
|
97
|
+
"options": [
|
|
98
|
+
{
|
|
99
|
+
"value": "strong",
|
|
100
|
+
"label": "strong, with transactions",
|
|
101
|
+
"description": "A read sees every committed write, and a business operation commits all of its changes or none. Pick it when money, stock or anything counted is involved, or users must see their own changes at once."
|
|
102
|
+
},
|
|
103
|
+
{
|
|
104
|
+
"value": "eventual",
|
|
105
|
+
"label": "eventual, with a bound on staleness",
|
|
106
|
+
"description": "Replicas and indexes may lag the primary by a bounded time, asked below. Pick it for read-heavy data that may be seconds old (catalogues, feeds, analytics) or replicas in several regions."
|
|
107
|
+
}
|
|
108
|
+
]
|
|
109
|
+
},
|
|
110
|
+
{
|
|
111
|
+
"key": "HOSTING",
|
|
112
|
+
"title": "Hosting",
|
|
113
|
+
"label": "Who runs the engine?",
|
|
114
|
+
"hint": "Running a database well means patching, failover, backups, monitoring and tuning, at any hour. The engine's hosting is decided here, not in the Infrastructure pack.",
|
|
115
|
+
"defaultValue": "managed",
|
|
116
|
+
"options": [
|
|
117
|
+
{
|
|
118
|
+
"value": "managed",
|
|
119
|
+
"label": "a managed cloud service",
|
|
120
|
+
"description": "Amazon RDS or Aurora, Azure Database, Cloud SQL, MongoDB Atlas, DynamoDB or ElastiCache run the engine. Pick it when the team has no database operators, or runs in a public cloud already."
|
|
121
|
+
},
|
|
122
|
+
{
|
|
123
|
+
"value": "self",
|
|
124
|
+
"label": "self-hosted by us",
|
|
125
|
+
"description": "We run the engine on our Kubernetes (CloudNativePG, Percona or MongoDB operators) or virtual machines (Patroni). Pick it when data must stay on premises, a provider is ruled out, or the scale makes a managed service too costly, and people with the skills are on call. With a key-value store this means Redis or Valkey, not DynamoDB."
|
|
126
|
+
}
|
|
127
|
+
]
|
|
128
|
+
},
|
|
129
|
+
{
|
|
130
|
+
"key": "MIGRATIONS",
|
|
131
|
+
"title": "Schema changes",
|
|
132
|
+
"label": "How does the schema change?",
|
|
133
|
+
"hint": "The schema will change many times while the system runs; each change has to be repeatable in every environment and safe for the code still running. Only when the store has a schema to migrate: a key-value store's tables and indexes are infrastructure code, and its item shapes carry a version.",
|
|
134
|
+
"defaultValue": "tool",
|
|
135
|
+
"options": [
|
|
136
|
+
{
|
|
137
|
+
"value": "tool",
|
|
138
|
+
"label": "a versioned migration tool (Flyway or Liquibase)",
|
|
139
|
+
"description": "Numbered SQL (or changelog) migrations kept with the code, applied by the deploy. Pick it for relational stores, especially when several applications or languages share the tooling or DBAs review SQL; for MongoDB, Liquibase with its MongoDB extension. Not with a key-value store."
|
|
140
|
+
},
|
|
141
|
+
{
|
|
142
|
+
"value": "orm",
|
|
143
|
+
"label": "the ORM's migrations (Prisma, EF Core, Alembic, Django)",
|
|
144
|
+
"description": "Migrations generated from the model in code and applied by the deploy. Pick it when one application owns a relational store and its ORM generates migrations the team reviews. Not with a document or key-value store: Prisma and Mongoose generate no migrations for MongoDB."
|
|
145
|
+
},
|
|
146
|
+
{
|
|
147
|
+
"value": "lazy",
|
|
148
|
+
"label": "a schema version per record, upgraded in code",
|
|
149
|
+
"description": "Each document or item carries its schema version; code upgrades old records when it reads them, and a backfill catches up. Pick it for document and key-value stores with large collections where rewriting everything at once is too costly. Not with a relational database."
|
|
150
|
+
}
|
|
151
|
+
]
|
|
152
|
+
},
|
|
153
|
+
{
|
|
154
|
+
"key": "STALE_SECONDS",
|
|
155
|
+
"label": "How old may a read be when consistency is eventual (seconds)? Used only with eventual consistency",
|
|
156
|
+
"defaultValue": "5",
|
|
157
|
+
"type": "number"
|
|
158
|
+
},
|
|
159
|
+
{
|
|
160
|
+
"key": "P99_MS",
|
|
161
|
+
"label": "What 99th-percentile latency must key lookups meet (ms)? Used only with a key-value store",
|
|
162
|
+
"defaultValue": "20",
|
|
163
|
+
"type": "number"
|
|
164
|
+
}
|
|
165
|
+
]
|
|
166
|
+
},
|
|
167
|
+
"nodes": [
|
|
168
|
+
{
|
|
169
|
+
"id": "need",
|
|
170
|
+
"type": "need",
|
|
171
|
+
"label": "Data kept in the right store",
|
|
172
|
+
"x": 0,
|
|
173
|
+
"y": 0,
|
|
174
|
+
"kind": "brief",
|
|
175
|
+
"source": "Hub concern pack: Data store",
|
|
176
|
+
"description": "The element keeps data the system depends on. It has to be kept in a store whose data model fits the way the data is read and changed, consistent where it must be, run by people who can keep it healthy, and able to change shape many times while the system stays online. The choice and its reasons must be written down, because data is far harder to move later than code. The checks assume one repository per element with SQL migrations in db/migration, Prisma migrations in prisma/migrations, a Liquibase changelog in db/changelog.xml with its jars in db/lib, request-handling code under src/ and batch jobs under src/jobs/."
|
|
177
|
+
},
|
|
178
|
+
{
|
|
179
|
+
"id": "req-access-patterns",
|
|
180
|
+
"type": "requirement",
|
|
181
|
+
"label": "Queries designed, not scanned",
|
|
182
|
+
"x": 260,
|
|
183
|
+
"y": 0,
|
|
184
|
+
"ears_type": "ubiquitous",
|
|
185
|
+
"action": "list every query the element makes in an access-pattern catalogue with its expected volume, serve each from a key or index designed for it, and make 0 Scan or KEYS calls on a request path",
|
|
186
|
+
"rationale": "A key-value store fits only when every query is a known lookup; a scan that is fast at launch is a time-out a year later (DynamoDB best practices: design for access patterns; Fowler, PolyglotPersistence).",
|
|
187
|
+
"hubWhen": {
|
|
188
|
+
"MODEL": [
|
|
189
|
+
"keyvalue"
|
|
190
|
+
]
|
|
191
|
+
}
|
|
192
|
+
},
|
|
193
|
+
{
|
|
194
|
+
"id": "req-indexed-reads",
|
|
195
|
+
"type": "requirement",
|
|
196
|
+
"label": "Request paths read by index",
|
|
197
|
+
"x": 260,
|
|
198
|
+
"y": 130,
|
|
199
|
+
"ears_type": "ubiquitous",
|
|
200
|
+
"action": "serve every query on a request path from a key or an index, with 0 whole-table or whole-collection scans over a table or collection above 10,000 rows on a request path",
|
|
201
|
+
"rationale": "A full scan that is fast at launch is a time-out a year later; small tables are scanned by design and are not the problem (Fowler, PolyglotPersistence; Kleppmann, Designing Data-Intensive Applications, ch. 3).",
|
|
202
|
+
"hubWhen": {
|
|
203
|
+
"MODEL": [
|
|
204
|
+
"relational",
|
|
205
|
+
"document"
|
|
206
|
+
]
|
|
207
|
+
}
|
|
208
|
+
},
|
|
209
|
+
{
|
|
210
|
+
"id": "req-versioned",
|
|
211
|
+
"type": "requirement",
|
|
212
|
+
"label": "Migrations are versioned",
|
|
213
|
+
"x": 260,
|
|
214
|
+
"y": 260,
|
|
215
|
+
"ears_type": "event-driven",
|
|
216
|
+
"trigger": "a change needs a different schema, index or reference data",
|
|
217
|
+
"action": "apply it as a versioned migration committed with the code and run by the deploy pipeline with {{MIGRATIONS}}, with 0 schema changes made by hand in any shared environment",
|
|
218
|
+
"rationale": "A schema changed by hand differs between environments, and the difference shows up in production (Sadalage and Fowler, Evolutionary Database Design: all database artefacts are version controlled).",
|
|
219
|
+
"hubWhen": {
|
|
220
|
+
"MIGRATIONS": [
|
|
221
|
+
"tool",
|
|
222
|
+
"orm"
|
|
223
|
+
],
|
|
224
|
+
"MODEL": [
|
|
225
|
+
"relational"
|
|
226
|
+
]
|
|
227
|
+
}
|
|
228
|
+
},
|
|
229
|
+
{
|
|
230
|
+
"id": "req-versioned-doc",
|
|
231
|
+
"type": "requirement",
|
|
232
|
+
"label": "Collection changes are versioned",
|
|
233
|
+
"x": 260,
|
|
234
|
+
"y": 390,
|
|
235
|
+
"ears_type": "event-driven",
|
|
236
|
+
"trigger": "a change needs a different validator, index or reference data",
|
|
237
|
+
"action": "apply it as a versioned changeset committed with the code and run by the deploy pipeline with {{MIGRATIONS}}, with 0 validator or index changes made by hand in any shared environment",
|
|
238
|
+
"rationale": "A collection changed by hand differs between environments, and the difference shows up in production (Sadalage and Fowler, Evolutionary Database Design: all database artefacts are version controlled).",
|
|
239
|
+
"hubWhen": {
|
|
240
|
+
"MIGRATIONS": [
|
|
241
|
+
"tool"
|
|
242
|
+
],
|
|
243
|
+
"MODEL": [
|
|
244
|
+
"document"
|
|
245
|
+
]
|
|
246
|
+
}
|
|
247
|
+
},
|
|
248
|
+
{
|
|
249
|
+
"id": "req-lazy",
|
|
250
|
+
"type": "requirement",
|
|
251
|
+
"label": "Old records upgraded",
|
|
252
|
+
"x": 260,
|
|
253
|
+
"y": 520,
|
|
254
|
+
"ears_type": "event-driven",
|
|
255
|
+
"trigger": "a record written under an older schema version is read",
|
|
256
|
+
"action": "upgrade it to the current version in code before use, write it back at the next save, and backfill in the background so that 0 records are more than 2 schema versions behind",
|
|
257
|
+
"rationale": "Upgrading on read spreads the cost of a change over time; the backfill keeps the code from carrying upgraders for every version ever written (MongoDB, the Schema Versioning pattern).",
|
|
258
|
+
"hubWhen": {
|
|
259
|
+
"MIGRATIONS": [
|
|
260
|
+
"lazy"
|
|
261
|
+
],
|
|
262
|
+
"MODEL": [
|
|
263
|
+
"document",
|
|
264
|
+
"keyvalue"
|
|
265
|
+
]
|
|
266
|
+
}
|
|
267
|
+
},
|
|
268
|
+
{
|
|
269
|
+
"id": "req-integrity",
|
|
270
|
+
"type": "requirement",
|
|
271
|
+
"label": "Integrity enforced by the database",
|
|
272
|
+
"x": 260,
|
|
273
|
+
"y": 650,
|
|
274
|
+
"ears_type": "ubiquitous",
|
|
275
|
+
"action": "enforce the invariants between records in the database itself, with a primary key on 100% of tables, a foreign key on every reference column, and unique and check constraints for the rules they can express",
|
|
276
|
+
"rationale": "Every code path, script and future application obeys a constraint; only some of them obey application code (Sadalage and Fowler, Evolutionary Database Design; PostgreSQL documentation, constraints).",
|
|
277
|
+
"hubWhen": {
|
|
278
|
+
"MODEL": [
|
|
279
|
+
"relational"
|
|
280
|
+
]
|
|
281
|
+
}
|
|
282
|
+
},
|
|
283
|
+
{
|
|
284
|
+
"id": "req-documents",
|
|
285
|
+
"type": "requirement",
|
|
286
|
+
"label": "Documents validated and bounded",
|
|
287
|
+
"x": 260,
|
|
288
|
+
"y": 780,
|
|
289
|
+
"ears_type": "ubiquitous",
|
|
290
|
+
"action": "store each aggregate as one document, validate 100% of collections with a JSON Schema validator that rejects invalid writes, and keep every document under 1 MB",
|
|
291
|
+
"rationale": "Schema-flexible does not mean schema-free: a validator stops malformed documents at the door, and the size bound keeps documents well below MongoDB's 16 MB limit and fast to read (MongoDB schema validation).",
|
|
292
|
+
"hubWhen": {
|
|
293
|
+
"MODEL": [
|
|
294
|
+
"document"
|
|
295
|
+
]
|
|
296
|
+
}
|
|
297
|
+
},
|
|
298
|
+
{
|
|
299
|
+
"id": "req-kv-latency",
|
|
300
|
+
"type": "requirement",
|
|
301
|
+
"label": "Key lookups are fast",
|
|
302
|
+
"x": 260,
|
|
303
|
+
"y": 910,
|
|
304
|
+
"ears_type": "ubiquitous",
|
|
305
|
+
"action": "answer 99% of key reads and writes within {{P99_MS}} ms as measured by the store, and keep every item under 400 KB",
|
|
306
|
+
"rationale": "Predictable low latency at any scale is the reason to give up queries; 400 KB is DynamoDB's item limit, and large values in Redis block other commands (DynamoDB best practices).",
|
|
307
|
+
"hubWhen": {
|
|
308
|
+
"MODEL": [
|
|
309
|
+
"keyvalue"
|
|
310
|
+
]
|
|
311
|
+
}
|
|
312
|
+
},
|
|
313
|
+
{
|
|
314
|
+
"id": "req-transactions",
|
|
315
|
+
"type": "requirement",
|
|
316
|
+
"label": "Operations commit whole",
|
|
317
|
+
"x": 260,
|
|
318
|
+
"y": 1040,
|
|
319
|
+
"ears_type": "event-driven",
|
|
320
|
+
"trigger": "a business operation changes several records",
|
|
321
|
+
"action": "commit all its changes in one transaction, so that 0 readers see part of the operation and a failure leaves none of it",
|
|
322
|
+
"rationale": "A half-applied operation (money taken, order not created) is the hardest kind of bug to find and repair (Kleppmann, Designing Data-Intensive Applications, ch. 7).",
|
|
323
|
+
"hubWhen": {
|
|
324
|
+
"CONSISTENCY": [
|
|
325
|
+
"strong"
|
|
326
|
+
]
|
|
327
|
+
}
|
|
328
|
+
},
|
|
329
|
+
{
|
|
330
|
+
"id": "req-staleness",
|
|
331
|
+
"type": "requirement",
|
|
332
|
+
"label": "Staleness is bounded",
|
|
333
|
+
"x": 260,
|
|
334
|
+
"y": 1170,
|
|
335
|
+
"ears_type": "state-driven",
|
|
336
|
+
"precondition": "replicas or secondary indexes lag behind the primary",
|
|
337
|
+
"action": "serve reads at most {{STALE_SECONDS}} seconds old, and read from the primary wherever a user must see their own write",
|
|
338
|
+
"rationale": "Eventual consistency is acceptable only with a known bound and with read-your-writes where users notice (Kleppmann, Designing Data-Intensive Applications, ch. 5: replication lag).",
|
|
339
|
+
"hubWhen": {
|
|
340
|
+
"CONSISTENCY": [
|
|
341
|
+
"eventual"
|
|
342
|
+
]
|
|
343
|
+
}
|
|
344
|
+
},
|
|
345
|
+
{
|
|
346
|
+
"id": "req-exit",
|
|
347
|
+
"type": "requirement",
|
|
348
|
+
"label": "Data can leave the provider",
|
|
349
|
+
"x": 260,
|
|
350
|
+
"y": 1300,
|
|
351
|
+
"ears_type": "ubiquitous",
|
|
352
|
+
"action": "keep a daily logical export of all data in storage the organisation controls, in a format a self-hosted engine of the same kind loads, with the newest export less than 26 hours old",
|
|
353
|
+
"rationale": "A managed service is a dependency on one provider; an export it does not hold is the exit plan (DORA Art. 28, exit strategies). Loading it into a self-hosted engine is the restore drill of the Backup and recovery pack.",
|
|
354
|
+
"hubWhen": {
|
|
355
|
+
"HOSTING": [
|
|
356
|
+
"managed"
|
|
357
|
+
]
|
|
358
|
+
}
|
|
359
|
+
},
|
|
360
|
+
{
|
|
361
|
+
"id": "req-engine-patch",
|
|
362
|
+
"type": "requirement",
|
|
363
|
+
"label": "Engine patched on time",
|
|
364
|
+
"x": 260,
|
|
365
|
+
"y": 1430,
|
|
366
|
+
"ears_type": "event-driven",
|
|
367
|
+
"trigger": "a minor or security release of the database engine is published",
|
|
368
|
+
"action": "apply it within 30 days by a rolling upgrade with automatic failover, keeping writes unavailable for under 30 seconds",
|
|
369
|
+
"rationale": "Self-hosting makes patching our job; minor releases carry security and data-corruption fixes, and the engine's support lifecycle ends on published dates (PostgreSQL versioning policy; endoflife.date).",
|
|
370
|
+
"hubWhen": {
|
|
371
|
+
"HOSTING": [
|
|
372
|
+
"self"
|
|
373
|
+
]
|
|
374
|
+
}
|
|
375
|
+
},
|
|
376
|
+
{
|
|
377
|
+
"id": "sc-access-patterns",
|
|
378
|
+
"type": "scenario",
|
|
379
|
+
"label": "Scan on request path refused",
|
|
380
|
+
"x": 520,
|
|
381
|
+
"y": 0,
|
|
382
|
+
"given": "the access-pattern catalogue and the request-handling code",
|
|
383
|
+
"when": "a change calls Scan or KEYS outside a batch job",
|
|
384
|
+
"then": "the lint fails naming the call",
|
|
385
|
+
"hubWhen": {
|
|
386
|
+
"MODEL": [
|
|
387
|
+
"keyvalue"
|
|
388
|
+
]
|
|
389
|
+
}
|
|
390
|
+
},
|
|
391
|
+
{
|
|
392
|
+
"id": "sc-indexed-reads",
|
|
393
|
+
"type": "scenario",
|
|
394
|
+
"label": "No scan on request path",
|
|
395
|
+
"x": 520,
|
|
396
|
+
"y": 130,
|
|
397
|
+
"given": "the store loaded with production-sized data and its scan counters reset",
|
|
398
|
+
"when": "the request-path test suite runs and the counters are read",
|
|
399
|
+
"then": "no table or collection above 10,000 rows was scanned whole",
|
|
400
|
+
"hubWhen": {
|
|
401
|
+
"MODEL": [
|
|
402
|
+
"relational",
|
|
403
|
+
"document"
|
|
404
|
+
]
|
|
405
|
+
}
|
|
406
|
+
},
|
|
407
|
+
{
|
|
408
|
+
"id": "sc-versioned",
|
|
409
|
+
"type": "scenario",
|
|
410
|
+
"label": "Migration applied by pipeline",
|
|
411
|
+
"x": 520,
|
|
412
|
+
"y": 260,
|
|
413
|
+
"given": "a change that adds a column",
|
|
414
|
+
"when": "it is deployed to each environment in turn",
|
|
415
|
+
"then": "the same versioned migration is applied by the pipeline everywhere, and the migration history matches in every environment",
|
|
416
|
+
"hubWhen": {
|
|
417
|
+
"MIGRATIONS": [
|
|
418
|
+
"tool",
|
|
419
|
+
"orm"
|
|
420
|
+
],
|
|
421
|
+
"MODEL": [
|
|
422
|
+
"relational"
|
|
423
|
+
]
|
|
424
|
+
}
|
|
425
|
+
},
|
|
426
|
+
{
|
|
427
|
+
"id": "sc-versioned-doc",
|
|
428
|
+
"type": "scenario",
|
|
429
|
+
"label": "Changeset applied by pipeline",
|
|
430
|
+
"x": 520,
|
|
431
|
+
"y": 390,
|
|
432
|
+
"given": "a change that adds an index",
|
|
433
|
+
"when": "it is deployed to each environment in turn",
|
|
434
|
+
"then": "the same versioned changeset is applied by the pipeline everywhere, and the changelog history matches in every environment",
|
|
435
|
+
"hubWhen": {
|
|
436
|
+
"MIGRATIONS": [
|
|
437
|
+
"tool"
|
|
438
|
+
],
|
|
439
|
+
"MODEL": [
|
|
440
|
+
"document"
|
|
441
|
+
]
|
|
442
|
+
}
|
|
443
|
+
},
|
|
444
|
+
{
|
|
445
|
+
"id": "sc-lazy",
|
|
446
|
+
"type": "scenario",
|
|
447
|
+
"label": "Old record read",
|
|
448
|
+
"x": 520,
|
|
449
|
+
"y": 520,
|
|
450
|
+
"given": "a record at schema version N-1",
|
|
451
|
+
"when": "the element reads it and later saves it",
|
|
452
|
+
"then": "it is used as version N and stored as version N",
|
|
453
|
+
"hubWhen": {
|
|
454
|
+
"MIGRATIONS": [
|
|
455
|
+
"lazy"
|
|
456
|
+
],
|
|
457
|
+
"MODEL": [
|
|
458
|
+
"document",
|
|
459
|
+
"keyvalue"
|
|
460
|
+
]
|
|
461
|
+
}
|
|
462
|
+
},
|
|
463
|
+
{
|
|
464
|
+
"id": "sc-integrity",
|
|
465
|
+
"type": "scenario",
|
|
466
|
+
"label": "Dangling reference refused",
|
|
467
|
+
"x": 520,
|
|
468
|
+
"y": 650,
|
|
469
|
+
"given": "an order line that references an order",
|
|
470
|
+
"when": "a line is inserted for an order that does not exist",
|
|
471
|
+
"then": "the database refuses the insert",
|
|
472
|
+
"hubWhen": {
|
|
473
|
+
"MODEL": [
|
|
474
|
+
"relational"
|
|
475
|
+
]
|
|
476
|
+
}
|
|
477
|
+
},
|
|
478
|
+
{
|
|
479
|
+
"id": "sc-documents",
|
|
480
|
+
"type": "scenario",
|
|
481
|
+
"label": "Invalid document refused",
|
|
482
|
+
"x": 520,
|
|
483
|
+
"y": 780,
|
|
484
|
+
"given": "a collection with its JSON Schema validator",
|
|
485
|
+
"when": "a document missing a required field is inserted",
|
|
486
|
+
"then": "the database refuses the write",
|
|
487
|
+
"hubWhen": {
|
|
488
|
+
"MODEL": [
|
|
489
|
+
"document"
|
|
490
|
+
]
|
|
491
|
+
}
|
|
492
|
+
},
|
|
493
|
+
{
|
|
494
|
+
"id": "sc-kv-latency",
|
|
495
|
+
"type": "scenario",
|
|
496
|
+
"label": "Lookups within target",
|
|
497
|
+
"x": 520,
|
|
498
|
+
"y": 910,
|
|
499
|
+
"given": "the store at production volume",
|
|
500
|
+
"when": "a day of key reads and writes has been served and the store's latency percentiles are read",
|
|
501
|
+
"then": "the 99th percentile of reads and of writes is within {{P99_MS}} ms",
|
|
502
|
+
"hubWhen": {
|
|
503
|
+
"MODEL": [
|
|
504
|
+
"keyvalue"
|
|
505
|
+
]
|
|
506
|
+
}
|
|
507
|
+
},
|
|
508
|
+
{
|
|
509
|
+
"id": "sc-transactions",
|
|
510
|
+
"type": "scenario",
|
|
511
|
+
"label": "Failure leaves nothing",
|
|
512
|
+
"x": 520,
|
|
513
|
+
"y": 1040,
|
|
514
|
+
"given": "an operation that writes three records",
|
|
515
|
+
"when": "it fails after the second write",
|
|
516
|
+
"then": "none of the three records is changed and no reader saw the first two",
|
|
517
|
+
"hubWhen": {
|
|
518
|
+
"CONSISTENCY": [
|
|
519
|
+
"strong"
|
|
520
|
+
]
|
|
521
|
+
}
|
|
522
|
+
},
|
|
523
|
+
{
|
|
524
|
+
"id": "sc-staleness",
|
|
525
|
+
"type": "scenario",
|
|
526
|
+
"label": "Own write visible",
|
|
527
|
+
"x": 520,
|
|
528
|
+
"y": 1170,
|
|
529
|
+
"given": "a user who has just changed a record",
|
|
530
|
+
"when": "the user reads it again while replicas lag",
|
|
531
|
+
"then": "the user sees the change, and other readers see it within {{STALE_SECONDS}} seconds",
|
|
532
|
+
"hubWhen": {
|
|
533
|
+
"CONSISTENCY": [
|
|
534
|
+
"eventual"
|
|
535
|
+
]
|
|
536
|
+
}
|
|
537
|
+
},
|
|
538
|
+
{
|
|
539
|
+
"id": "sc-exit",
|
|
540
|
+
"type": "scenario",
|
|
541
|
+
"label": "Export is fresh",
|
|
542
|
+
"x": 520,
|
|
543
|
+
"y": 1300,
|
|
544
|
+
"given": "the storage the organisation controls",
|
|
545
|
+
"when": "the freshness check runs",
|
|
546
|
+
"then": "the newest export there is less than 26 hours old",
|
|
547
|
+
"hubWhen": {
|
|
548
|
+
"HOSTING": [
|
|
549
|
+
"managed"
|
|
550
|
+
]
|
|
551
|
+
}
|
|
552
|
+
},
|
|
553
|
+
{
|
|
554
|
+
"id": "sc-engine-patch",
|
|
555
|
+
"type": "scenario",
|
|
556
|
+
"label": "Minor release applied",
|
|
557
|
+
"x": 520,
|
|
558
|
+
"y": 1430,
|
|
559
|
+
"given": "a new minor release of the engine",
|
|
560
|
+
"when": "30 days have passed",
|
|
561
|
+
"then": "every node runs it, and the failover during the upgrade kept writes unavailable for under 30 seconds",
|
|
562
|
+
"hubWhen": {
|
|
563
|
+
"HOSTING": [
|
|
564
|
+
"self"
|
|
565
|
+
]
|
|
566
|
+
}
|
|
567
|
+
},
|
|
568
|
+
{
|
|
569
|
+
"id": "adr-relational",
|
|
570
|
+
"type": "adr",
|
|
571
|
+
"label": "A relational database",
|
|
572
|
+
"x": 780,
|
|
573
|
+
"y": 0,
|
|
574
|
+
"concern": "data-store",
|
|
575
|
+
"status": "accepted",
|
|
576
|
+
"date": "",
|
|
577
|
+
"context": "This element keeps the system's data, and the store chosen for it outlives most of the code around it: data is far harder to move than code. The forces: the way the data is queried (ad hoc and across entities, whole aggregates by id, or a few known lookups at very high volume) favours different data models; some operations must never be seen half done, while others can accept reading slightly old data in exchange for scale and availability; a managed service takes patching, failover and backups off the team but adds a provider, its limits and its bill, while self-hosting needs people who can run the engine at three in the morning; and the schema will change many times while the system is live, so every change has to be repeatable and safe for the code version still running. Backup and recovery is its own concern; whether a change ships as expand and contract or in a window is decided in the Deployment and rollback pack.",
|
|
578
|
+
"decision": "The data is kept in a relational database: PostgreSQL by default, MySQL where the team or platform already runs it. Consistency: {{CONSISTENCY}}; where it is eventual, reads are at most {{STALE_SECONDS}} seconds old. Hosting: {{HOSTING}} (managed: Amazon RDS or Aurora, Azure Database for PostgreSQL or for MySQL flexible server, Google Cloud SQL; self-hosted: CloudNativePG on Kubernetes or Patroni on virtual machines). Schema changes: {{MIGRATIONS}}; whether a change ships as expand and contract or in a window, and how migrations are linted for it, is decided in the Deployment and rollback pack. Constraints, not only code, enforce the invariants; JSONB columns hold the parts whose shape varies. Choosing PostgreSQL or MySQL: PostgreSQL for richer types (JSONB, arrays, ranges), extensions (PostGIS, pgvector) and transactional DDL; MySQL when existing operations know it. Choosing managed or self-hosted: managed unless data residency, cost at scale or an on-premises platform rules it out.",
|
|
579
|
+
"consequences": "• Any query can be written later, including the reports and back-office searches nobody listed today.\n• Transactions and constraints keep the data consistent across entities without application code.\n• Scaling writes past one primary needs partitioning, sharding (Citus, Vitess) or a different store for the hot path.\n• Every schema change is a migration, planned with the code version still running.",
|
|
580
|
+
"alternatives": "1. A document database: aggregates read whole and flexible shapes, at the cost of joins and cross-document constraints.\n2. A key-value store: scale and latency for known lookups, no ad hoc queries.\n3. A distributed SQL database (CockroachDB, YugabyteDB, Spanner): relational with horizontal write scale, more cost and latency per write.",
|
|
581
|
+
"hubWhen": {
|
|
582
|
+
"MODEL": [
|
|
583
|
+
"relational"
|
|
584
|
+
]
|
|
585
|
+
}
|
|
586
|
+
},
|
|
587
|
+
{
|
|
588
|
+
"id": "adr-document",
|
|
589
|
+
"type": "adr",
|
|
590
|
+
"label": "A document database",
|
|
591
|
+
"x": 780,
|
|
592
|
+
"y": 130,
|
|
593
|
+
"concern": "data-store",
|
|
594
|
+
"status": "accepted",
|
|
595
|
+
"date": "",
|
|
596
|
+
"context": "This element keeps the system's data, and the store chosen for it outlives most of the code around it: data is far harder to move than code. The forces: the way the data is queried (ad hoc and across entities, whole aggregates by id, or a few known lookups at very high volume) favours different data models; some operations must never be seen half done, while others can accept reading slightly old data in exchange for scale and availability; a managed service takes patching, failover and backups off the team but adds a provider, its limits and its bill, while self-hosting needs people who can run the engine at three in the morning; and the schema will change many times while the system is live, so every change has to be repeatable and safe for the code version still running. Backup and recovery is its own concern; whether a change ships as expand and contract or in a window is decided in the Deployment and rollback pack.",
|
|
597
|
+
"decision": "The data is kept in a document database, MongoDB, one document per aggregate, with a JSON Schema validator on every collection. Consistency: {{CONSISTENCY}} (majority write concern; reads from the primary or with majority read concern where it must be strong); where it is eventual, secondaries serve reads at most {{STALE_SECONDS}} seconds old. Hosting: {{HOSTING}} (managed: MongoDB Atlas; self-hosted: the MongoDB or Percona operator on Kubernetes). Schema changes: {{MIGRATIONS}}; whether a change ships as expand and contract or in a window is decided in the Deployment and rollback pack. References between aggregates by id; multi-document transactions only where one operation must change two aggregates. Choosing MongoDB or a PostgreSQL JSONB column: MongoDB when most data is documents and scale-out by sharding is likely; JSONB when only a part of a mostly relational model varies in shape. Amazon DocumentDB or Azure Cosmos DB for MongoDB only after checking the features you need are compatible.",
|
|
598
|
+
"consequences": "• An aggregate is read and written in one operation, with no mapping to tables.\n• Shapes can vary between records, and the validator still stops malformed writes.\n• Joins and constraints across documents are the application's job; queries not planned for need new indexes or pipelines.\n• Data duplicated across documents for read speed must be kept in step by code.",
|
|
599
|
+
"alternatives": "1. A relational database with JSONB columns: constraints and joins with flexible parts.\n2. A key-value store: simpler and faster for lookups by key, no queries on content.\n3. A search engine (OpenSearch) as the main store: great for text search, weak as a system of record.",
|
|
600
|
+
"hubWhen": {
|
|
601
|
+
"MODEL": [
|
|
602
|
+
"document"
|
|
603
|
+
]
|
|
604
|
+
}
|
|
605
|
+
},
|
|
606
|
+
{
|
|
607
|
+
"id": "adr-keyvalue",
|
|
608
|
+
"type": "adr",
|
|
609
|
+
"label": "A key-value store",
|
|
610
|
+
"x": 780,
|
|
611
|
+
"y": 260,
|
|
612
|
+
"concern": "data-store",
|
|
613
|
+
"status": "accepted",
|
|
614
|
+
"date": "",
|
|
615
|
+
"context": "This element keeps the system's data, and the store chosen for it outlives most of the code around it: data is far harder to move than code. The forces: the way the data is queried (ad hoc and across entities, whole aggregates by id, or a few known lookups at very high volume) favours different data models; some operations must never be seen half done, while others can accept reading slightly old data in exchange for scale and availability; a managed service takes patching, failover and backups off the team but adds a provider, its limits and its bill, while self-hosting needs people who can run the engine at three in the morning; and the schema will change many times while the system is live, so every change has to be repeatable and safe for the code version still running. Backup and recovery is its own concern; whether a change ships as expand and contract or in a window is decided in the Deployment and rollback pack.",
|
|
616
|
+
"decision": "The data is kept in a key-value store designed from its access patterns: Amazon DynamoDB (single-table design, keys and global secondary indexes per listed access pattern, on-demand or provisioned capacity) for durable data on AWS; Redis (or Valkey) with persistence only for small, short-lived or rebuildable data such as sessions, counters and rate limits. Key reads and writes answer within {{P99_MS}} ms at the 99th percentile, measured by the store. Consistency: {{CONSISTENCY}} (DynamoDB strongly consistent reads and TransactWriteItems where it must be strong); where it is eventual, replicas and global tables lag at most {{STALE_SECONDS}} seconds. Hosting: {{HOSTING}} (managed: DynamoDB, ElastiCache or MemoryDB; self-hosted: Redis with Sentinel or Valkey cluster). Schema changes: tables and indexes are infrastructure code applied by the pipeline; item shapes carry a schema version and old items are upgraded in code when read. No Scan on a request path. Choosing DynamoDB or Redis: DynamoDB when the data must survive and grow without limit; Redis when it fits in memory and losing the last second is acceptable. Outside AWS: Azure Cosmos DB or Google Bigtable play DynamoDB's part.",
|
|
617
|
+
"consequences": "• Single-digit-millisecond latency at any scale, with capacity that scales without re-architecture.\n• Every query must be designed up front; a new access pattern means a new index or a backfill.\n• No joins and limited transactions; reports and analytics go to an export (DynamoDB to S3, Athena) rather than the store.\n• DynamoDB ties the element to AWS; the item and transaction limits shape the design.",
|
|
618
|
+
"alternatives": "1. A relational database: any query, transactions and constraints, with less headroom for scale.\n2. A document database: richer queries on content, more operational work.\n3. A cache in front of a relational database: keeps queries flexible and lookups fast, adds invalidation.",
|
|
619
|
+
"hubWhen": {
|
|
620
|
+
"MODEL": [
|
|
621
|
+
"keyvalue"
|
|
622
|
+
]
|
|
623
|
+
}
|
|
624
|
+
},
|
|
625
|
+
{
|
|
626
|
+
"id": "ff-flyway",
|
|
627
|
+
"type": "fitness-fn",
|
|
628
|
+
"label": "Migrations apply cleanly",
|
|
629
|
+
"x": 1040,
|
|
630
|
+
"y": 0,
|
|
631
|
+
"characteristic": "maintainability",
|
|
632
|
+
"scope": "atomic",
|
|
633
|
+
"cadence": "triggered",
|
|
634
|
+
"trigger": "pull-request",
|
|
635
|
+
"invocation": "automated",
|
|
636
|
+
"description": "On every pull request the pipeline starts the production engine and version, applies all migrations from empty, and validates them; the deploy runs migrate and validate against each environment, so a schema changed by hand shows up as a validation failure. With Liquibase the same is `liquibase update` followed by `liquibase validate`.\n\nThreshold: Every migration applies to an empty database of the production engine and version; 0 checksum mismatches against applied migrations\n\nTool: Flyway (PostgreSQL shown; MySQL: the mysql service image and a jdbc:mysql URL)\n\n```yaml\n# .github/workflows/migrations.yml\njobs:\n migrations:\n runs-on: ubuntu-latest\n services:\n postgres:\n image: postgres:17 # the production major version\n env: { POSTGRES_PASSWORD: test, POSTGRES_DB: app }\n ports: ['5432:5432']\n options: --health-cmd pg_isready --health-interval 5s\n steps:\n - uses: actions/checkout@v4.2.2 # pin by commit SHA in your repository\n - run: |\n docker run --rm --network host -v \"$PWD/db/migration:/flyway/sql\" flyway/flyway:11 \\\n -url=jdbc:postgresql://localhost:5432/app -user=postgres -password=test \\\n -validateMigrationNaming=true migrate validate\n```",
|
|
637
|
+
"hubWhen": {
|
|
638
|
+
"MIGRATIONS": [
|
|
639
|
+
"tool"
|
|
640
|
+
],
|
|
641
|
+
"MODEL": [
|
|
642
|
+
"relational"
|
|
643
|
+
]
|
|
644
|
+
}
|
|
645
|
+
},
|
|
646
|
+
{
|
|
647
|
+
"id": "ff-liquibase-mongo",
|
|
648
|
+
"type": "fitness-fn",
|
|
649
|
+
"label": "Changesets apply cleanly",
|
|
650
|
+
"x": 1040,
|
|
651
|
+
"y": 130,
|
|
652
|
+
"characteristic": "maintainability",
|
|
653
|
+
"scope": "atomic",
|
|
654
|
+
"cadence": "triggered",
|
|
655
|
+
"trigger": "pull-request",
|
|
656
|
+
"invocation": "automated",
|
|
657
|
+
"description": "On every pull request the pipeline starts the production MongoDB version, applies the changelog from empty with Liquibase and its MongoDB extension (the extension and MongoDB driver jars are kept in db/lib and mounted into /liquibase/lib), and checks that status reports the database up to date; the deploy runs the same update against each environment.\n\nThreshold: Every changeset applies to an empty MongoDB of the production version; after the update the changelog reports nothing pending\n\nTool: Liquibase with the liquibase-mongodb extension\n\n```yaml\n# .github/workflows/migrations.yml\njobs:\n migrations:\n runs-on: ubuntu-latest\n services:\n mongo:\n image: mongo:8.0 # the production version\n ports: ['27017:27017']\n steps:\n - uses: actions/checkout@v4.2.2 # pin by commit SHA in your repository\n - run: |\n lb() { docker run --rm --network host -v \"$PWD/db:/liquibase/changelog\" -v \"$PWD/db/lib:/liquibase/lib\" \\\n liquibase/liquibase:4.31 --url=\"mongodb://localhost:27017/app\" --changelog-file=changelog.xml \"$@\"; }\n lb update\n lb status --verbose | grep -q 'is up to date'\n```",
|
|
658
|
+
"hubWhen": {
|
|
659
|
+
"MIGRATIONS": [
|
|
660
|
+
"tool"
|
|
661
|
+
],
|
|
662
|
+
"MODEL": [
|
|
663
|
+
"document"
|
|
664
|
+
]
|
|
665
|
+
}
|
|
666
|
+
},
|
|
667
|
+
{
|
|
668
|
+
"id": "ff-orm-drift",
|
|
669
|
+
"type": "fitness-fn",
|
|
670
|
+
"label": "Model and migrations agree",
|
|
671
|
+
"x": 1040,
|
|
672
|
+
"y": 260,
|
|
673
|
+
"characteristic": "maintainability",
|
|
674
|
+
"scope": "atomic",
|
|
675
|
+
"cadence": "triggered",
|
|
676
|
+
"trigger": "pull-request",
|
|
677
|
+
"invocation": "automated",
|
|
678
|
+
"description": "The build fails when the model in code changed without a migration, so every schema change is a committed, versioned migration.\n\nThreshold: 0 differences between the model in code and the committed migrations\n\nTool: Prisma Migrate (prisma migrate diff); EF Core: dotnet ef migrations has-pending-model-changes; Alembic: alembic check; Django: manage.py makemigrations --check --dry-run\n\n```bash\n# exits 2 when the schema and the migrations differ\nnpx prisma migrate diff \\\n --from-migrations prisma/migrations \\\n --to-schema-datamodel prisma/schema.prisma \\\n --shadow-database-url \"$SHADOW_DATABASE_URL\" \\\n --exit-code\n```",
|
|
679
|
+
"hubWhen": {
|
|
680
|
+
"MIGRATIONS": [
|
|
681
|
+
"orm"
|
|
682
|
+
],
|
|
683
|
+
"MODEL": [
|
|
684
|
+
"relational"
|
|
685
|
+
]
|
|
686
|
+
}
|
|
687
|
+
},
|
|
688
|
+
{
|
|
689
|
+
"id": "ff-schema-versions",
|
|
690
|
+
"type": "fitness-fn",
|
|
691
|
+
"label": "No document far behind",
|
|
692
|
+
"x": 1040,
|
|
693
|
+
"y": 390,
|
|
694
|
+
"characteristic": "maintainability",
|
|
695
|
+
"scope": "atomic",
|
|
696
|
+
"cadence": "triggered",
|
|
697
|
+
"trigger": "nightly",
|
|
698
|
+
"invocation": "automated",
|
|
699
|
+
"description": "A scheduled job counts the documents per collection that are more than two versions behind the version the code writes, or carry no schema version at all (the oldest of all), and fails when any exist; the backfill job then runs.\n\nThreshold: 0 documents more than 2 schema versions behind the current one, documents without a version field included\n\nTool: mongosh (scheduled job)\n\n```js\n// check-schema-versions.js — mongosh \"$MONGODB_URI\" --file check-schema-versions.js\nconst CURRENT = { orders: 7, customers: 4 } // the version the code writes\nlet behind = 0\nfor (const [name, version] of Object.entries(CURRENT)) {\n const n = db.getCollection(name).countDocuments({\n $or: [{ schemaVersion: { $lt: version - 2 } }, { schemaVersion: { $exists: false } }],\n })\n if (n > 0) print(`${name}: ${n} documents more than 2 versions behind`)\n behind += n\n}\nif (behind > 0) quit(1)\n```",
|
|
700
|
+
"hubWhen": {
|
|
701
|
+
"MIGRATIONS": [
|
|
702
|
+
"lazy"
|
|
703
|
+
],
|
|
704
|
+
"MODEL": [
|
|
705
|
+
"document"
|
|
706
|
+
]
|
|
707
|
+
}
|
|
708
|
+
},
|
|
709
|
+
{
|
|
710
|
+
"id": "ff-schema-versions-kv",
|
|
711
|
+
"type": "fitness-fn",
|
|
712
|
+
"label": "No item far behind",
|
|
713
|
+
"x": 1040,
|
|
714
|
+
"y": 520,
|
|
715
|
+
"characteristic": "maintainability",
|
|
716
|
+
"scope": "atomic",
|
|
717
|
+
"cadence": "triggered",
|
|
718
|
+
"trigger": "nightly",
|
|
719
|
+
"invocation": "automated",
|
|
720
|
+
"description": "A scheduled batch job (the one place a Scan is allowed) counts the items more than two versions behind the version the code writes, or without a schema version at all, and fails when any exist; the backfill job then runs. The CLI pages the scan and sums the count.\n\nThreshold: 0 items more than 2 schema versions behind the current one, items without a version attribute included\n\nTool: AWS CLI (DynamoDB); Redis: a SCAN over the key space in a job, reading the version field of each value\n\n```bash\n#!/usr/bin/env bash\n# CURRENT: the schema version the code writes; TABLE from the environment\nset -euo pipefail\nCURRENT=7\nbehind=$(aws dynamodb scan --table-name \"$TABLE\" --select COUNT \\\n --filter-expression 'attribute_not_exists(schemaVersion) OR schemaVersion < :v' \\\n --expression-attribute-values \"{\\\":v\\\":{\\\"N\\\":\\\"$((CURRENT - 2))\\\"}}\" --query Count --output text)\n[ \"$behind\" -eq 0 ] || { echo \"$behind items more than 2 schema versions behind\"; exit 1; }\n```",
|
|
721
|
+
"hubWhen": {
|
|
722
|
+
"MIGRATIONS": [
|
|
723
|
+
"lazy"
|
|
724
|
+
],
|
|
725
|
+
"MODEL": [
|
|
726
|
+
"keyvalue"
|
|
727
|
+
]
|
|
728
|
+
}
|
|
729
|
+
},
|
|
730
|
+
{
|
|
731
|
+
"id": "ff-seq-scan",
|
|
732
|
+
"type": "fitness-fn",
|
|
733
|
+
"label": "No sequential scan on request paths",
|
|
734
|
+
"x": 1040,
|
|
735
|
+
"y": 650,
|
|
736
|
+
"characteristic": "performance-efficiency",
|
|
737
|
+
"scope": "atomic",
|
|
738
|
+
"cadence": "triggered",
|
|
739
|
+
"trigger": "pull-request",
|
|
740
|
+
"invocation": "automated",
|
|
741
|
+
"description": "The integration pipeline loads a database with production-sized data, resets the statistics, runs the request-path test suite, then reads pg_stat_user_tables: a table above 10,000 rows with a sequential scan since the reset fails the job.\n\nThreshold: 0 sequential scans over a table above 10,000 rows during the request-path test suite\n\nTool: psql (PostgreSQL); MySQL: sys.schema_tables_with_full_table_scans after the same suite\n\n```sql\n-- before the request-path test suite, on a database loaded with production-sized data:\nSELECT pg_stat_reset();\n\n-- after it: tables above 10,000 rows that were read whole; the job fails on any row\nSELECT relname, seq_scan, n_live_tup\nFROM pg_stat_user_tables\nWHERE n_live_tup > 10000 AND seq_scan > 0\nORDER BY seq_scan DESC;\n```",
|
|
742
|
+
"hubWhen": {
|
|
743
|
+
"MODEL": [
|
|
744
|
+
"relational"
|
|
745
|
+
]
|
|
746
|
+
}
|
|
747
|
+
},
|
|
748
|
+
{
|
|
749
|
+
"id": "ff-collscan",
|
|
750
|
+
"type": "fitness-fn",
|
|
751
|
+
"label": "No collection scan on request paths",
|
|
752
|
+
"x": 1040,
|
|
753
|
+
"y": 780,
|
|
754
|
+
"characteristic": "performance-efficiency",
|
|
755
|
+
"scope": "atomic",
|
|
756
|
+
"cadence": "triggered",
|
|
757
|
+
"trigger": "pull-request",
|
|
758
|
+
"invocation": "automated",
|
|
759
|
+
"description": "The integration pipeline loads a database with production-sized data, turns the profiler on for every operation, runs the request-path test suite, then reads system.profile: an operation whose plan was a collection scan over a collection above 10,000 documents fails the job.\n\nThreshold: 0 COLLSCAN operations over a collection above 10,000 documents during the request-path test suite\n\nTool: mongosh\n\n```js\n// before the request-path test suite: db.setProfilingLevel(2)\n// after it — mongosh \"$MONGODB_URI\" --file check-collscan.js\nconst big = db.getCollectionNames()\n .filter((n) => !n.startsWith('system.') && db.getCollection(n).estimatedDocumentCount() > 10000)\n .map((n) => `${db.getName()}.${n}`)\nconst scans = db.system.profile.find({ planSummary: 'COLLSCAN', ns: { $in: big } }).toArray()\nif (scans.length) {\n print(scans.map((s) => `${s.ns}: ${JSON.stringify(s.command)}`).join('\\n'))\n quit(1)\n}\n```",
|
|
760
|
+
"hubWhen": {
|
|
761
|
+
"MODEL": [
|
|
762
|
+
"document"
|
|
763
|
+
]
|
|
764
|
+
}
|
|
765
|
+
},
|
|
766
|
+
{
|
|
767
|
+
"id": "ff-integrity",
|
|
768
|
+
"type": "fitness-fn",
|
|
769
|
+
"label": "Keys and foreign keys present",
|
|
770
|
+
"x": 1040,
|
|
771
|
+
"y": 910,
|
|
772
|
+
"characteristic": "functional-suitability",
|
|
773
|
+
"scope": "atomic",
|
|
774
|
+
"cadence": "triggered",
|
|
775
|
+
"trigger": "pull-request",
|
|
776
|
+
"invocation": "automated",
|
|
777
|
+
"description": "A test migrates a fresh database in a container and queries the catalogue for tables without a primary key and reference columns without a foreign key; both lists must be empty.\n\nThreshold: 100% of tables have a primary key; 0 columns named *_id without a foreign key\n\nTool: Testcontainers with a SQL query on information_schema (PostgreSQL)\n\n```sql\n-- tables without a primary key\nSELECT t.table_name FROM information_schema.tables t\nWHERE t.table_schema = 'public' AND t.table_type = 'BASE TABLE'\n AND NOT EXISTS (SELECT 1 FROM information_schema.table_constraints c\n WHERE c.table_name = t.table_name AND c.constraint_type = 'PRIMARY KEY');\n\n-- reference columns without a foreign key\nSELECT k.table_name, k.column_name FROM information_schema.columns k\nWHERE k.table_schema = 'public' AND k.column_name LIKE '%\\_id'\n AND NOT EXISTS (SELECT 1 FROM information_schema.key_column_usage u\n JOIN information_schema.table_constraints c USING (constraint_name, table_name)\n WHERE c.constraint_type = 'FOREIGN KEY'\n AND u.table_name = k.table_name AND u.column_name = k.column_name);\n```",
|
|
778
|
+
"hubWhen": {
|
|
779
|
+
"MODEL": [
|
|
780
|
+
"relational"
|
|
781
|
+
]
|
|
782
|
+
}
|
|
783
|
+
},
|
|
784
|
+
{
|
|
785
|
+
"id": "ff-validators",
|
|
786
|
+
"type": "fitness-fn",
|
|
787
|
+
"label": "Collections validate writes",
|
|
788
|
+
"x": 1040,
|
|
789
|
+
"y": 1040,
|
|
790
|
+
"characteristic": "functional-suitability",
|
|
791
|
+
"scope": "atomic",
|
|
792
|
+
"cadence": "triggered",
|
|
793
|
+
"trigger": "deploy",
|
|
794
|
+
"invocation": "automated",
|
|
795
|
+
"description": "A check run after each deploy lists the collections and fails when one has no JSON Schema validator, or one that only warns.\n\nThreshold: 100% of collections have a $jsonSchema validator with validationLevel strict and validationAction error\n\nTool: mongosh\n\n```js\n// check-validators.js — mongosh \"$MONGODB_URI\" --file check-validators.js\nconst missing = db.getCollectionInfos({ type: 'collection' })\n .filter((c) => !c.name.startsWith('system.'))\n .filter((c) => !c.options?.validator?.$jsonSchema\n || (c.options.validationLevel ?? 'strict') !== 'strict'\n || (c.options.validationAction ?? 'error') !== 'error')\n .map((c) => c.name)\nif (missing.length) { print('Collections without a strict validator: ' + missing.join(', ')); quit(1) }\n```",
|
|
796
|
+
"hubWhen": {
|
|
797
|
+
"MODEL": [
|
|
798
|
+
"document"
|
|
799
|
+
]
|
|
800
|
+
}
|
|
801
|
+
},
|
|
802
|
+
{
|
|
803
|
+
"id": "ff-no-scan",
|
|
804
|
+
"type": "fitness-fn",
|
|
805
|
+
"label": "No Scan in request code",
|
|
806
|
+
"x": 1040,
|
|
807
|
+
"y": 1170,
|
|
808
|
+
"characteristic": "performance-efficiency",
|
|
809
|
+
"scope": "atomic",
|
|
810
|
+
"cadence": "triggered",
|
|
811
|
+
"trigger": "pull-request",
|
|
812
|
+
"invocation": "automated",
|
|
813
|
+
"description": "A lint rule forbids importing the DynamoDB Scan command and calling keys() on a client in request-handling code; batch jobs under src/jobs are exempt.\n\nThreshold: 0 uses of the DynamoDB Scan command or the Redis KEYS command outside src/jobs\n\nTool: ESLint (Node.js); other runtimes: a Semgrep rule on the same call names\n\n```js\n// eslint.config.mjs\nexport default [\n {\n files: ['src/**/*.ts'],\n ignores: ['src/jobs/**'],\n rules: {\n 'no-restricted-imports': ['error', {\n paths: [\n { name: '@aws-sdk/client-dynamodb', importNames: ['ScanCommand'], message: 'ADR Key-value store: serve requests from a key or index, never Scan.' },\n { name: '@aws-sdk/lib-dynamodb', importNames: ['ScanCommand'], message: 'ADR Key-value store: serve requests from a key or index, never Scan.' },\n ],\n }],\n 'no-restricted-syntax': ['error', {\n selector: 'CallExpression[callee.property.name=\"keys\"][callee.object.name!=\"Object\"]',\n message: 'ADR Key-value store: KEYS blocks Redis; use SCAN in a job under src/jobs, never in a request.',\n }],\n },\n },\n]\n```",
|
|
814
|
+
"hubWhen": {
|
|
815
|
+
"MODEL": [
|
|
816
|
+
"keyvalue"
|
|
817
|
+
]
|
|
818
|
+
}
|
|
819
|
+
},
|
|
820
|
+
{
|
|
821
|
+
"id": "ff-kv-latency",
|
|
822
|
+
"type": "fitness-fn",
|
|
823
|
+
"label": "Key lookups within target",
|
|
824
|
+
"x": 1040,
|
|
825
|
+
"y": 1300,
|
|
826
|
+
"characteristic": "performance-efficiency",
|
|
827
|
+
"scope": "atomic",
|
|
828
|
+
"cadence": "triggered",
|
|
829
|
+
"trigger": "nightly",
|
|
830
|
+
"invocation": "automated",
|
|
831
|
+
"description": "A daily job reads the store's own latency percentile per operation from CloudWatch (SuccessfulRequestLatency, p99, hourly) and fails when any hour exceeds the budget. Runs on Linux (GNU date).\n\nThreshold: 99th percentile of the store's request latency for GetItem and PutItem at most {{P99_MS}} ms in every hour of the last 24 hours\n\nTool: AWS CLI with CloudWatch SuccessfulRequestLatency (DynamoDB); Redis: redis-benchmark -t get,set against the production-sized store, reading its p99 line\n\n```bash\n#!/usr/bin/env bash\n# daily: the store's p99 for key reads and writes over the last 24 hours, per hour\nset -euo pipefail\nfail=0\nfor op in GetItem PutItem; do\n p99=$(aws cloudwatch get-metric-statistics --namespace AWS/DynamoDB --metric-name SuccessfulRequestLatency \\\n --dimensions Name=TableName,Value=\"$TABLE\" Name=Operation,Value=\"$op\" \\\n --start-time \"$(date -u -d '24 hours ago' +%FT%TZ)\" --end-time \"$(date -u +%FT%TZ)\" --period 3600 \\\n --extended-statistics p99 --query 'max(Datapoints[].ExtendedStatistics.p99)' --output text)\n [ \"$p99\" = None ] || [ \"$(jq -n \"$p99 <= {{P99_MS}}\")\" = true ] || { echo \"$op p99 $p99 ms, budget {{P99_MS}} ms\"; fail=1; }\ndone\nexit $fail\n```",
|
|
832
|
+
"hubWhen": {
|
|
833
|
+
"MODEL": [
|
|
834
|
+
"keyvalue"
|
|
835
|
+
]
|
|
836
|
+
}
|
|
837
|
+
},
|
|
838
|
+
{
|
|
839
|
+
"id": "ff-atomic",
|
|
840
|
+
"type": "fitness-fn",
|
|
841
|
+
"label": "Failed operation leaves nothing",
|
|
842
|
+
"x": 1040,
|
|
843
|
+
"y": 1430,
|
|
844
|
+
"characteristic": "functional-suitability",
|
|
845
|
+
"scope": "atomic",
|
|
846
|
+
"cadence": "triggered",
|
|
847
|
+
"trigger": "pull-request",
|
|
848
|
+
"invocation": "automated",
|
|
849
|
+
"description": "An integration test against the real engine (Testcontainers) injects a fault after the second write of an operation through the repository's test hook and asserts that none of its records exists afterwards; one such test per multi-record operation.\n\nThreshold: For every business operation that writes several records: a fault after its second write leaves 0 records changed\n\nTool: Vitest (or your stack's test runner) with Testcontainers\n\n```ts\nimport { afterEach, expect, it } from 'vitest'\nimport { failAfterWrites, reset } from '../src/data/testHooks' // the repository's fault injection, test builds only\nimport { orderLines, orders, placeOrder } from '../src/orders'\n\nafterEach(reset)\n\nit('a failure after the second write leaves nothing of the operation', async () => {\n failAfterWrites(2) // the third write throws\n await expect(placeOrder(sampleOrderWithThreeLines())).rejects.toThrow()\n expect(await orders.find(sampleOrderId)).toBeNull()\n expect(await orderLines.countFor(sampleOrderId)).toBe(0)\n})\n```",
|
|
850
|
+
"hubWhen": {
|
|
851
|
+
"CONSISTENCY": [
|
|
852
|
+
"strong"
|
|
853
|
+
]
|
|
854
|
+
}
|
|
855
|
+
},
|
|
856
|
+
{
|
|
857
|
+
"id": "ff-replica-lag",
|
|
858
|
+
"type": "fitness-fn",
|
|
859
|
+
"label": "Replica lag within bound",
|
|
860
|
+
"x": 1040,
|
|
861
|
+
"y": 1560,
|
|
862
|
+
"characteristic": "reliability",
|
|
863
|
+
"scope": "atomic",
|
|
864
|
+
"cadence": "continual",
|
|
865
|
+
"invocation": "automated",
|
|
866
|
+
"description": "An alert on postgres_exporter's replication-lag metric pages when a replica falls further behind than the bound.\n\nThreshold: Replica lag at most {{STALE_SECONDS}} seconds; an alert fires after 2 minutes above it\n\nTool: Prometheus with postgres_exporter (PostgreSQL); MySQL: mysqld_exporter's mysql_slave_status_seconds_behind_master\n\n```yaml\ngroups:\n - name: data-store\n rules:\n - alert: ReplicaLagAboveBound\n expr: max by (instance) (pg_replication_lag_seconds) > {{STALE_SECONDS}}\n for: 2m\n labels: { severity: page }\n annotations:\n summary: \"Replica {{ $labels.instance }} lags {{ $value }}s behind the primary\"\n```",
|
|
867
|
+
"hubWhen": {
|
|
868
|
+
"CONSISTENCY": [
|
|
869
|
+
"eventual"
|
|
870
|
+
],
|
|
871
|
+
"MODEL": [
|
|
872
|
+
"relational"
|
|
873
|
+
]
|
|
874
|
+
}
|
|
875
|
+
},
|
|
876
|
+
{
|
|
877
|
+
"id": "ff-replica-lag-document",
|
|
878
|
+
"type": "fitness-fn",
|
|
879
|
+
"label": "Secondary lag within bound",
|
|
880
|
+
"x": 1040,
|
|
881
|
+
"y": 1690,
|
|
882
|
+
"characteristic": "reliability",
|
|
883
|
+
"scope": "atomic",
|
|
884
|
+
"cadence": "continual",
|
|
885
|
+
"invocation": "automated",
|
|
886
|
+
"description": "An alert on the MongoDB exporter's member replication lag (compatible-mode metric from replSetGetStatus) pages when a secondary falls further behind than the bound.\n\nThreshold: Replica set member lag at most {{STALE_SECONDS}} seconds; an alert fires after 2 minutes above it\n\nTool: Prometheus with the Percona mongodb_exporter (--compatible-mode)\n\n```yaml\ngroups:\n - name: data-store\n rules:\n - alert: SecondaryLagAboveBound\n expr: max by (set, name) (mongodb_mongod_replset_member_replication_lag{state=\"SECONDARY\"}) > {{STALE_SECONDS}}\n for: 2m\n labels: { severity: page }\n annotations:\n summary: \"{{ $labels.name }} in {{ $labels.set }} lags {{ $value }}s behind the primary\"\n```",
|
|
887
|
+
"hubWhen": {
|
|
888
|
+
"CONSISTENCY": [
|
|
889
|
+
"eventual"
|
|
890
|
+
],
|
|
891
|
+
"MODEL": [
|
|
892
|
+
"document"
|
|
893
|
+
]
|
|
894
|
+
}
|
|
895
|
+
},
|
|
896
|
+
{
|
|
897
|
+
"id": "ff-replica-lag-kv",
|
|
898
|
+
"type": "fitness-fn",
|
|
899
|
+
"label": "Replication lag within bound",
|
|
900
|
+
"x": 1040,
|
|
901
|
+
"y": 1820,
|
|
902
|
+
"characteristic": "reliability",
|
|
903
|
+
"scope": "atomic",
|
|
904
|
+
"cadence": "continual",
|
|
905
|
+
"invocation": "automated",
|
|
906
|
+
"description": "Two alert rules: the Redis exporter's replica lag, and DynamoDB's ReplicationLatency (milliseconds, per receiving region) brought into Prometheus by the CloudWatch exporter; either pages when a replica falls further behind than the bound.\n\nThreshold: Redis replica lag, or DynamoDB global table replication latency, at most {{STALE_SECONDS}} seconds; an alert fires after 2 minutes above it\n\nTool: Prometheus with redis_exporter and the CloudWatch exporter (aws_dynamodb_replication_latency_maximum)\n\n```yaml\ngroups:\n - name: data-store\n rules:\n - alert: RedisReplicaLagAboveBound\n expr: max by (instance) (redis_connected_slave_lag_seconds) > {{STALE_SECONDS}}\n for: 2m\n labels: { severity: page }\n annotations:\n summary: \"Redis {{ $labels.instance }}: a replica lags {{ $value }}s\"\n - alert: DynamoDBReplicationLagAboveBound\n expr: max by (table_name, receiving_region) (aws_dynamodb_replication_latency_maximum) / 1000 > {{STALE_SECONDS}}\n for: 2m\n labels: { severity: page }\n annotations:\n summary: \"{{ $labels.table_name }} replicates to {{ $labels.receiving_region }} with {{ $value }}s latency\"\n```",
|
|
907
|
+
"hubWhen": {
|
|
908
|
+
"CONSISTENCY": [
|
|
909
|
+
"eventual"
|
|
910
|
+
],
|
|
911
|
+
"MODEL": [
|
|
912
|
+
"keyvalue"
|
|
913
|
+
]
|
|
914
|
+
}
|
|
915
|
+
},
|
|
916
|
+
{
|
|
917
|
+
"id": "ff-export",
|
|
918
|
+
"type": "fitness-fn",
|
|
919
|
+
"label": "Export is fresh",
|
|
920
|
+
"x": 1040,
|
|
921
|
+
"y": 1950,
|
|
922
|
+
"characteristic": "flexibility",
|
|
923
|
+
"scope": "atomic",
|
|
924
|
+
"cadence": "triggered",
|
|
925
|
+
"trigger": "nightly",
|
|
926
|
+
"invocation": "automated",
|
|
927
|
+
"description": "A scheduled check lists the export location through rclone (S3, Azure Blob Storage, Google Cloud Storage and others alike), takes the newest object's modification time and fails when it is older than 26 hours (a daily export with two hours of slack). Runs on Linux (GNU date).\n\nThreshold: The newest export in storage the organisation controls is less than 26 hours old\n\nTool: rclone with jq (scheduled check)\n\n```bash\n#!/usr/bin/env bash\n# EXPORT_REMOTE: an rclone remote in storage we control, e.g. s3:exports/orders, azblob:exports/orders, gcs:exports/orders\nset -euo pipefail\nnewest=$(rclone lsjson \"$EXPORT_REMOTE\" --files-only --recursive | jq -r 'max_by(.ModTime).ModTime')\n[ \"$newest\" != null ] || { echo \"no export found in $EXPORT_REMOTE\"; exit 1; }\nage=$(( $(date +%s) - $(date -d \"$newest\" +%s) ))\n[ \"$age\" -lt $((26 * 3600)) ] || { echo \"newest export is $((age / 3600)) h old\"; exit 1; }\n```",
|
|
928
|
+
"hubWhen": {
|
|
929
|
+
"HOSTING": [
|
|
930
|
+
"managed"
|
|
931
|
+
]
|
|
932
|
+
}
|
|
933
|
+
},
|
|
934
|
+
{
|
|
935
|
+
"id": "ff-engine-current-relational",
|
|
936
|
+
"type": "fitness-fn",
|
|
937
|
+
"label": "PostgreSQL on latest minor",
|
|
938
|
+
"x": 1040,
|
|
939
|
+
"y": 2080,
|
|
940
|
+
"characteristic": "maintainability",
|
|
941
|
+
"scope": "atomic",
|
|
942
|
+
"cadence": "triggered",
|
|
943
|
+
"trigger": "nightly",
|
|
944
|
+
"invocation": "automated",
|
|
945
|
+
"description": "A scheduled job asks each node its version, looks its cycle up on endoflife.date (postgresql) and fails when the newest release of the cycle has been out for more than 30 days without being applied, or the cycle has reached end of support. Runs on Linux (GNU date).\n\nThreshold: Every PostgreSQL node runs the latest release of its postgresql cycle on endoflife.date, or one published less than 30 days ago; 0 cycles past end of support\n\nTool: endoflife.date API with psql (PostgreSQL); MySQL: SELECT VERSION() and the mysql product, cycle of two numbers\n\n```bash\n#!/usr/bin/env bash\n# run once per node; the node's connection string comes from the environment\nset -euo pipefail\nrunning=$(psql \"$DATABASE_URL\" -tAc 'SHOW server_version' | cut -d' ' -f1)\ncycle=$(cut -d. -f1-1 <<<\"$running\")\ninfo=$(curl -fsS \"https://endoflife.date/api/postgresql/${cycle}.json\")\nlatest=$(jq -r '.latest' <<<\"$info\"); released=$(jq -r '.latestReleaseDate' <<<\"$info\"); eol=$(jq -r '.eol' <<<\"$info\")\nif [ \"$eol\" = true ] || { [ \"$eol\" != false ] && [ \"$(date -d \"$eol\" +%s)\" -lt \"$(date +%s)\" ]; }; then\n echo \"PostgreSQL $cycle is past end of support ($eol)\"; exit 1\nfi\nif [ \"$running\" != \"$latest\" ] && [ \"$(date -d \"$released\" +%s)\" -lt \"$(date -d '30 days ago' +%s)\" ]; then\n echo \"running $running, $latest released on $released (30 days allowed)\"; exit 1\nfi\n```",
|
|
946
|
+
"hubWhen": {
|
|
947
|
+
"HOSTING": [
|
|
948
|
+
"self"
|
|
949
|
+
],
|
|
950
|
+
"MODEL": [
|
|
951
|
+
"relational"
|
|
952
|
+
]
|
|
953
|
+
}
|
|
954
|
+
},
|
|
955
|
+
{
|
|
956
|
+
"id": "ff-engine-current-document",
|
|
957
|
+
"type": "fitness-fn",
|
|
958
|
+
"label": "MongoDB on latest minor",
|
|
959
|
+
"x": 1040,
|
|
960
|
+
"y": 2210,
|
|
961
|
+
"characteristic": "maintainability",
|
|
962
|
+
"scope": "atomic",
|
|
963
|
+
"cadence": "triggered",
|
|
964
|
+
"trigger": "nightly",
|
|
965
|
+
"invocation": "automated",
|
|
966
|
+
"description": "A scheduled job asks each node its version, looks its cycle up on endoflife.date (mongodb) and fails when the newest release of the cycle has been out for more than 30 days without being applied, or the cycle has reached end of support. Runs on Linux (GNU date).\n\nThreshold: Every MongoDB node runs the latest release of its mongodb cycle on endoflife.date, or one published less than 30 days ago; 0 cycles past end of support\n\nTool: endoflife.date API with mongosh\n\n```bash\n#!/usr/bin/env bash\n# run once per node; the node's connection string comes from the environment\nset -euo pipefail\nrunning=$(mongosh \"$MONGODB_URI\" --quiet --eval 'db.version()')\ncycle=$(cut -d. -f1-2 <<<\"$running\")\ninfo=$(curl -fsS \"https://endoflife.date/api/mongodb/${cycle}.json\")\nlatest=$(jq -r '.latest' <<<\"$info\"); released=$(jq -r '.latestReleaseDate' <<<\"$info\"); eol=$(jq -r '.eol' <<<\"$info\")\nif [ \"$eol\" = true ] || { [ \"$eol\" != false ] && [ \"$(date -d \"$eol\" +%s)\" -lt \"$(date +%s)\" ]; }; then\n echo \"MongoDB $cycle is past end of support ($eol)\"; exit 1\nfi\nif [ \"$running\" != \"$latest\" ] && [ \"$(date -d \"$released\" +%s)\" -lt \"$(date -d '30 days ago' +%s)\" ]; then\n echo \"running $running, $latest released on $released (30 days allowed)\"; exit 1\nfi\n```",
|
|
967
|
+
"hubWhen": {
|
|
968
|
+
"HOSTING": [
|
|
969
|
+
"self"
|
|
970
|
+
],
|
|
971
|
+
"MODEL": [
|
|
972
|
+
"document"
|
|
973
|
+
]
|
|
974
|
+
}
|
|
975
|
+
},
|
|
976
|
+
{
|
|
977
|
+
"id": "ff-engine-current-keyvalue",
|
|
978
|
+
"type": "fitness-fn",
|
|
979
|
+
"label": "Redis on latest minor",
|
|
980
|
+
"x": 1040,
|
|
981
|
+
"y": 2340,
|
|
982
|
+
"characteristic": "maintainability",
|
|
983
|
+
"scope": "atomic",
|
|
984
|
+
"cadence": "triggered",
|
|
985
|
+
"trigger": "nightly",
|
|
986
|
+
"invocation": "automated",
|
|
987
|
+
"description": "A scheduled job asks each node its version, looks its cycle up on endoflife.date (redis) and fails when the newest release of the cycle has been out for more than 30 days without being applied, or the cycle has reached end of support. Runs on Linux (GNU date).\n\nThreshold: Every Redis node runs the latest release of its redis cycle on endoflife.date, or one published less than 30 days ago; 0 cycles past end of support\n\nTool: endoflife.date API with redis-cli (Redis; Valkey: the valkey product)\n\n```bash\n#!/usr/bin/env bash\n# run once per node; the node's connection string comes from the environment\nset -euo pipefail\nrunning=$(redis-cli -u \"$REDIS_URL\" INFO server | tr -d '\\r' | awk -F: '/^redis_version:/ { print $2 }')\ncycle=$(cut -d. -f1-2 <<<\"$running\")\ninfo=$(curl -fsS \"https://endoflife.date/api/redis/${cycle}.json\")\nlatest=$(jq -r '.latest' <<<\"$info\"); released=$(jq -r '.latestReleaseDate' <<<\"$info\"); eol=$(jq -r '.eol' <<<\"$info\")\nif [ \"$eol\" = true ] || { [ \"$eol\" != false ] && [ \"$(date -d \"$eol\" +%s)\" -lt \"$(date +%s)\" ]; }; then\n echo \"Redis $cycle is past end of support ($eol)\"; exit 1\nfi\nif [ \"$running\" != \"$latest\" ] && [ \"$(date -d \"$released\" +%s)\" -lt \"$(date -d '30 days ago' +%s)\" ]; then\n echo \"running $running, $latest released on $released (30 days allowed)\"; exit 1\nfi\n```",
|
|
988
|
+
"hubWhen": {
|
|
989
|
+
"HOSTING": [
|
|
990
|
+
"self"
|
|
991
|
+
],
|
|
992
|
+
"MODEL": [
|
|
993
|
+
"keyvalue"
|
|
994
|
+
]
|
|
995
|
+
}
|
|
996
|
+
}
|
|
997
|
+
],
|
|
998
|
+
"relations": [
|
|
999
|
+
{
|
|
1000
|
+
"id": "req-access-patterns--derives--need",
|
|
1001
|
+
"sourceId": "req-access-patterns",
|
|
1002
|
+
"targetId": "need",
|
|
1003
|
+
"relationType": "derives"
|
|
1004
|
+
},
|
|
1005
|
+
{
|
|
1006
|
+
"id": "req-indexed-reads--derives--need",
|
|
1007
|
+
"sourceId": "req-indexed-reads",
|
|
1008
|
+
"targetId": "need",
|
|
1009
|
+
"relationType": "derives"
|
|
1010
|
+
},
|
|
1011
|
+
{
|
|
1012
|
+
"id": "req-versioned--derives--need",
|
|
1013
|
+
"sourceId": "req-versioned",
|
|
1014
|
+
"targetId": "need",
|
|
1015
|
+
"relationType": "derives"
|
|
1016
|
+
},
|
|
1017
|
+
{
|
|
1018
|
+
"id": "req-versioned-doc--derives--need",
|
|
1019
|
+
"sourceId": "req-versioned-doc",
|
|
1020
|
+
"targetId": "need",
|
|
1021
|
+
"relationType": "derives"
|
|
1022
|
+
},
|
|
1023
|
+
{
|
|
1024
|
+
"id": "req-lazy--derives--need",
|
|
1025
|
+
"sourceId": "req-lazy",
|
|
1026
|
+
"targetId": "need",
|
|
1027
|
+
"relationType": "derives"
|
|
1028
|
+
},
|
|
1029
|
+
{
|
|
1030
|
+
"id": "req-integrity--derives--need",
|
|
1031
|
+
"sourceId": "req-integrity",
|
|
1032
|
+
"targetId": "need",
|
|
1033
|
+
"relationType": "derives"
|
|
1034
|
+
},
|
|
1035
|
+
{
|
|
1036
|
+
"id": "req-documents--derives--need",
|
|
1037
|
+
"sourceId": "req-documents",
|
|
1038
|
+
"targetId": "need",
|
|
1039
|
+
"relationType": "derives"
|
|
1040
|
+
},
|
|
1041
|
+
{
|
|
1042
|
+
"id": "req-kv-latency--derives--need",
|
|
1043
|
+
"sourceId": "req-kv-latency",
|
|
1044
|
+
"targetId": "need",
|
|
1045
|
+
"relationType": "derives"
|
|
1046
|
+
},
|
|
1047
|
+
{
|
|
1048
|
+
"id": "req-transactions--derives--need",
|
|
1049
|
+
"sourceId": "req-transactions",
|
|
1050
|
+
"targetId": "need",
|
|
1051
|
+
"relationType": "derives"
|
|
1052
|
+
},
|
|
1053
|
+
{
|
|
1054
|
+
"id": "req-staleness--derives--need",
|
|
1055
|
+
"sourceId": "req-staleness",
|
|
1056
|
+
"targetId": "need",
|
|
1057
|
+
"relationType": "derives"
|
|
1058
|
+
},
|
|
1059
|
+
{
|
|
1060
|
+
"id": "req-exit--derives--need",
|
|
1061
|
+
"sourceId": "req-exit",
|
|
1062
|
+
"targetId": "need",
|
|
1063
|
+
"relationType": "derives"
|
|
1064
|
+
},
|
|
1065
|
+
{
|
|
1066
|
+
"id": "req-engine-patch--derives--need",
|
|
1067
|
+
"sourceId": "req-engine-patch",
|
|
1068
|
+
"targetId": "need",
|
|
1069
|
+
"relationType": "derives"
|
|
1070
|
+
},
|
|
1071
|
+
{
|
|
1072
|
+
"id": "sc-access-patterns--verifies--req-access-patterns",
|
|
1073
|
+
"sourceId": "sc-access-patterns",
|
|
1074
|
+
"targetId": "req-access-patterns",
|
|
1075
|
+
"relationType": "verifies"
|
|
1076
|
+
},
|
|
1077
|
+
{
|
|
1078
|
+
"id": "sc-indexed-reads--verifies--req-indexed-reads",
|
|
1079
|
+
"sourceId": "sc-indexed-reads",
|
|
1080
|
+
"targetId": "req-indexed-reads",
|
|
1081
|
+
"relationType": "verifies"
|
|
1082
|
+
},
|
|
1083
|
+
{
|
|
1084
|
+
"id": "sc-versioned--verifies--req-versioned",
|
|
1085
|
+
"sourceId": "sc-versioned",
|
|
1086
|
+
"targetId": "req-versioned",
|
|
1087
|
+
"relationType": "verifies"
|
|
1088
|
+
},
|
|
1089
|
+
{
|
|
1090
|
+
"id": "sc-versioned-doc--verifies--req-versioned-doc",
|
|
1091
|
+
"sourceId": "sc-versioned-doc",
|
|
1092
|
+
"targetId": "req-versioned-doc",
|
|
1093
|
+
"relationType": "verifies"
|
|
1094
|
+
},
|
|
1095
|
+
{
|
|
1096
|
+
"id": "sc-lazy--verifies--req-lazy",
|
|
1097
|
+
"sourceId": "sc-lazy",
|
|
1098
|
+
"targetId": "req-lazy",
|
|
1099
|
+
"relationType": "verifies"
|
|
1100
|
+
},
|
|
1101
|
+
{
|
|
1102
|
+
"id": "sc-integrity--verifies--req-integrity",
|
|
1103
|
+
"sourceId": "sc-integrity",
|
|
1104
|
+
"targetId": "req-integrity",
|
|
1105
|
+
"relationType": "verifies"
|
|
1106
|
+
},
|
|
1107
|
+
{
|
|
1108
|
+
"id": "sc-documents--verifies--req-documents",
|
|
1109
|
+
"sourceId": "sc-documents",
|
|
1110
|
+
"targetId": "req-documents",
|
|
1111
|
+
"relationType": "verifies"
|
|
1112
|
+
},
|
|
1113
|
+
{
|
|
1114
|
+
"id": "sc-kv-latency--verifies--req-kv-latency",
|
|
1115
|
+
"sourceId": "sc-kv-latency",
|
|
1116
|
+
"targetId": "req-kv-latency",
|
|
1117
|
+
"relationType": "verifies"
|
|
1118
|
+
},
|
|
1119
|
+
{
|
|
1120
|
+
"id": "sc-transactions--verifies--req-transactions",
|
|
1121
|
+
"sourceId": "sc-transactions",
|
|
1122
|
+
"targetId": "req-transactions",
|
|
1123
|
+
"relationType": "verifies"
|
|
1124
|
+
},
|
|
1125
|
+
{
|
|
1126
|
+
"id": "sc-staleness--verifies--req-staleness",
|
|
1127
|
+
"sourceId": "sc-staleness",
|
|
1128
|
+
"targetId": "req-staleness",
|
|
1129
|
+
"relationType": "verifies"
|
|
1130
|
+
},
|
|
1131
|
+
{
|
|
1132
|
+
"id": "sc-exit--verifies--req-exit",
|
|
1133
|
+
"sourceId": "sc-exit",
|
|
1134
|
+
"targetId": "req-exit",
|
|
1135
|
+
"relationType": "verifies"
|
|
1136
|
+
},
|
|
1137
|
+
{
|
|
1138
|
+
"id": "sc-engine-patch--verifies--req-engine-patch",
|
|
1139
|
+
"sourceId": "sc-engine-patch",
|
|
1140
|
+
"targetId": "req-engine-patch",
|
|
1141
|
+
"relationType": "verifies"
|
|
1142
|
+
},
|
|
1143
|
+
{
|
|
1144
|
+
"id": "ff-flyway--implements--adr-relational",
|
|
1145
|
+
"sourceId": "ff-flyway",
|
|
1146
|
+
"targetId": "adr-relational",
|
|
1147
|
+
"relationType": "implements"
|
|
1148
|
+
},
|
|
1149
|
+
{
|
|
1150
|
+
"id": "ff-liquibase-mongo--implements--adr-document",
|
|
1151
|
+
"sourceId": "ff-liquibase-mongo",
|
|
1152
|
+
"targetId": "adr-document",
|
|
1153
|
+
"relationType": "implements"
|
|
1154
|
+
},
|
|
1155
|
+
{
|
|
1156
|
+
"id": "ff-orm-drift--implements--adr-relational",
|
|
1157
|
+
"sourceId": "ff-orm-drift",
|
|
1158
|
+
"targetId": "adr-relational",
|
|
1159
|
+
"relationType": "implements"
|
|
1160
|
+
},
|
|
1161
|
+
{
|
|
1162
|
+
"id": "ff-schema-versions--implements--adr-document",
|
|
1163
|
+
"sourceId": "ff-schema-versions",
|
|
1164
|
+
"targetId": "adr-document",
|
|
1165
|
+
"relationType": "implements"
|
|
1166
|
+
},
|
|
1167
|
+
{
|
|
1168
|
+
"id": "ff-schema-versions-kv--implements--adr-keyvalue",
|
|
1169
|
+
"sourceId": "ff-schema-versions-kv",
|
|
1170
|
+
"targetId": "adr-keyvalue",
|
|
1171
|
+
"relationType": "implements"
|
|
1172
|
+
},
|
|
1173
|
+
{
|
|
1174
|
+
"id": "ff-seq-scan--implements--adr-relational",
|
|
1175
|
+
"sourceId": "ff-seq-scan",
|
|
1176
|
+
"targetId": "adr-relational",
|
|
1177
|
+
"relationType": "implements"
|
|
1178
|
+
},
|
|
1179
|
+
{
|
|
1180
|
+
"id": "ff-collscan--implements--adr-document",
|
|
1181
|
+
"sourceId": "ff-collscan",
|
|
1182
|
+
"targetId": "adr-document",
|
|
1183
|
+
"relationType": "implements"
|
|
1184
|
+
},
|
|
1185
|
+
{
|
|
1186
|
+
"id": "ff-integrity--implements--adr-relational",
|
|
1187
|
+
"sourceId": "ff-integrity",
|
|
1188
|
+
"targetId": "adr-relational",
|
|
1189
|
+
"relationType": "implements"
|
|
1190
|
+
},
|
|
1191
|
+
{
|
|
1192
|
+
"id": "ff-validators--implements--adr-document",
|
|
1193
|
+
"sourceId": "ff-validators",
|
|
1194
|
+
"targetId": "adr-document",
|
|
1195
|
+
"relationType": "implements"
|
|
1196
|
+
},
|
|
1197
|
+
{
|
|
1198
|
+
"id": "ff-no-scan--implements--adr-keyvalue",
|
|
1199
|
+
"sourceId": "ff-no-scan",
|
|
1200
|
+
"targetId": "adr-keyvalue",
|
|
1201
|
+
"relationType": "implements"
|
|
1202
|
+
},
|
|
1203
|
+
{
|
|
1204
|
+
"id": "ff-kv-latency--implements--adr-keyvalue",
|
|
1205
|
+
"sourceId": "ff-kv-latency",
|
|
1206
|
+
"targetId": "adr-keyvalue",
|
|
1207
|
+
"relationType": "implements"
|
|
1208
|
+
},
|
|
1209
|
+
{
|
|
1210
|
+
"id": "ff-atomic--implements--adr-relational",
|
|
1211
|
+
"sourceId": "ff-atomic",
|
|
1212
|
+
"targetId": "adr-relational",
|
|
1213
|
+
"relationType": "implements"
|
|
1214
|
+
},
|
|
1215
|
+
{
|
|
1216
|
+
"id": "ff-atomic--implements--adr-document",
|
|
1217
|
+
"sourceId": "ff-atomic",
|
|
1218
|
+
"targetId": "adr-document",
|
|
1219
|
+
"relationType": "implements"
|
|
1220
|
+
},
|
|
1221
|
+
{
|
|
1222
|
+
"id": "ff-atomic--implements--adr-keyvalue",
|
|
1223
|
+
"sourceId": "ff-atomic",
|
|
1224
|
+
"targetId": "adr-keyvalue",
|
|
1225
|
+
"relationType": "implements"
|
|
1226
|
+
},
|
|
1227
|
+
{
|
|
1228
|
+
"id": "ff-replica-lag--implements--adr-relational",
|
|
1229
|
+
"sourceId": "ff-replica-lag",
|
|
1230
|
+
"targetId": "adr-relational",
|
|
1231
|
+
"relationType": "implements"
|
|
1232
|
+
},
|
|
1233
|
+
{
|
|
1234
|
+
"id": "ff-replica-lag-document--implements--adr-document",
|
|
1235
|
+
"sourceId": "ff-replica-lag-document",
|
|
1236
|
+
"targetId": "adr-document",
|
|
1237
|
+
"relationType": "implements"
|
|
1238
|
+
},
|
|
1239
|
+
{
|
|
1240
|
+
"id": "ff-replica-lag-kv--implements--adr-keyvalue",
|
|
1241
|
+
"sourceId": "ff-replica-lag-kv",
|
|
1242
|
+
"targetId": "adr-keyvalue",
|
|
1243
|
+
"relationType": "implements"
|
|
1244
|
+
},
|
|
1245
|
+
{
|
|
1246
|
+
"id": "ff-export--implements--adr-relational",
|
|
1247
|
+
"sourceId": "ff-export",
|
|
1248
|
+
"targetId": "adr-relational",
|
|
1249
|
+
"relationType": "implements"
|
|
1250
|
+
},
|
|
1251
|
+
{
|
|
1252
|
+
"id": "ff-export--implements--adr-document",
|
|
1253
|
+
"sourceId": "ff-export",
|
|
1254
|
+
"targetId": "adr-document",
|
|
1255
|
+
"relationType": "implements"
|
|
1256
|
+
},
|
|
1257
|
+
{
|
|
1258
|
+
"id": "ff-export--implements--adr-keyvalue",
|
|
1259
|
+
"sourceId": "ff-export",
|
|
1260
|
+
"targetId": "adr-keyvalue",
|
|
1261
|
+
"relationType": "implements"
|
|
1262
|
+
},
|
|
1263
|
+
{
|
|
1264
|
+
"id": "ff-engine-current-relational--implements--adr-relational",
|
|
1265
|
+
"sourceId": "ff-engine-current-relational",
|
|
1266
|
+
"targetId": "adr-relational",
|
|
1267
|
+
"relationType": "implements"
|
|
1268
|
+
},
|
|
1269
|
+
{
|
|
1270
|
+
"id": "ff-engine-current-document--implements--adr-document",
|
|
1271
|
+
"sourceId": "ff-engine-current-document",
|
|
1272
|
+
"targetId": "adr-document",
|
|
1273
|
+
"relationType": "implements"
|
|
1274
|
+
},
|
|
1275
|
+
{
|
|
1276
|
+
"id": "ff-engine-current-keyvalue--implements--adr-keyvalue",
|
|
1277
|
+
"sourceId": "ff-engine-current-keyvalue",
|
|
1278
|
+
"targetId": "adr-keyvalue",
|
|
1279
|
+
"relationType": "implements"
|
|
1280
|
+
}
|
|
1281
|
+
]
|
|
1282
|
+
}
|