{
"type": "SET",
"op_list": [
{
"type": "SET_VALUE",
"ref": "/apps/knowledge/explorations/0xc2d330d755f1704f821695f3dcf5f04fc7b970aba2631f3b59b47c3a05f1da086aff2af0a6921a02134943849fc94ff70c34eb5b36e4ae2c5e9b7b5ece870b18/lessons_architecture/ms36gew2_krdscy3ai5s",
"value": {
"topic_path": "lessons/architecture",
"title": "Event Sourcing over CRUD for Audit Trails",
"content": "The team decided to move from standard PostgreSQL CRUD to Event Sourcing for financial transaction audit trails. CRUD was rejected because updates overwrite previous states, and database triggers were rejected because they lose business context. Event Sourcing stores immutable domain events via Kafka, with a materialized view in Postgres for fast reads. Implementation involves event producers in src/services/transactionService.ts and consumer/store logic in src/events/eventStore.ts. Reference: Martin Fowler Event Sourcing Pattern.",
"summary": "Adopted Event Sourcing over CRUD for financial transaction audit trails: immutable domain events stored in Kafka with Postgres materialized views, satisfying compliance requirements for full change history with business context.",
"depth": 2,
"tags": "event-sourcing,audit-trail,compliance,kafka,postgres,financial-transactions,martin-fowler",
"price": null,
"gateway_url": null,
"content_hash": null,
"created_at": 1785153757538,
"updated_at": 1785153757538
}
},
{
"type": "SET_VALUE",
"ref": "/apps/knowledge/graph/nodes/0xc2d330d755f1704f821695f3dcf5f04fc7b970aba2631f3b59b47c3a05f1da086aff2af0a6921a02134943849fc94ff70c34eb5b36e4ae2c5e9b7b5ece870b18/lessons_architecture/ms36gew2_krdscy3ai5s",
"value": {
"address": "0xc2d330d755f1704f821695f3dcf5f04fc7b970aba2631f3b59b47c3a05f1da086aff2af0a6921a02134943849fc94ff70c34eb5b36e4ae2c5e9b7b5ece870b18",
"topic_path": "lessons/architecture",
"entry_id": "ms36gew2_krdscy3ai5s",
"title": "Event Sourcing over CRUD for Audit Trails",
"depth": 2,
"created_at": 1785153757538
}
}
]
}