TamaDB positions itself as a transmission‑layer cache that accepts JSON updates from several producers, merges fields without overwriting untouched data, and notifies consumers with the current document state.
Merge‑only writes eliminate coordination overhead
Both the dev.to post and the official project site describe TamaDB’s core ingestion operation as an upsert that always merges rather than replaces. When a producer sends a subset of fields, those fields are updated while all other fields remain unchanged, preventing one producer from unintentionally erasing another’s data. This design removes the need for producers to coordinate timestamps or full document snapshots, a drawback highlighted for Redis streams and Kafka compacted topics.
The merge rule is strict: a field cannot be removed through a write, and array values are replaced wholesale because element‑level updates are not part of Increment 1.
The transmission‑layer governance document reiterates that the cache never alters the semantic meaning of attributes – it only preserves what arrives.
Per‑leaf version numbers and bounded history
TamaDB treats each terminal value as a leaf that carries its own version counter and a short history of prior values. The overall document also has a version, but the leaf versions reveal which producer’s field changed and how many updates that field has seen. In the example garage scenario, the document reached version 11 while the humidity leaf stayed at version 1 because only the humidity sensor ever wrote that field.
The project site confirms the leaf‑level versioning model as a core principle and notes that the history depth is fixed at five entries in Increment 1, with no API to read it yet.
Both sources agree that future increments will make leaf history configurable and expose it through the API.
Webhook delivery and reliability guarantees
When a write succeeds, TamaDB immediately enqueues a webhook containing the full merged document. The payload is captured at enqueue time, so later updates do not retroactively alter already‑queued deliveries. Consumers therefore receive a consistent snapshot without needing to replay events.
Delivery is best‑effort: the in‑memory queue supports one‑fire or retry modes (up to five attempts with exponential backoff). If the service restarts, pending deliveries are lost, and the cache does not replay them. The transmission‑layer description classifies this as a non‑responsibility, explicitly stating that the layer does not provide durable broker guarantees.
Both documents note that a downstream broker such as PamaDB can be added for durable delivery requirements.
Scope, security and governance
The governance page defines the transmission layer’s boundaries: no business logic, no data aggregation, no permanent storage, and no authentication or TLS in Increment 1. The dev.to article mirrors this by warning that all endpoints are open by default and must be shielded behind a reverse proxy for production use.
Both sources stress that TamaDB is a cache, not an archive. Documents expire based on a TTL hierarchy—instance, document type, or per‑document—where the most specific setting wins. Expired items are soft‑deleted and not returned on reads.
The governance document adds the “Semantic Preservation Principle”, which formalises the rule that every attribute exiting the layer must retain its original meaning, a phrasing not present in the dev.to post.
Analysis: when and why developers might adopt TamaDB
For teams building dashboards, IoT aggregators, or any system where multiple independent services need to contribute to a single JSON view, TamaDB removes the coordination layer that traditional message queues impose. By guaranteeing that each leaf update never wipes unrelated fields, developers can write simple, schema‑validated producers without implementing custom merge logic. The per‑leaf versioning also gives consumers a lightweight way to detect which part of a document changed, useful for UI diffing or selective downstream processing.
However, the lack of authentication, TLS, and durable delivery means TamaDB is best suited for internal networks or environments where a reverse proxy or external security perimeter can be added. Projects that require guaranteed replay of every change, complex queries, or long‑term archival will need to pair TamaDB with a broker such as PamaDB or a traditional database.
Future roadmap items—Hybrid Document Open Model, configurable leaf history, and discrete leaf updates—promise to broaden applicability to less‑structured data sources while keeping the core merge‑only guarantee. Until those increments arrive, developers should evaluate whether the fixed five‑entry leaf history and in‑memory delivery queue meet their latency and reliability requirements.
Cover: AI-generated illustration with headline text; not a documentary photograph.
Source: The Space Between Redis and Kafka: Why I Built a Document Cache with Per-Leaf Versioning · TamaDB — Presentation

Leave a Reply